Skip to main content
Make it clear that KECCAK-256 is not the "original" padding proposed by the Keccak team (which was more complicated---see the version 2 submission) but rather the version 3 submission. Also link to the version 3 submission pdf.
Source Link

Ethereum uses KECCAK-256. It should be noted that it does not follow the FIPS-202 based standard (a.k.a SHA-3), which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = KECCAK [512] (M || 01, 256);. whichThis was different thanfrom the original padding proposed by the Keccak team in The Keccak SHA-3 submission version 3 (final, winning version). It seems that now people The difference is the additional '01' bits appended to the message. People are now calling the "original" SHA3"submitted version 3" SHA-3 Keccak hashing "Keccak" and the newfinalized NIST SHA3SHA-3 standard as "SHA-3".

Using this online generator and the Solidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

Ethereum uses KECCAK-256. It should be noted that it does not follow the FIPS-202 based standard (a.k.a SHA-3), which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = KECCAK [512] (M || 01, 256); which was different than the original padding proposed by the Keccak team. It seems that now people are calling the "original" SHA3 Keccak hashing "Keccak" and the new NIST SHA3 standard as "SHA-3".

Using this online generator and the Solidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

Ethereum uses KECCAK-256. It should be noted that it does not follow the FIPS-202 based standard (a.k.a SHA-3), which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = KECCAK [512] (M || 01, 256). This was different from the padding proposed by the Keccak team in The Keccak SHA-3 submission version 3 (final, winning version). The difference is the additional '01' bits appended to the message. People are now calling the "submitted version 3" SHA-3 Keccak hashing "Keccak" and the finalized NIST SHA-3 standard "SHA-3".

Using this online generator and the Solidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

Updated online compiler example to latest online Solidity website.
Source Link
Hudson Jameson
  • 4.7k
  • 2
  • 23
  • 34

Ethereum uses KECCAK-256. It should be noted that it does not follow the FIPS-202 based standard (a.k.a SHA-3), which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = KECCAK [512] (M || 01, 256); which was different than the original padding proposed by the Keccak team. It seems that now people are calling the "original" SHA3 Keccak hashing "Keccak" and the new NIST SHA3 standard as "SHA-3".

Using this online generator and the Solidity Online CompilerSolidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in SolidityEthereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

Ethereum uses KECCAK-256. It should be noted that it does not follow the FIPS-202 based standard (a.k.a SHA-3), which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = KECCAK [512] (M || 01, 256); which was different than the original padding proposed by the Keccak team. It seems that now people are calling the "original" SHA3 Keccak hashing "Keccak" and the new NIST SHA3 standard as "SHA-3".

Using this online generator and the Solidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

Ethereum uses KECCAK-256. It should be noted that it does not follow the FIPS-202 based standard (a.k.a SHA-3), which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = KECCAK [512] (M || 01, 256); which was different than the original padding proposed by the Keccak team. It seems that now people are calling the "original" SHA3 Keccak hashing "Keccak" and the new NIST SHA3 standard as "SHA-3".

Using this online generator and the Solidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

added 17 characters in body
Source Link
Hudson Jameson
  • 4.7k
  • 2
  • 23
  • 34

Ethereum uses KECCAK SHA3-256. It should be noted that it does not follow the FIPS-202 based standard (a.k.a SHA-3), which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = K ECCAKKECCAK [512] (M || 01, 256); which was diferentdifferent than the original padding proposed by the Keccak team. It seems that now people are calling the "original" SHA3-Keccak Keccak hashing "Keccak" and the new NIST SHA3 standard as "SHA-3".

Using this online generator and the Solidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

Ethereum uses KECCAK SHA3-256. It should be noted that it does not follow the FIPS-202 based standard, which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = K ECCAK [512] (M || 01, 256); which was diferent than the original padding proposed by the Keccak team. It seems that now people are calling the "original" SHA3-Keccak "Keccak" and the new NIST SHA3 standard as "SHA-3".

Using this online generator and the Solidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

Ethereum uses KECCAK-256. It should be noted that it does not follow the FIPS-202 based standard (a.k.a SHA-3), which was finalized in August 2015.

According to this, NIST changed the padding to SHA3-256(M) = KECCAK [512] (M || 01, 256); which was different than the original padding proposed by the Keccak team. It seems that now people are calling the "original" SHA3 Keccak hashing "Keccak" and the new NIST SHA3 standard as "SHA-3".

Using this online generator and the Solidity Online Compiler, I tested the difference between Keccak-256 and SHA3-256. I hashed the word testing using Ethereum and the 2 SHA3 hashing algorithms:

Ethereum SHA3 function in Solidity = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

Keccak-256 = 5f16f4c7f149ac4f9510d9cf8cf384038ad348b3bcdc01915f95de12df9d1b02

SHA3-256 (NIST Standard) = 7f5979fb78f082e8b1c676635db8795c4ac6faba03525fb708cb5fd68fd40c5e

Source Link
Hudson Jameson
  • 4.7k
  • 2
  • 23
  • 34
Loading