政大機構典藏-National Chengchi University Institutional Repository(NCCUR):Item 140.119/146579
English  |  正體中文  |  简体中文  |  Post-Print筆數 : 27 |  Items with full text/Total items : 113311/144292 (79%)
Visitors : 50931356      Online Users : 983
RC Version 6.0 © Powered By DSPACE, MIT. Enhanced by NTU Library IR team.
Scope Tips:
  • please add "double quotation mark" for query phrases to get precise results
  • please goto advance search for comprehansive author search
  • Adv. Search
    HomeLoginUploadHelpAboutAdminister Goto mobile version
    政大典藏 > College of Commerce > Department of MIS > Theses >  Item 140.119/146579
    Please use this identifier to cite or link to this item: https://nccur.lib.nccu.edu.tw/handle/140.119/146579


    Title: 實作區塊鏈交易池狀態快照與模擬工具:以 Uniswap 為例
    A Snapshot and Simulation Tool for Ethereum Transaction Pool: Uniswap as an example
    Authors: 林祐丞
    Lin, Yu-Cheng
    Contributors: 陳恭
    Chen, Kung
    林祐丞
    Lin, Yu-Cheng
    Keywords: 去中心化金融
    Uniswap
    三明治攻擊
    區塊鏈交易池
    Decentralized Finance
    Uniswap
    Sandwich Attack
    Transaction Mempool
    Date: 2023
    Issue Date: 2023-08-02 14:06:22 (UTC+8)
    Abstract: 在區塊鏈技術的普及和去中心化金融(DeFi)的崛起的背景下,區塊鏈交易的安全性、透明度和效率成為人們普遍關注的重要議題。對此,我們的研究專注於開發一款新型的工具,這款工具的目標是對區塊鏈交易池狀態進行全面的快照記錄和模擬,以加深對區塊鏈交易打包順序以及競價攻擊的理解,並進一步提高區塊鏈技術的效率和可靠性。在我們的研究中,一個主要的動機源於區塊鏈交易的批次性質以及其公開透明的特徵,這兩種特性都使得區塊鏈交易更容易受到競價攻擊,如三明治攻擊,進而導致交易池狀態的不穩定性增加。基於這樣的背景,我們在深入研究去中心化交易所,例如Uniswap的運作模式和競價攻擊問題的基礎上,開發出了這款工具。
    為了讓讀者對區塊鏈交易有更深入的理解,本研究首先對去中心化金融、去中心化交易所以及價格攻擊等相關概念進行了詳細的回顧與介紹。透過這種方式,我們期望讀者能夠對這些概念有一個基本且全面的理解。然後,我們介紹了我們工具的設計理念和實現方式,其中包括工具的整體架構、框架設計和系統流程設計。為了驗證工具的實際運作效果,我們利用一個已編寫完成的三明治套利機器人來模擬和測試,主要是透過偵測私有區塊鏈網路交易池的變動並模仿用戶的Uniswap交易來檢驗模擬期間是否會受到攻擊。通過這種方式,我們證明了工具快照的交易狀態可用於模擬,進而增進區塊鏈交易的安全性。而我們的研究重點並非在於套利機器人本身,而是在於證明工具取得的快照和模擬能力。
    在結論部分,我們對本研究的重要發現進行了總結。透過開發一款專為區塊鏈交易池設計的全新工具,我們為相關研究提供了堅實的技術支援。這款工具的出現,能使我們對區塊鏈交易的本質有更深的理解,提高區塊鏈技術的運作效率,對抗競價攻擊,同時更好地保護使用者的權益。儘管我們目前只開發出了最小可行性產品(Minimum Viable Product,MVP),但我們深信,隨著這款工具的進一步完善和發展,以及其他相關研究的持續推進,對於擴大其功能與應用範疇,這款工具在未來的區塊鏈研究中將扮演更重要的角色,從而推進區塊鏈技術的創新與進步。
    With the popularity of blockchain technology and the rise of decentralized finance (DeFi), the safety, transparency, and efficiency of blockchain transactions have become major topics of concern. To address these issues, our study focuses on the development of a novel tool that aims to snapshot and simulate the state of blockchain transaction pools comprehensively. The goal is to deepen the understanding of blockchain transaction sequencing and front-running attacks, and further improve the efficiency and reliability of blockchain technology. A key motivation in our study stems from the batch nature of blockchain transactions and their public transparency, both of which render blockchain transactions more susceptible to front-running attacks, such as sandwich attacks, thus increasing the instability of the transaction pool status. Against this background, we developed this tool based on in-depth study of decentralized exchanges, such as Uniswap, and their vulnerability to front-running attacks.
    To deepen readers` understanding of blockchain transactions, we first reviewed and introduced concepts related to decentralized finance, decentralized exchanges, and front-running attacks. Through this approach, we hope that readers will gain a basic and comprehensive understanding of these concepts. We then described the design philosophy and implementation methods of our tool, including its overall architecture, framework design, and system process design. To validate the effectiveness of our tool, we used a sandwich arbitrage bot to simulate and test it. This mainly involved monitoring changes in private blockchain network transaction pools and imitating Uniswap transactions by users to examine whether they would be attacked during the simulation period. Through this approach, we demonstrated that the snapshot status of transactions by our tool can be used for simulation, thereby enhancing the safety of blockchain transactions. It is important to emphasize that the focus of our study is not the arbitrage bot itself, but the demonstration of the snapshot and simulation capabilities of the tool.
    In the conclusion, we summarized the significant findings of our study. By developing a new tool specifically designed for blockchain transaction pools, we provide solid technical support for related research. The advent of this tool allows us to have a deeper understanding of the nature of blockchain transactions, improve the operational efficiency of blockchain technology, combat front-running attacks, and better protect user rights. Even though we have currently only developed a Minimum Viable Product (MVP), we are confident that with the further refinement and development of this tool, and with the continuous advancement of other related research, it will play an even more crucial role in future blockchain research, further propelling the innovation and progress of blockchain technology.
    Reference: 1. Bai, T., Hu, Y., He, J., Fan, H., & An, Z. (2022). Health-zkIDM: A Healthcare Identity System Based on Fabric Blockchain and Zero-Knowledge Proof. Sensors, 22(20), 7716.
    2. Bautista, J. R., Usman, M., Harrell, D. T., Meyer, E. T., & Khurshid, A. (2022). Clinical, Organizational and Regulatory, and Ethical and Social (CORES) Issues and Recommendations on Blockchain Deployment for Healthcare: Evidence from Experts. Blockchain in Healthcare Today, 5.
    3. Daian, P., Goldfeder, S., Kell, T., Li, Y., Zhao, X., Bentov, I., ... & Juels, A. (2019). Flash boys 2.0: Frontrunning, transaction reordering, and consensus instability in decentralized exchanges. arXiv preprint arXiv:1904.05234.
    4. Gudgeon, L., Werner, S., Perez, D., & Knottenbelt, W. J. (2020, October). Defi protocols for loanable funds: Interest rates, liquidity and market efficiency. In Proceedings of the 2nd ACM Conference on Advances in Financial Technologies (pp. 92-112).
    5. Jensen, J. R., von Wachter, V., & Ross, O. (2021). An introduction to decentralized finance (defi). Complex Systems Informatics and Modeling Quarterly, (26), 46-54.
    6. Koroļkovs, N., & Kodors, S. (2022). UNISWAP-A CASE STUDY OF DECENTRALIZED EXCHANGES ON THE BLOCKCHAIN. In HUMAN. ENVIRONMENT. TECHNOLOGIES. Proceedings of the Students International Scientific and Practical Conference (No. 26, pp. 25-30).
    7. Lo, Y. C., & Medda, F. (2021). Uniswap and the Emergence of the Decentralized Exchange. Journal of Financial Market Infrastructures, 10(2), 1-25.
    8. Manoj, T., Makkithaya, K., & Narendra, V. (2022). A blockchain based decentralized identifiers for entity authentication in electronic health records. Cogent Eng, 9(1), 2035134.
    9. Metelski, D., & Sobieraj, J. (2022). Decentralized Finance (DeFi) Projects: A Study of Key Performance Indicators in Terms of DeFi Protocols’ Valuations. International Journal of Financial Studies, 10(4), 108.
    10. Qin, K., Zhou, L., Afonin, Y., Lazzaretti, L., & Gervais, A. (2021). CeFi vs. DeFi--Comparing Centralized to Decentralized Finance. arXiv preprint arXiv:2106.08157.
    11. Razzaq, A., Mohsan, S. A. H., Ghayyur, S. A. K., Al-Kahtani, N., Alkahtani, H. K., & Mostafa, S. M. (2022, December). Blockchain in Healthcare: A Decentralized Platform for Digital Health Passport of COVID-19 Based on Vaccination and Immunity Certificates. In Healthcare (Vol. 10, No. 12, p. 2453). MDPI.
    12. Ren, F., Cai, M. L., Li, S. P., Xiong, X., & Chen, Z. H. (2022). A Multi-market Comparison of the Intraday Lead–Lag Relations Among Stock Index-Based Spot, Futures and Options. Computational Economics, 1-28.
    13. Wang, Y., Zuest, P., Yao, Y., Lu, Z., & Wattenhofer, R. (2022, April). Impact and User Perception of Sandwich Attacks in the DeFi Ecosystem. In Proceedings of the 2022 CHI Conference on Human Factors in Computing Systems (pp. 1-15).
    14. Zhou, L., Qin, K., Torres, C. F., Le, D. V., & Gervais, A. (2021, May). High-frequency trading on decentralized on-chain exchanges. In 2021 IEEE Symposium on Security and Privacy (SP) (pp. 428-445). IEEE.
    Description: 碩士
    國立政治大學
    資訊管理學系
    110356046
    Source URI: http://thesis.lib.nccu.edu.tw/record/#G0110356046
    Data Type: thesis
    Appears in Collections:[Department of MIS] Theses

    Files in This Item:

    File Description SizeFormat
    604601.pdf1400KbAdobe PDF20View/Open


    All items in 政大典藏 are protected by copyright, with all rights reserved.


    社群 sharing

    著作權政策宣告 Copyright Announcement
    1.本網站之數位內容為國立政治大學所收錄之機構典藏,無償提供學術研究與公眾教育等公益性使用,惟仍請適度,合理使用本網站之內容,以尊重著作權人之權益。商業上之利用,則請先取得著作權人之授權。
    The digital content of this website is part of National Chengchi University Institutional Repository. It provides free access to academic research and public education for non-commercial use. Please utilize it in a proper and reasonable manner and respect the rights of copyright owners. For commercial use, please obtain authorization from the copyright owner in advance.

    2.本網站之製作,已盡力防止侵害著作權人之權益,如仍發現本網站之數位內容有侵害著作權人權益情事者,請權利人通知本網站維護人員(nccur@nccu.edu.tw),維護人員將立即採取移除該數位著作等補救措施。
    NCCU Institutional Repository is made to protect the interests of copyright owners. If you believe that any material on the website infringes copyright, please contact our staff(nccur@nccu.edu.tw). We will remove the work from the repository and investigate your claim.
    DSpace Software Copyright © 2002-2004  MIT &  Hewlett-Packard  /   Enhanced by   NTU Library IR team Copyright ©   - Feedback