This repository contains the curriculum for various courses offered by Hxckr. Each course is organized into a dedicated folder, with the curriculum stored in a markdown file.
Code Exercise: Implement code to generate a mnemonic phrase using BIP39. Allow the user to input an optional passphrase. Convert the mnemonic phrase into a seed for use in an HD wallet.
3. Hierarchical Deterministic Wallets (BIP32/BIP44) and Derivation Paths
Objective: Implement HD wallets with proper derivation paths for organized key management.
Code Exercise: Extend your wallet to implement an HD wallet using the seed from the mnemonic phrase. Follow BIP44 to define standard derivation paths and generate multiple accounts and addresses. Provide functionality to derive keys and addresses at various levels (account, change, address index).
4. Creating Bitcoin Addresses
Objective: Convert public keys into Bitcoin addresses.
Topics:
[x] Hashing public keys with SHA-256 and RIPEMD-160
[x] Understanding the Base58Check encoding scheme
[x] Generating different types of addresses (P2PKH, P2SH, Bech32)
Code Exercise: Implement code that takes a public key and produces a Bitcoin address using Base58Check encoding. Extend it to generate a Bech32 (SegWit) address.
5. Secure Storage of Private Keys
Objective: Implement secure methods for storing private keys.
Topics:
[x] Importance of private key security
[x] Encrypting private keys (e.g., using AES)
[x] Storing keys in encrypted files or secure databases
Code Exercise: Extend your program to encrypt the mnemonic seed with a user-provided passphrase and store it securely. Include functionality to decrypt and load the seed when needed to derive keys and addresses.
6. Building the Wallet Interface
Objective: Create a user interface for interacting with your wallet.
Topics:
[x] Designing a command-line or graphical interface
[x] Displaying wallet information (addresses, balances)
Resources:
Exercise:
Code Exercise: Build a simple interface that allows users to unlock the wallet using their passphrase and view their bitcoin addresses.
7. Connecting to the Bitcoin Network
Objective: Enable your wallet to communicate with the Bitcoin network.
Topics:
[x] Understanding how nodes interact in the network
[x] Using APIs to access blockchain data (e.g., BlockCypher, Blockchain.info, mempool.space)
[x] Optional: Running a Bitcoin full node and using JSON-RPC
Code Exercise: Write code to create a raw Bitcoin transaction sending funds from your wallet to another address. Implement the signing process and output the raw signed transaction in hexadecimal format.
10. Broadcasting Transactions
Objective: Send your signed transactions to the Bitcoin network.
Topics:
[x] Using APIs or a full node to broadcast transactions
Code Exercise: Write code that listens for incoming transactions to your wallet addresses and updates the balance and transaction history in real-time.
12. Enhancing Wallet Security
Objective: Implement advanced security features to protect user funds.
Work In Progress
Course Title: Build a Bitcoin Wallet from Scratch Modules:
1. Generating Private and Public Keys
Objective: Implement code to generate valid Bitcoin private keys and derive public keys.
Topics:
Resources:
Exercise:
2. Implementing Mnemonic Phrases (BIP39)
Objective: Understand and implement mnemonic phrases for seed generation and wallet backup.
Topics:
Resources:
Exercise:
3. Hierarchical Deterministic Wallets (BIP32/BIP44) and Derivation Paths
Objective: Implement HD wallets with proper derivation paths for organized key management.
Topics:
Resources:
Exercise:
4. Creating Bitcoin Addresses
Objective: Convert public keys into Bitcoin addresses.
Topics:
Resources:
Exercise:
5. Secure Storage of Private Keys
Objective: Implement secure methods for storing private keys.
Topics:
Resources:
Exercise:
6. Building the Wallet Interface
Objective: Create a user interface for interacting with your wallet.
Topics:
Resources:
Exercise:
7. Connecting to the Bitcoin Network
Objective: Enable your wallet to communicate with the Bitcoin network.
Topics:
Resources:
Exercise:
8. Retrieving and Parsing Blockchain Data
Objective: Fetch and process blockchain data relevant to your wallet.
Topics:
Resources:
Exercise:
9. Transaction Creation and Signing
Todo: refer to the transactions course and break these topics into smaller modules
Objective: Implement the ability to create and sign Bitcoin transactions.
Topics:
Resources:
Exercise:
10. Broadcasting Transactions
Objective: Send your signed transactions to the Bitcoin network.
Topics:
Resources:
Exercise:
11. Handling Incoming Transactions
Objective: Update wallet state based on incoming transactions.
Topics:
Resources:
Exercise:
12. Enhancing Wallet Security
Objective: Implement advanced security features to protect user funds.
Topics:
Resources:
Exercise: