How Does the Blockchain Verify That the ‘Reveal’ Matches the Original ‘Commitment’?
The verification is performed by a smart contract on the blockchain. When the user submits the 'reveal' (the original transaction details plus the secret salt), the smart contract executes the same hashing algorithm used in the commitment step.
It hashes the revealed details and the salt. If the newly calculated hash matches the original 'commitment' hash stored on the blockchain, the contract verifies the authenticity and executes the transaction.