Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat!: impl final tari pow algorithm #4862

Merged
merged 3 commits into from
Nov 3, 2022
Merged

feat!: impl final tari pow algorithm #4862

merged 3 commits into from
Nov 3, 2022

Commits on Oct 27, 2022

  1. feat: impl final tari pow algorithm

    Tari's independent proof-of-work algorithm is very straightforward.
    
    Calculate the _triple hash_ of the following input data:
     - Nonce (8 bytes)
     - Tari mining hash (32 bytes)
     - PoW record (for Sha-3x, this is always a single byte of value 1)
    
    That is, the nonce in little-endian format, mining hash and the PoW record are chained together and hashed by the
    Keccak Sha3-256 algorithm. The result is hashed again, and this result is hashed a third time. The result of the third
    hash is compared to the target value of the current block difficulty.
    
    A triple hash is selected to keep the requirements on hardware miners (FPGAs, ASICs) fairly low. But we also want to
    avoid making the proof-of-work immediately "NiceHashable". There are several coins that already use a single or
    double SHA3 hash, and we'd like to avoid having that hashrate immediately deployable against Tari.
    
    This PR also stabilises RFC-0131
    CjS77 committed Oct 27, 2022
    Configuration menu
    Copy the full SHA
    42cc767 View commit details
    Browse the repository at this point in the history

Commits on Oct 28, 2022

  1. fix: mining_test_difficulty

    CjS77 committed Oct 28, 2022
    Configuration menu
    Copy the full SHA
    d109371 View commit details
    Browse the repository at this point in the history

Commits on Nov 3, 2022

  1. feat: update to version for PoW (#4875)

    Description
    ---
    Updates the header version to change the PoW so we don't have to reset the chain
    
    Motivation and Context
    ---
    See: #4862 
    
    How Has This Been Tested?
    ---
    SWvheerden committed Nov 3, 2022
    Configuration menu
    Copy the full SHA
    889118b View commit details
    Browse the repository at this point in the history