{"id":27933088,"url":"https://github.com/buzzcosm/udemy-course-blockchain-technology-in-java-1","last_synced_at":"2025-10-30T23:43:32.356Z","repository":{"id":291473060,"uuid":"977663547","full_name":"buzzcosm/udemy-course-blockchain-technology-in-java-1","owner":"buzzcosm","description":"Udemy course - Blockchain \u0026 Cryptocurrency in Java","archived":false,"fork":false,"pushed_at":"2025-05-05T20:54:32.000Z","size":16,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-02T03:47:49.993Z","etag":null,"topics":["blockchain","blockchain-demos","blockchain-technology","cryprocurrency","cryptography","java","udemy-course-project"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/buzzcosm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-04T17:56:45.000Z","updated_at":"2025-05-05T20:54:35.000Z","dependencies_parsed_at":"2025-06-01T18:38:02.115Z","dependency_job_id":"b5ec603f-4b60-4dee-a339-32fb4180ff39","html_url":"https://github.com/buzzcosm/udemy-course-blockchain-technology-in-java-1","commit_stats":null,"previous_names":["buzzcosm/udemy-course-blockchain-technology-in-java-1"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/buzzcosm/udemy-course-blockchain-technology-in-java-1","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buzzcosm%2Fudemy-course-blockchain-technology-in-java-1","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buzzcosm%2Fudemy-course-blockchain-technology-in-java-1/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buzzcosm%2Fudemy-course-blockchain-technology-in-java-1/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buzzcosm%2Fudemy-course-blockchain-technology-in-java-1/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/buzzcosm","download_url":"https://codeload.github.com/buzzcosm/udemy-course-blockchain-technology-in-java-1/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/buzzcosm%2Fudemy-course-blockchain-technology-in-java-1/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267644724,"owners_count":24120866,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-29T02:00:12.549Z","response_time":2574,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["blockchain","blockchain-demos","blockchain-technology","cryprocurrency","cryptography","java","udemy-course-project"],"created_at":"2025-05-07T04:27:22.067Z","updated_at":"2025-10-30T23:43:32.292Z","avatar_url":"https://github.com/buzzcosm.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Udemy course - Blockchain\n\n[learn blockchain technology in java](https://www.udemy.com/course/learn-blockchain-technology-in-java)\n\n## Blockchain Theory and Implementation\n\nImportant Classes:\n\n- [Block](./src/main/java/com/buzzcosm/blockchain/demo/Block.java)\n- [Blockchain](./src/main/java/com/buzzcosm/blockchain/demo/Blockchain.java)\n- [Miner](./src/main/java/com/buzzcosm/blockchain/demo/Miner.java)\n\n### Proof of work (PoW) - Algorithm\n\n```java\n        // This is a proof of work (PoW)\n        while (!isGoldenHash(block)) {\n            block.incrementNonce();\n            block.generateHash();\n        }\n```\n\n**Important terms:**\n\n- **nonce**: number of tries to find a valid hash\n- **difficulty**: number of leading zeros in hash\n- **hash**: unique identifier of block\n- **genesis block**: first block in blockchain\n\n## Cryptocurrency\n\n**Important terms:**\n\n- **mempool**: transactions that have not been included in a block yet\n  - mempool **stores the transactions** until a given miner verifies them and puts them into a block\n  - similar to producer - consumer method\n- **miner**: person who mines blocks\n- **transaction**: transfer of funds between two parties\n- **pre-verified** *transactions*: transactions that have already been verified and added to a block\n- **transaction fee**: fee that is paid to the miner for including a transaction in a block\n- **Merkle-Trees** Solution: https://en.wikipedia.org/wiki/Merkle_tree\n  - Merkle-Root\n- Public \u0026 Private Key Cryptography\n  - Public Key Cryptography: https://en.wikipedia.org/wiki/Public-key_cryptography\n  - Private Key Cryptography: https://en.wikipedia.org/wiki/Private-key_cryptography\n- Bitcoin: https://en.wikipedia.org/wiki/Bitcoin\n  - bitcoin protocol: https://en.bitcoin.it/wiki/Protocol_specification\n  - ECDSA (Elliptic Curve Digital Signature Algorithm): https://en.wikipedia.org/wiki/Elliptic_Curve_Digital_Signature_Algorithm\n- Elliptic Curve Cryptography: https://en.wikipedia.org/wiki/Elliptic_Curve_Cryptography\n- UTXOs (Unspent Transaction Output): https://en.wikipedia.org/wiki/Unspent_transaction_output\n- Crypto Wallets: https://en.wikipedia.org/wiki/Crypto_wallet\n- RIPEMD: https://en.wikipedia.org/wiki/RIPEMD\n- 51% Attack: https://bitcoinwiki.org/wiki/51-attack\n- competing chains problems\n- double spending problems\n- orphaned blocks \u0026 block verification\n- Mining \u0026 Inflation\n- Transaction Fees\n- Blockchain Forks\n  - Soft Fork\n  - Hard Fork\n\n\u003e MINER'S REWARD = X BTC + TRANSACTION FEES\n\n\u003e TRANSACTION INPUT AMOUNT = TRANSACTION OUTPUT AMOUNT + MINER'S REWARD\n\n### 51% Attack\n\n- [YouTube: Was ist eine 51% Attacke? Einfach erklärt für Anfänger](https://www.youtube.com/watch?v=Dk3TrnU8kJU)\n\nA 51% attack in blockchain refers to an attack where an attacker gains control of more than 50% of the network's hash rate, allowing them to manipulate the blockchain. This control enables them to alter transactions, double-spend funds, and potentially disrupt the entire network.\n\n#### How a 51% attack works\n\n1. Acquire control:  \n   The attacker gathers enough computational power (hash rate) to surpass the network's majority.\n2. Manipulate transactions:  \n   They can then alter the order of transactions, prevent some from being confirmed, or even reverse valid transactions.\n3. Double-spending:  \n   The attacker can create a separate, fraudulent blockchain branch, which they can then broadcast to the network to invalidate the original transactions.\n4. Disruption and loss of trust:  \n   Successful 51% attacks can lead to double-spending, network instability, and a loss of trust in the cryptocurrency or blockchain. \n\nExamples:\n\n**Double-spending:**\n\nAn attacker could spend the same cryptocurrency twice, once in a real transaction and once on a fraudulent chain they create.\n\n**Transaction manipulation:**\n\nThey could delay or prevent the confirmation of legitimate transactions, disrupting commerce.\n\n**Block withholding:**\n\nAttackers could mine blocks but withhold them from the network, leading to delays in block propagation and transaction confirmations. \n\n#### Key takeaways\n\n- A 51% attack poses a significant threat to Proof-of-Work (PoW) blockchain networks.\n- The more hash rate a blockchain possesses, the harder it is to successfully launch a 51% attack.\n- Successfully overcoming a 51% attack can be costly for the blockchain network and its users, leading to loss of trust and potential economic damage. ","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuzzcosm%2Fudemy-course-blockchain-technology-in-java-1","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbuzzcosm%2Fudemy-course-blockchain-technology-in-java-1","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuzzcosm%2Fudemy-course-blockchain-technology-in-java-1/lists"}