Padrões de Desenho para Contratos Inteligentes em Ethereum
Main Author: | |
---|---|
Publication Date: | 2019 |
Format: | Master thesis |
Language: | eng |
Source: | Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) |
Download full: | http://hdl.handle.net/10400.22/15609 |
Summary: | The invention of Bitcoin in 2008 offered a solution for a digital currency that could be used without a trusted third-party settling disputes over transactions. Bitcoin relied on a technology known as the blockchain, which can be described as a distributed database that relies on a consensus mechanism (generally Proof Of Work is employed) to be resilient against tampering. Ethereum, launched in 2015, leveraged the blockchain technology to augment the initial proposal of Bitcoin, enabling computational statements to be executed as part of each block validation. The platform offers a Turing-complete runtime environment (the Ethereum Virtual Machine), which can run smart contracts - scripts that verify and enforce the execution of predefined legal contracts. The technical development of smart contracts present significant challenges that are not well modeled by the current body of knowledge and practices of software engineering. In fact, some of the characteristic of blockchain make the contract execution uncontrollable by the programmer and immutable after deployment. Also, the potential security risks are considerable, since there is a large incentive to exploit vulnerabilities in a smart contract for financial gain. Considering the concerns presented above, the establishment of well understood and welldefined design patterns for the development of smart contracts is of paramount importance. In the realm of software engineering, design patterns are defined as generic and reusable solutions to common problems in software design. In the context of this work, a survey of design patterns that target the Ethereum framework was performed, with an extensive analysis regarding the context in which they can be employed, as well as implementations, examples and consequences of their use. A total of 11 design patterns were analysed. The design patterns identified for the Ethereum framework focus on several concerns specific to this platform – most of these concerns revolve around safety, upgradeability, and the limitations inherent to the sandboxed approach of the Ethereum Virtual Machine. A Decentralized Application (dApp) was created to showcase the employment of several of the identified contracts, and to highlight the value they can provide. This dApp offers a framework for decentralized betting in a trustless environment, where neither the user needs to trust the owner nor vice-versa. The dApp implements several use cases that are reliant on the identified design patterns. |
id |
RCAP_3f9ea39a106f80875fc38c82b9484b89 |
---|---|
oai_identifier_str |
oai:recipp.ipp.pt:10400.22/15609 |
network_acronym_str |
RCAP |
network_name_str |
Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) |
repository_id_str |
https://opendoar.ac.uk/repository/7160 |
spelling |
Padrões de Desenho para Contratos Inteligentes em EthereumDesign Patterns for Ethereum Smart ContractsBlockchainEthereumDesign patternsSmart contractsBlockchain software engineeringThe invention of Bitcoin in 2008 offered a solution for a digital currency that could be used without a trusted third-party settling disputes over transactions. Bitcoin relied on a technology known as the blockchain, which can be described as a distributed database that relies on a consensus mechanism (generally Proof Of Work is employed) to be resilient against tampering. Ethereum, launched in 2015, leveraged the blockchain technology to augment the initial proposal of Bitcoin, enabling computational statements to be executed as part of each block validation. The platform offers a Turing-complete runtime environment (the Ethereum Virtual Machine), which can run smart contracts - scripts that verify and enforce the execution of predefined legal contracts. The technical development of smart contracts present significant challenges that are not well modeled by the current body of knowledge and practices of software engineering. In fact, some of the characteristic of blockchain make the contract execution uncontrollable by the programmer and immutable after deployment. Also, the potential security risks are considerable, since there is a large incentive to exploit vulnerabilities in a smart contract for financial gain. Considering the concerns presented above, the establishment of well understood and welldefined design patterns for the development of smart contracts is of paramount importance. In the realm of software engineering, design patterns are defined as generic and reusable solutions to common problems in software design. In the context of this work, a survey of design patterns that target the Ethereum framework was performed, with an extensive analysis regarding the context in which they can be employed, as well as implementations, examples and consequences of their use. A total of 11 design patterns were analysed. The design patterns identified for the Ethereum framework focus on several concerns specific to this platform – most of these concerns revolve around safety, upgradeability, and the limitations inherent to the sandboxed approach of the Ethereum Virtual Machine. A Decentralized Application (dApp) was created to showcase the employment of several of the identified contracts, and to highlight the value they can provide. This dApp offers a framework for decentralized betting in a trustless environment, where neither the user needs to trust the owner nor vice-versa. The dApp implements several use cases that are reliant on the identified design patterns.Azevedo, Isabel de Fátima SilvaREPOSITÓRIO P.PORTOCosta, João Miguel Ribeiro da2020-11-06T01:30:21Z20192019-01-01T00:00:00Zinfo:eu-repo/semantics/publishedVersioninfo:eu-repo/semantics/masterThesisapplication/pdfhttp://hdl.handle.net/10400.22/15609urn:tid:202343022enginfo:eu-repo/semantics/openAccessreponame:Repositórios Científicos de Acesso Aberto de Portugal (RCAAP)instname:FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologiainstacron:RCAAP2025-03-07T10:07:51Zoai:recipp.ipp.pt:10400.22/15609Portal AgregadorONGhttps://www.rcaap.pt/oai/openaireinfo@rcaap.ptopendoar:https://opendoar.ac.uk/repository/71602025-05-29T00:34:47.089761Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) - FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologiafalse |
dc.title.none.fl_str_mv |
Padrões de Desenho para Contratos Inteligentes em Ethereum Design Patterns for Ethereum Smart Contracts |
title |
Padrões de Desenho para Contratos Inteligentes em Ethereum |
spellingShingle |
Padrões de Desenho para Contratos Inteligentes em Ethereum Costa, João Miguel Ribeiro da Blockchain Ethereum Design patterns Smart contracts Blockchain software engineering |
title_short |
Padrões de Desenho para Contratos Inteligentes em Ethereum |
title_full |
Padrões de Desenho para Contratos Inteligentes em Ethereum |
title_fullStr |
Padrões de Desenho para Contratos Inteligentes em Ethereum |
title_full_unstemmed |
Padrões de Desenho para Contratos Inteligentes em Ethereum |
title_sort |
Padrões de Desenho para Contratos Inteligentes em Ethereum |
author |
Costa, João Miguel Ribeiro da |
author_facet |
Costa, João Miguel Ribeiro da |
author_role |
author |
dc.contributor.none.fl_str_mv |
Azevedo, Isabel de Fátima Silva REPOSITÓRIO P.PORTO |
dc.contributor.author.fl_str_mv |
Costa, João Miguel Ribeiro da |
dc.subject.por.fl_str_mv |
Blockchain Ethereum Design patterns Smart contracts Blockchain software engineering |
topic |
Blockchain Ethereum Design patterns Smart contracts Blockchain software engineering |
description |
The invention of Bitcoin in 2008 offered a solution for a digital currency that could be used without a trusted third-party settling disputes over transactions. Bitcoin relied on a technology known as the blockchain, which can be described as a distributed database that relies on a consensus mechanism (generally Proof Of Work is employed) to be resilient against tampering. Ethereum, launched in 2015, leveraged the blockchain technology to augment the initial proposal of Bitcoin, enabling computational statements to be executed as part of each block validation. The platform offers a Turing-complete runtime environment (the Ethereum Virtual Machine), which can run smart contracts - scripts that verify and enforce the execution of predefined legal contracts. The technical development of smart contracts present significant challenges that are not well modeled by the current body of knowledge and practices of software engineering. In fact, some of the characteristic of blockchain make the contract execution uncontrollable by the programmer and immutable after deployment. Also, the potential security risks are considerable, since there is a large incentive to exploit vulnerabilities in a smart contract for financial gain. Considering the concerns presented above, the establishment of well understood and welldefined design patterns for the development of smart contracts is of paramount importance. In the realm of software engineering, design patterns are defined as generic and reusable solutions to common problems in software design. In the context of this work, a survey of design patterns that target the Ethereum framework was performed, with an extensive analysis regarding the context in which they can be employed, as well as implementations, examples and consequences of their use. A total of 11 design patterns were analysed. The design patterns identified for the Ethereum framework focus on several concerns specific to this platform – most of these concerns revolve around safety, upgradeability, and the limitations inherent to the sandboxed approach of the Ethereum Virtual Machine. A Decentralized Application (dApp) was created to showcase the employment of several of the identified contracts, and to highlight the value they can provide. This dApp offers a framework for decentralized betting in a trustless environment, where neither the user needs to trust the owner nor vice-versa. The dApp implements several use cases that are reliant on the identified design patterns. |
publishDate |
2019 |
dc.date.none.fl_str_mv |
2019 2019-01-01T00:00:00Z 2020-11-06T01:30:21Z |
dc.type.status.fl_str_mv |
info:eu-repo/semantics/publishedVersion |
dc.type.driver.fl_str_mv |
info:eu-repo/semantics/masterThesis |
format |
masterThesis |
status_str |
publishedVersion |
dc.identifier.uri.fl_str_mv |
http://hdl.handle.net/10400.22/15609 urn:tid:202343022 |
url |
http://hdl.handle.net/10400.22/15609 |
identifier_str_mv |
urn:tid:202343022 |
dc.language.iso.fl_str_mv |
eng |
language |
eng |
dc.rights.driver.fl_str_mv |
info:eu-repo/semantics/openAccess |
eu_rights_str_mv |
openAccess |
dc.format.none.fl_str_mv |
application/pdf |
dc.source.none.fl_str_mv |
reponame:Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) instname:FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia instacron:RCAAP |
instname_str |
FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia |
instacron_str |
RCAAP |
institution |
RCAAP |
reponame_str |
Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) |
collection |
Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) |
repository.name.fl_str_mv |
Repositórios Científicos de Acesso Aberto de Portugal (RCAAP) - FCCN, serviços digitais da FCT – Fundação para a Ciência e a Tecnologia |
repository.mail.fl_str_mv |
info@rcaap.pt |
_version_ |
1833600601842253824 |