Implementing DNS with Blockchain Technology
- Make sure your computer comes with Python 3
- If not, go to
https://www.python.org/downloads/to download your Python now !
- Clone this repo to your local machine
Using git command line
git clone https://github.com/southzyzy/DnStack
- Install the required dependencies
Using python3-pip
pip3 install pandas gevent flask flask-wtf pycryptodomeDnStack is following the concept of Blockstack DNS (BNS). The idea is listed in their documentation and DnStack is a Proof-of-Concept (POC) on how BNS works.
Read More
The whole point of Blockchains is that they should be decentralized. And if they’re decentralized, how on earth do we ensure that they all reflect the same chain? This is called the problem of Consensus, and we’ll have to implement a Consensus Algorithm if we want more than one node in our network.
We then implement this Consensus Algorithm call Proof-of-Work (POW).
"Proof-of-work is essentially one-CPU-one-vote. The majority decision is represented by the longest chain, which has the greatest proof-of-work effort invested in it. If a majority of CPU power is controlled by honest nodes, the honest chain will grow the fastest and outpace any competing chains."
In other words, the longest chain on the network is the de-facto one. Using this algorithm, we reach Consensus amongst the nodes in our network.
This project requires the following script to operate:
- Broker.py
- run.py (Web UI of Broker) (Optional to run)
- miner.py
- alice.py
- bob.py
This is the Broker script that handles the traffic flow, and the main leader for our Blockchain.
python3 broker.py
Web UI for the Broker program, to access go to
http://localhost:1337
python3 run.py
Mining program to calculate Proofs for nodes and communicates with the Broker.
python3 miner.py
Nodes in our DnStack network.
python3 alice.py
python3 bob.py
| Gerald Peh | Tan Zhao Yea |
|---|---|
github.com/hellogeraldpeh |
github.com/southzyzy |

