Technical Background
Overview
This Web Application has been initially build by Instinctools based on a design proposal by myself.
Important: Is running on the Eterherum Rinkby Testnet.
Every Blockchain application must connect to a Node, that keeps the Blockchain database. This Demo-Page is using an Infura service - a WebService that provides Node-Functionality via a standardized API.
The Application Logic, the Wallet (that keeps the private key), Hash Calculation is downloaded as Javascript from a WebServer. So it can be checked and read by everybody. It using Angular JS as a framwork to build dynamic Webpages.
To communicate with the Infura Node a Javascript-Library https://github.com/ethereum/wiki/wiki/JavaScript-API called WEB3 is downloaded with the Page. It includes functions to create and write a transaction in the Blockchain.
The Wallet is a complex application and provides a mechanism to sign the transactions with the private key. I am using the eth-lightwallet.
Fuel Server
Every transaction on the Ethereum Blockchain must be paid with Ether (that is digital currency). In this application you will not need to buy Ether, as this is done already. A FuelServer is receiving your signed-transaction (he can never change your transaction), reading your public address and sending some Ether to it. Only after the Ether is sent to your address it is sending your signed transaction to the Blockchain. Further logic can be build into the FuelServer to prevent fraud and misuse.
Smart Contracts
When uploading the Hash to the Blockchain, the logic on the Chain is implemented in a Smart Contract: https://rinkeby.etherscan.io/address/0xF95034a99F06676313Aa10f7e67a5d1C253a1687#code
The Smart Contract has basically 2 functions:
- Upload a Hash (called asset): Perform validation and store Owner of the Asset and Hash into the Blockchain
- Read a Hash: Read the Hash from the Blockchain and return owner information
This Smart Contract is very simple and not programmed well -only for testing purposes.
Source Code
All Source Code is OpenSource and can be downloaded from GitHub: https://github.com/happychriss/BC_Certifier
Cloud Solution
The Webapplication is hosted at Heroku. The entire Webpage is build with WordPress.
0 Kommentare