Cryptographic hash: Difference between revisions

From Computer Science Wiki
No edit summary
No edit summary
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[file:computation.png|right|frame|Computational thinking, problem-solving and programming<ref>http://www.flaticon.com/</ref>]]
[[file:computation.png|right|frame|Computational thinking, problem-solving and programming<ref>http://www.flaticon.com/</ref>]]


Key generation is the process of generating keys in cryptography. A key is used to encrypt and decrypt whatever data is being encrypted/decrypted.<ref>https://en.wikipedia.org/wiki/Key_generation</ref>
Prior to reading this article, you should understand [[Hashing|hashing]].  


A cryptographic hash function (CHF) is a hash function that is suitable for use in cryptography. It is a mathematical algorithm that maps data of arbitrary size (often called the "message") to a bit string of a fixed size (the "hash value", "hash", or "message digest") and is a one-way function, that is, a function which is practically infeasible to invert. Ideally, the only way to find a message that produces a given hash is to attempt a brute-force search of possible inputs to see if they produce a match, or use a rainbow table of matched hashes. Cryptographic hash functions are a basic tool of modern cryptography.<ref>https://en.wikipedia.org/wiki/Cryptographic_hash_function</ref>


[[File:Keys.png|600px]]
The ideal cryptographic hash function has the following main properties:
 
* it is deterministic, meaning that the same message always results in the same hash
* it is quick to compute the hash value for any given message
* it is infeasible to generate a message that yields a given hash value
* it is infeasible to find two different messages with the same hash value
* a small change to a message should change the hash value so extensively that the new hash value appears uncorrelated with the old hash value (avalanche effect)




== Video ==
== Video ==
This video is at the '''perfect level''' of detail. Please watch the whole video, but the part which is especially pointed at [[blockchain]] starts at about 4:05.


<html>
<html>
<iframe width="560" height="315" src="https://www.youtube.com/embed/GSIDS_lvRv4" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
<iframe width="560" height="315" src="https://www.youtube.com/embed/UswqcbncliE" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
</html>
</html>



Latest revision as of 17:57, 8 March 2020

Computational thinking, problem-solving and programming[1]

Prior to reading this article, you should understand hashing.

A cryptographic hash function (CHF) is a hash function that is suitable for use in cryptography. It is a mathematical algorithm that maps data of arbitrary size (often called the "message") to a bit string of a fixed size (the "hash value", "hash", or "message digest") and is a one-way function, that is, a function which is practically infeasible to invert. Ideally, the only way to find a message that produces a given hash is to attempt a brute-force search of possible inputs to see if they produce a match, or use a rainbow table of matched hashes. Cryptographic hash functions are a basic tool of modern cryptography.[2]

The ideal cryptographic hash function has the following main properties:

  • it is deterministic, meaning that the same message always results in the same hash
  • it is quick to compute the hash value for any given message
  • it is infeasible to generate a message that yields a given hash value
  • it is infeasible to find two different messages with the same hash value
  • a small change to a message should change the hash value so extensively that the new hash value appears uncorrelated with the old hash value (avalanche effect)


Video

References