Älykkään sopimuksen kehitysprosessi Hyperledger Fabric -lohkoketjuympäristöön
Tikkanen, Henri (2022)
Tikkanen, Henri
2022
Julkaisun pysyvä osoite on
https://urn.fi/URN:NBN:fi:amk-202205108344
https://urn.fi/URN:NBN:fi:amk-202205108344
Tiivistelmä
Tämän opinnäytetyön tavoitteena oli tuottaa ensisijaisesti kokemusperäistä tietoa älykkään sopimuksen kehittämisestä Hyperledger Fabric -lohkoketjuympäristössä. Aihetta lähestyttiin ensin yleisen teorian kautta, josta siirryttiin tutkimaan älykkään sopimuksen kehitysprosessia kokonaisuudessaan, tarvittavia työvälineitä ja saatavilla olevaa lähdemateriaalia. Lopuksi toteutettiin älykäs sopimus hypoteettiseen finanssialan toimijaan liittyvän toimeksiannon perusteella ja implementointiin se lohkoketjuverkkoon.
Järjestelmään tutustumisen ja älykkään sopimuksen toteutuksen tukena käytettiin Hyperledger Fabricin tarjoamaa laajaa dokumentaatiota ja Fabric-testiverkkoa vapaasti ladattavine esimerkkeineen. Älykkään sopimuksen ohjelmointiin käytettiin JavaScript-kieltä. Fabric-testiverkon toimintaa kuvaavat kappaleet toteutettiin siten, että koko prosessi olisi toistettavissa esimerkkejä tarkasti seuraamalla. Varsinaisen älykkään sopimuksen kehitys toteutettiin puolestaan siten, että prosessi ja sen raportointi muodostivat sisällöllisen jatkumon aiemmille kappaleille.
Opinnäytetyössä havaittiin, että luotettavaa tietoa aiheesta oli kohtuullisen helposti saatavilla, mutta tieto oli kuitenkin verrattain kapea-alaista, painottuen Hyperledger-projektin julkaisemaan sisältöön. Myös suomenkielistä lähdemateriaalia löytyi suhteellisen niukasti. Merkittäviksi hidasteiksi Hyperledger Fabric -järjestelmän yleistymisen kannalta arveltiin mm. osaajapulaa ja järjestelmän profiloitumista vaativiin yritysmaailman toteutuksiin.
Lisäksi voitiin todeta, että onnistuttiin luomaan yksinkertainen konseptitodistus älykkään sopimuksen käyttämisestä määriteltyyn tarkoitukseen, joka toteutti sille asetetut vaatimukset tämän opinnäytetyön keskeisten tutkimustavoitteiden kontekstissa. Kun yhdisteltiin prosessin aikana kertynyttä teoriatietoa ja kokemuksia älykkään sopimuksen kehittämisestä Fabric-testiverkkoon, oli mahdollista tehdä tiettyjä johtopäätöksiä vastauksena tutkimusasetelmaan. Suhteessa muihin lohkoketjuteknologioihin, keskeisiksi Hyperledger Fabric -järjestelmän valintaa tukeviksi tekijöiksi nousivat yksityisyys ja yleinen tietoturvallisuus. Kun verrattiin perinteisiin järjestelmiin, todettiin lohkoketjuteknologiaan sisältyvän tiedon hajautuksen tarjoavan keskeisen turvallisuusedun kuvatun toimeksiannon tapauksessa, mutta toisaalta vaativan, että hajautus osataan käytännössä toteuttaa tarkoituksenmukaisella tavalla. The objective of this thesis was primarily to produce experiential information about the development process of smart contracts in the Hyperledger Fabric blockchain platform. The topic was first approached through general theory, followed by the development process of smart contracts studied as a whole, the tools required and the available source materials. Finally, a smart contract was implemented on the basis of an assignment related to a hypothetical financial operator and implemented in the blockchain network.
Extensive documentation provided by Hyperledger Fabric and the Fabric test network with freely downloadable examples were used to support the introduction of the system and the implementation of the smart contract. The JavaScript language was used to program the smart contract. The sections describing the operation of the Fabric test network were implemented in such a way that the whole process could be reproduced by closely following the examples. The process and reporting of developing the actual smart contract logically based on the previous paragraphs.
It was found in the thesis that reliable information on the topic was reasonably easily available, but the information was still relatively narrow as it was mainly published by the Hyperledger project itself. The source material in Finnish was also relatively scarce. As significant slowdowns in the spread of the Hyperledger Fabric system were considered to be e.g. a shortage of experts and focus on demanding enterprise-grade implementations.
In addition, it was found that a simple proof of concept for the use of smart contracts for a defined purpose was successfully created and it met the requirements set for it in the context of the main research objectives of this thesis. By combining theoretical knowledge and practical experience gained during the process, it was possible to draw conclusions in response to the research agenda. Compared to other blockchain platforms, privacy and general security appeared to be key factors supporting the choice of Hyperledger Fabric. Compared to traditional systems, the decentralization of data was found to provide a key security benefit in the case of the task described, but on the other hand it required that the decentralization be implemented in an appropriate manner.
Järjestelmään tutustumisen ja älykkään sopimuksen toteutuksen tukena käytettiin Hyperledger Fabricin tarjoamaa laajaa dokumentaatiota ja Fabric-testiverkkoa vapaasti ladattavine esimerkkeineen. Älykkään sopimuksen ohjelmointiin käytettiin JavaScript-kieltä. Fabric-testiverkon toimintaa kuvaavat kappaleet toteutettiin siten, että koko prosessi olisi toistettavissa esimerkkejä tarkasti seuraamalla. Varsinaisen älykkään sopimuksen kehitys toteutettiin puolestaan siten, että prosessi ja sen raportointi muodostivat sisällöllisen jatkumon aiemmille kappaleille.
Opinnäytetyössä havaittiin, että luotettavaa tietoa aiheesta oli kohtuullisen helposti saatavilla, mutta tieto oli kuitenkin verrattain kapea-alaista, painottuen Hyperledger-projektin julkaisemaan sisältöön. Myös suomenkielistä lähdemateriaalia löytyi suhteellisen niukasti. Merkittäviksi hidasteiksi Hyperledger Fabric -järjestelmän yleistymisen kannalta arveltiin mm. osaajapulaa ja järjestelmän profiloitumista vaativiin yritysmaailman toteutuksiin.
Lisäksi voitiin todeta, että onnistuttiin luomaan yksinkertainen konseptitodistus älykkään sopimuksen käyttämisestä määriteltyyn tarkoitukseen, joka toteutti sille asetetut vaatimukset tämän opinnäytetyön keskeisten tutkimustavoitteiden kontekstissa. Kun yhdisteltiin prosessin aikana kertynyttä teoriatietoa ja kokemuksia älykkään sopimuksen kehittämisestä Fabric-testiverkkoon, oli mahdollista tehdä tiettyjä johtopäätöksiä vastauksena tutkimusasetelmaan. Suhteessa muihin lohkoketjuteknologioihin, keskeisiksi Hyperledger Fabric -järjestelmän valintaa tukeviksi tekijöiksi nousivat yksityisyys ja yleinen tietoturvallisuus. Kun verrattiin perinteisiin järjestelmiin, todettiin lohkoketjuteknologiaan sisältyvän tiedon hajautuksen tarjoavan keskeisen turvallisuusedun kuvatun toimeksiannon tapauksessa, mutta toisaalta vaativan, että hajautus osataan käytännössä toteuttaa tarkoituksenmukaisella tavalla.
Extensive documentation provided by Hyperledger Fabric and the Fabric test network with freely downloadable examples were used to support the introduction of the system and the implementation of the smart contract. The JavaScript language was used to program the smart contract. The sections describing the operation of the Fabric test network were implemented in such a way that the whole process could be reproduced by closely following the examples. The process and reporting of developing the actual smart contract logically based on the previous paragraphs.
It was found in the thesis that reliable information on the topic was reasonably easily available, but the information was still relatively narrow as it was mainly published by the Hyperledger project itself. The source material in Finnish was also relatively scarce. As significant slowdowns in the spread of the Hyperledger Fabric system were considered to be e.g. a shortage of experts and focus on demanding enterprise-grade implementations.
In addition, it was found that a simple proof of concept for the use of smart contracts for a defined purpose was successfully created and it met the requirements set for it in the context of the main research objectives of this thesis. By combining theoretical knowledge and practical experience gained during the process, it was possible to draw conclusions in response to the research agenda. Compared to other blockchain platforms, privacy and general security appeared to be key factors supporting the choice of Hyperledger Fabric. Compared to traditional systems, the decentralization of data was found to provide a key security benefit in the case of the task described, but on the other hand it required that the decentralization be implemented in an appropriate manner.