Overview of RIPEMD-160
Last updated
Last updated
The other underlying good hash function used in Bitcoin is RIPEMD-160. And again, although it's not required in order to gain an understanding of how Bitcoin works, it can be very helpful to see a working example implementation.
Note: This implementation is for informational purposes only. It has not been optimized or rigorously tested and should therefore not be used in a production environment. As a general rule, you should only ever use a rigorously tested and widely accepted implementation of any hash function.
Source Code can be found here: https://github.com/jakeBitcoinAssociation/hash-functions
Like SHA-256, RIPEMD-160 follows a Merkle Damgaard construction and can be split into three parts:
Input and Processing
Input
Message block construction
Message schedule construction
Compression
Initialization of working variables
Computation of temporary words and mutation of working variables
Integrate computed and mutated working variables with initial values
Final value construction and output