This is a demo blockchain contains features such as Proof of Work(PoW) [with specific difficulty], signing transactions(with private key), verifying transactions(with public key), etc.
Made using TypeScript, also compiled down to javascript.
You can check the typescript source code in ./src.
- Proof of Work(PoW) [with specific difficulty].
- Create public/private keys.
- Signing transactions(with private key).
- Verifying transactions(with public key).
- Checking the balance of a specific address.
- Checking the validity of the blockchain.
- Visualizing the whole blockchain.
git clone https://github.com/SD170/blockchain-ronaldo-coin
On the project root folder, run:
npm install
You can run the project easily by using:
npm start
You can generate a new public/private key pair
node ./dist/keyGen.js
Now you can test it in the ./dist/server.js.
Used a few libraries, few of them we're needed for development only:
- crypto-js - For using related important algorithms such as SHA256.
- elliptic - To use EC algorithms for creating Public/Private keys, sign/verify transactions.
- typescript(Dev) - Used as the base language.
- ts-node(Dev) - TypeScript execution and REPL for node.js.
- node.js - To run the compiled JS.