SlideShare a Scribd company logo
Cryptographic Hash Functions
Use of Cryptography in Blockchain
• To protect user privacy.
• To protect transaction information.
• To protect ensure data consistency.
• To encode the rules for creation of new units of the currency into a
mathematical protocol.
• To utilize many advanced Cryptographic Techniques and Algorithm’s
into the blockchain network.
Hashing Algorithms
• A hash function is an algorithm that generates a fixed-length result or
hash value from a specific input data. It is different from encryption
which converts plain text to encrypted text and with the help of
decryption, converts the encrypted text back to the original plain
text.
• Types - RipeMD, Tiger, xxhash, MD5, SHA-2,CRC32 etc.
• Hashing algorithm – properties
• - plain text of any size - is converted into a fixed size hashed text through a
cryptographic hash function
• Efficiently computable
• - difficult for hackers to make sense of it. (A hash length of 160 to 512 bits is
good).
• - it doesn’t provide a way to go back to the original text.
Security properties
• Property1: Collision Resistance
• Property2: Pre-image resistance (hiding)
• Property3: Second Pre-image resistance
• Property4: Avalanche effect
• Property5: Deterministic
• Property6: Computational Efficient
1. Collision‐resistance.
• The first property that we need from a cryptographic hash function is
that it’s collision‐resistant. A collision occurs when two distinct inputs
produce the same output.
• A hash function H(.) is collision‐resistant if nobody can find a collision
• The number of inputs exceeds the number of outputs, we are
guaranteed that there must be at least one output to which the hash
function maps more than one input.
Collision-Resistance
• Means it should be hard to find two different inputs of any length
that result in the same hash. This property is also referred to as
collision free hash function.
• Since, hash function is compressing function with fixed hash length, it
is impossible for a hash function not to have collisions. This property
of collision free only confirms that these collisions should be hard to
find.
• This property makes it very difficult for an attacker to find two input
values with the same hash.
Example
Birthday Paradox – Finding collisions
• if you gather up 20-30 people in one room, the odds of two people sharing the
exact same birthday rises up astronomically. In fact, there is a 50-50 chance for 2
people of sharing the same birthday in this scenario!
• assuming that all days of the year have the same likelihood of having a
birthday, the chances of another person sharing your birthday is 1/365 which is
a 0.27%.
• Collision‐detection algorithm works for every hash function – takes a
long time.
• Hash function with a 256‐bit output, you would have to compute the
hash function 2 ^256 + 1 times in the worst case, and about 2^128
times on average.
• There are no hash functions proven to be collision‐resistant.
2. Pre-image resistance (Hiding)
• we’re given the output of the hash function y = H(x) , there’s no
feasible way to figure out what the input, x , was.
• Hiding. A hash function H is hiding if: when a secret value r is chosen
from a probability distribution that has high min‐entropy , then given
H(r ‖ x) it is infeasible to find x .
• min‐entropy is a measure of how predictable an outcome is, and high
min‐entropy captures the intuitive idea that the distribution (i.e.,
random variable) is very spread out.
Example
3. Second Pre-image resistance
Example
4. Avalanche Effect
Example 1:
Example 2:
5. Deterministic
Example:
6. Computational Efficient
Secure Hash Algorithm
• SHA originally designed by NIST in 1993
• Revised in 1995 as SHA-1
• versions of SHA
• SHA-224, SHA-256, SHA-384, SHA-512
SHA-256 hash function
Merkle – Damgard Scheme

More Related Content

Similar to 2 Cryptographic_Hash_Functions.pptx

unit 4.pptx of hash function in cryptography
unit 4.pptx of hash function in cryptographyunit 4.pptx of hash function in cryptography
unit 4.pptx of hash function in cryptography
NithyasriA2
 
Cryptography and Network Security Principles and Practice.docx
Cryptography and Network Security Principles and Practice.docxCryptography and Network Security Principles and Practice.docx
Cryptography and Network Security Principles and Practice.docx
richardnorman90310
 
CISSP Week 20
CISSP Week 20CISSP Week 20
CISSP Week 20
jemtallon
 
Cryptography
CryptographyCryptography
Cryptography
Rohan04
 
Concept of hashing
Concept of hashingConcept of hashing
Concept of hashing
Rafi Dar
 

Similar to 2 Cryptographic_Hash_Functions.pptx (20)

HASH FUNCTIONS.pdf
HASH FUNCTIONS.pdfHASH FUNCTIONS.pdf
HASH FUNCTIONS.pdf
 
CS6701 CRYPTOGRAPHY AND NETWORK SECURITY
CS6701 CRYPTOGRAPHY AND NETWORK SECURITYCS6701 CRYPTOGRAPHY AND NETWORK SECURITY
CS6701 CRYPTOGRAPHY AND NETWORK SECURITY
 
Cryptography Key Management.pptx
Cryptography Key Management.pptxCryptography Key Management.pptx
Cryptography Key Management.pptx
 
Ch_07 (1).pptx
Ch_07 (1).pptxCh_07 (1).pptx
Ch_07 (1).pptx
 
Birthday Paradox explained
Birthday Paradox explainedBirthday Paradox explained
Birthday Paradox explained
 
Dnssec tutorial-crypto-defs
Dnssec tutorial-crypto-defsDnssec tutorial-crypto-defs
Dnssec tutorial-crypto-defs
 
unit 4.pptx of hash function in cryptography
unit 4.pptx of hash function in cryptographyunit 4.pptx of hash function in cryptography
unit 4.pptx of hash function in cryptography
 
Public Key Encryption & Hash functions
Public Key Encryption & Hash functionsPublic Key Encryption & Hash functions
Public Key Encryption & Hash functions
 
Cryptography and Network Security Principles and Practice.docx
Cryptography and Network Security Principles and Practice.docxCryptography and Network Security Principles and Practice.docx
Cryptography and Network Security Principles and Practice.docx
 
CISSP Week 20
CISSP Week 20CISSP Week 20
CISSP Week 20
 
Information and data security cryptographic hash functions
Information and data security cryptographic hash functionsInformation and data security cryptographic hash functions
Information and data security cryptographic hash functions
 
Cryptography
CryptographyCryptography
Cryptography
 
Similarity Search in High Dimensions via Hashing
Similarity Search in High Dimensions via HashingSimilarity Search in High Dimensions via Hashing
Similarity Search in High Dimensions via Hashing
 
Hash Function & Analysis
Hash Function & AnalysisHash Function & Analysis
Hash Function & Analysis
 
BlockChain Overview
BlockChain OverviewBlockChain Overview
BlockChain Overview
 
Concept of hashing
Concept of hashingConcept of hashing
Concept of hashing
 
A Modified approach for implementation of an efficient padding scheme in a di...
A Modified approach for implementation of an efficient padding scheme in a di...A Modified approach for implementation of an efficient padding scheme in a di...
A Modified approach for implementation of an efficient padding scheme in a di...
 
Unit 4
Unit 4Unit 4
Unit 4
 
Introduction to blockchain and cryptocurrency technologies
Introduction to blockchain and cryptocurrency technologiesIntroduction to blockchain and cryptocurrency technologies
Introduction to blockchain and cryptocurrency technologies
 
Cs166 mynote
Cs166 mynoteCs166 mynote
Cs166 mynote
 

Recently uploaded

Recently uploaded (20)

slides CapTechTalks Webinar May 2024 Alexander Perry.pptx
slides CapTechTalks Webinar May 2024 Alexander Perry.pptxslides CapTechTalks Webinar May 2024 Alexander Perry.pptx
slides CapTechTalks Webinar May 2024 Alexander Perry.pptx
 
Synthetic Fiber Construction in lab .pptx
Synthetic Fiber Construction in lab .pptxSynthetic Fiber Construction in lab .pptx
Synthetic Fiber Construction in lab .pptx
 
Danh sách HSG Bộ môn cấp trường - Cấp THPT.pdf
Danh sách HSG Bộ môn cấp trường - Cấp THPT.pdfDanh sách HSG Bộ môn cấp trường - Cấp THPT.pdf
Danh sách HSG Bộ môn cấp trường - Cấp THPT.pdf
 
Instructions for Submissions thorugh G- Classroom.pptx
Instructions for Submissions thorugh G- Classroom.pptxInstructions for Submissions thorugh G- Classroom.pptx
Instructions for Submissions thorugh G- Classroom.pptx
 
Sha'Carri Richardson Presentation 202345
Sha'Carri Richardson Presentation 202345Sha'Carri Richardson Presentation 202345
Sha'Carri Richardson Presentation 202345
 
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
GIÁO ÁN DẠY THÊM (KẾ HOẠCH BÀI BUỔI 2) - TIẾNG ANH 8 GLOBAL SUCCESS (2 CỘT) N...
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 
How to Create Map Views in the Odoo 17 ERP
How to Create Map Views in the Odoo 17 ERPHow to Create Map Views in the Odoo 17 ERP
How to Create Map Views in the Odoo 17 ERP
 
Operations Management - Book1.p - Dr. Abdulfatah A. Salem
Operations Management - Book1.p  - Dr. Abdulfatah A. SalemOperations Management - Book1.p  - Dr. Abdulfatah A. Salem
Operations Management - Book1.p - Dr. Abdulfatah A. Salem
 
Ethnobotany and Ethnopharmacology ......
Ethnobotany and Ethnopharmacology ......Ethnobotany and Ethnopharmacology ......
Ethnobotany and Ethnopharmacology ......
 
Matatag-Curriculum and the 21st Century Skills Presentation.pptx
Matatag-Curriculum and the 21st Century Skills Presentation.pptxMatatag-Curriculum and the 21st Century Skills Presentation.pptx
Matatag-Curriculum and the 21st Century Skills Presentation.pptx
 
How to Break the cycle of negative Thoughts
How to Break the cycle of negative ThoughtsHow to Break the cycle of negative Thoughts
How to Break the cycle of negative Thoughts
 
Basic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
Basic Civil Engg Notes_Chapter-6_Environment Pollution & EngineeringBasic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
Basic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
 
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptxStudents, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
 
NCERT Solutions Power Sharing Class 10 Notes pdf
NCERT Solutions Power Sharing Class 10 Notes pdfNCERT Solutions Power Sharing Class 10 Notes pdf
NCERT Solutions Power Sharing Class 10 Notes pdf
 
Salient features of Environment protection Act 1986.pptx
Salient features of Environment protection Act 1986.pptxSalient features of Environment protection Act 1986.pptx
Salient features of Environment protection Act 1986.pptx
 
[GDSC YCCE] Build with AI Online Presentation
[GDSC YCCE] Build with AI Online Presentation[GDSC YCCE] Build with AI Online Presentation
[GDSC YCCE] Build with AI Online Presentation
 
Introduction to Quality Improvement Essentials
Introduction to Quality Improvement EssentialsIntroduction to Quality Improvement Essentials
Introduction to Quality Improvement Essentials
 
UNIT – IV_PCI Complaints: Complaints and evaluation of complaints, Handling o...
UNIT – IV_PCI Complaints: Complaints and evaluation of complaints, Handling o...UNIT – IV_PCI Complaints: Complaints and evaluation of complaints, Handling o...
UNIT – IV_PCI Complaints: Complaints and evaluation of complaints, Handling o...
 
Solid waste management & Types of Basic civil Engineering notes by DJ Sir.pptx
Solid waste management & Types of Basic civil Engineering notes by DJ Sir.pptxSolid waste management & Types of Basic civil Engineering notes by DJ Sir.pptx
Solid waste management & Types of Basic civil Engineering notes by DJ Sir.pptx
 

2 Cryptographic_Hash_Functions.pptx

  • 2. Use of Cryptography in Blockchain • To protect user privacy. • To protect transaction information. • To protect ensure data consistency. • To encode the rules for creation of new units of the currency into a mathematical protocol. • To utilize many advanced Cryptographic Techniques and Algorithm’s into the blockchain network.
  • 3. Hashing Algorithms • A hash function is an algorithm that generates a fixed-length result or hash value from a specific input data. It is different from encryption which converts plain text to encrypted text and with the help of decryption, converts the encrypted text back to the original plain text. • Types - RipeMD, Tiger, xxhash, MD5, SHA-2,CRC32 etc.
  • 4.
  • 5. • Hashing algorithm – properties • - plain text of any size - is converted into a fixed size hashed text through a cryptographic hash function • Efficiently computable • - difficult for hackers to make sense of it. (A hash length of 160 to 512 bits is good). • - it doesn’t provide a way to go back to the original text.
  • 6. Security properties • Property1: Collision Resistance • Property2: Pre-image resistance (hiding) • Property3: Second Pre-image resistance • Property4: Avalanche effect • Property5: Deterministic • Property6: Computational Efficient
  • 7. 1. Collision‐resistance. • The first property that we need from a cryptographic hash function is that it’s collision‐resistant. A collision occurs when two distinct inputs produce the same output. • A hash function H(.) is collision‐resistant if nobody can find a collision
  • 8. • The number of inputs exceeds the number of outputs, we are guaranteed that there must be at least one output to which the hash function maps more than one input.
  • 9.
  • 10. Collision-Resistance • Means it should be hard to find two different inputs of any length that result in the same hash. This property is also referred to as collision free hash function. • Since, hash function is compressing function with fixed hash length, it is impossible for a hash function not to have collisions. This property of collision free only confirms that these collisions should be hard to find. • This property makes it very difficult for an attacker to find two input values with the same hash.
  • 11.
  • 13.
  • 14. Birthday Paradox – Finding collisions • if you gather up 20-30 people in one room, the odds of two people sharing the exact same birthday rises up astronomically. In fact, there is a 50-50 chance for 2 people of sharing the same birthday in this scenario! • assuming that all days of the year have the same likelihood of having a birthday, the chances of another person sharing your birthday is 1/365 which is a 0.27%.
  • 15. • Collision‐detection algorithm works for every hash function – takes a long time. • Hash function with a 256‐bit output, you would have to compute the hash function 2 ^256 + 1 times in the worst case, and about 2^128 times on average. • There are no hash functions proven to be collision‐resistant.
  • 16. 2. Pre-image resistance (Hiding) • we’re given the output of the hash function y = H(x) , there’s no feasible way to figure out what the input, x , was. • Hiding. A hash function H is hiding if: when a secret value r is chosen from a probability distribution that has high min‐entropy , then given H(r ‖ x) it is infeasible to find x . • min‐entropy is a measure of how predictable an outcome is, and high min‐entropy captures the intuitive idea that the distribution (i.e., random variable) is very spread out.
  • 17.
  • 19.
  • 20. 3. Second Pre-image resistance
  • 22.
  • 29. Secure Hash Algorithm • SHA originally designed by NIST in 1993 • Revised in 1995 as SHA-1 • versions of SHA • SHA-224, SHA-256, SHA-384, SHA-512