Category: Blockchain

  • Simple Blockchain Implementation

    Introduction We have implemented a node that is part of a blockchain-based decentralized consensus algorithm. The program is designed to receive transactions and blocks as input and maintain an updated blockchain. This is one of the programming assignments from Princeton University’s course, “Bitcoin and Cryptocurrency Technologies.” Blockchain Structure Since multiple forks may exist in a…

  • Implementation of Trust-Based Consensus Algorithm

    We have implemented one of the consensus mechanisms in distributed network systems. This is one of the programming assignments from the Princeton University course, “Bitcoin and Cryptocurrency Technologies.” Trust Graph Between Nodes The task involves implementing a distributed consensus algorithm given a trust graph between nodes. This algorithm counteracts Sybil attacks*1 and provides an alternative…

  • Consensus Algorithm in Bitcoin Part 2

    This section explains why Bitcoin’s consensus algorithm functions effectively in practice, considering potential attackers (malicious nodes). Consensus Formation Through the Longest Chain Rule In the Bitcoin blockchain⛓️, miners, including malicious ones, autonomously extend the chain. Inevitably, chain forks occur, but Bitcoin enforces a rule that only the longest chain is considered valid*1. This rule allows…

  • Consensus Algorithm in Bitcoin Part 1

    Distributed Network Systems and the Byzantine Generals Problem In distributed network systems, achieving consensus involves addressing the Byzantine Generals Problem. It has been shown in the context of Decentralized Consensus Formation and the Byzantine Generals Problem that if more than one-third of the nodes are malicious, reaching consensus is impossible. Even when the Byzantine Generals…

  • Decentralized Consensus Formation and the Byzantine Generals Problem

    Overview of the Byzantine Generals Problem A well-known issue in decentralized network systems is the Byzantine Generals Problem (Byzantine Fault). This problem addresses consensus formation in decentralized network systems and was formalized in 1982 by Leslie Lamport and his colleagues: Leslie Lamport, Robert Shostak, and Marshall Pease, The Byzantine Generals Problem, SRI International, 1982. Leslie…