arrow
返回

A large-scale exploratory study on the proxy pattern in Ethereum

delete2024-06-04
delete1
delete
OA
AI
A
Amir M. Ebrahimi *
B
Bram Adams
G
Gustavo A. Oliva
A
Ahmed E. Hassan
DOI:10.1007/s10664-024-10485-1delete
delete原文链接
delete原文求助
delete分享
delete收藏
摘要

摘要

En 中文
The proxy pattern is a well-known design pattern with numerous use cases in several sectors of the software industry (e.g., network applications, microservices, and IoT). As such, the use of the proxy pattern is also a common approach in the development of complex decentralized applications (DApps) on the Ethereum blockchain. A contract that implements the proxy pattern (proxy contract) acts as a layer between the clients and the target contract, enabling greater flexibility (e.g., data validation checks) and upgradeability (e.g., online smart contract replacement with zero downtime) in DApp development. Despite the importance of proxy contracts, little is known about (i) how their prevalence changed over time, (ii) the ways in which developers integrate proxies in the design of DApps, and (iii) what proxy types are being most commonly leveraged by developers. In this paper, we present a large-scale exploratory study on the use of the proxy pattern in Ethereum. We analyze a dataset of all Ethereum smart contracts as of Sep. 2022 containing 50M smart contracts and 1.6B transactions, and apply both quantitative and qualitative methods in order to (i) determine the prevalence of proxy contracts, (ii) understand the ways they are deployed and integrated into applications, and (iii) uncover the prevalence of different types of proxy contracts. Our findings reveal that 14.2% of all deployed smart contracts are proxy contracts. We show that proxy contracts are being more actively used than non-proxy contracts. Also, the usage of proxy contracts in various contexts, transactions involving proxy contracts, and adoption of proxy contracts by users have shown an upward trend over time, peaking at the end of our study period. They are either deployed through off-chain scripts or on-chain factory contracts, with the former and latter being employed in 39.1% and 60.9% of identified usage contexts in turn. We found that while the majority (67.8%) of proxies act as an interceptor, 32.2% enables upgradeability. Proxy contracts are typically (79%) implemented based on known reference implementations with 29.4% being of type ERC-1167, a class of proxies that aims to cheaply reuse and clone contracts' functionality. Our evaluation shows that our proposed behavioral proxy detection method has a precision and recall of 100% in detecting active proxies. Finally, we derive a set of practical recommendations for developers and introduce open research questions to guide future research on the topic.
Keyword:
Proxy pattern
Proxy
Maintenance
Smart contracts
Ethereum
Blockchain

期刊

Empirical Software Engineering 封面图
Empirical Software Engineering
IF:
3.6
论文数:
2.0K
被引数:
5.3K

机构

Q
queens university - canada
学者数:
1.8W
论文数: 1.7W
被引数: 29
引用论文

引用论文

Challenges and Common Solutions in Smart Contract Development智能合约开发中的挑战和常见解决方案
err2022-11-01
err28
errOAAI
errKannengiesser, Niclas; Lins, Sebastian; Sander, Christian; Winter, Klaus; Frey, Hellmuth; Sunyaev, Ali
err分享
err收藏
What makes Ethereum blockchain transactions be processed fast or slow? An empirical study
err2023-02-03
err4
errOAAI
errPacheco, Michael; Oliva, Gustavo A.; Rajbahadur, Gopi Krishnan; Hassan, Ahmed E.
err分享
err收藏
Ultrafast Absorption Changes of the Lhcii Carotenoids upon Selective Excitation of the Chlorophylls
err1998-01-01
err0
PREAI
errC. C. Gradinaru; I. H. M. van Stokkum; R. van Grondelle; H. van Amerongen
err分享
err收藏
Revisiting reopened bugs in open source software systems重新审视开源软件系统中重新打开的错误
err2022-04-25
err12
PREAI
errTagra, Ankur; Zhang, Haoxiang; Rajbahadur, Gopi Krishnan; Hassan, Ahmed E.
err分享
err收藏
Effects of the addition of helium on the synthesis of diamond films
err2000-12-01
err0
PREAI
errVitor Baranauskas; Helder J Ceragioli; Alfredo C Peterlevitz; Marcelo C Tosin; Steven F Durrant
err分享
err收藏
Naples in the Time of Cholera, 1884–1911
err
IF0
err2010-08-04
err0
PREAI
errFrank M. Snowden
err分享
err收藏
学者 查看更多内容