SlideShare a Scribd company logo
NETWORK SECURITY
Name of the Staff : M.FLORENCE DAYANA M.C.A.,M.Phil.,(Ph.D).,
Head, Dept. of CA
Bon Secours College For Women
Thanjavur.
Class : II MSc., CS
Semester : III
Unit : III
Topic : Public key Encryption and Hash Functions
2/15/20191
public-key Encryption
Public-key encryption is a cryptographic system that uses
two keys -- a public key known to everyone and
a private or secret key known only to the recipient of the
message.
Example: When John wants to send a secure message to Jane,
he uses Jane's public key to encrypt the message. Jane then
uses her private key to decrypt it.
An important element to the public key system is that the public
and private keys are related in such a way that only the public
key can be used to encrypt messages and only the
corresponding private key can be used to decrypt them.
Moreover, it is virtually impossible to deduce the private key if you
know the public key.
Public key encryption is a form of encryption that uses two
keys.
A public key, which everyone knows, and a private key, which
only you know.
To encrypt, the public key is applied to the target information,
using a predefined operation (several times), to produce a
pseudo-random number.
To decrypt, the private key is applied to the pseudo-random
number, using a different predefined operation (several times),
to get the target information back.
The algorithm relies on the fact that encryption is easy, and
decryption is hard, making decryption impractical without the
key.
It was the first system to allow secure information transfer,
without a shared Key.
Hash Functions
• A hash function H accepts a variable-length block
of data M as input and produces a fixed-size hash
value
• h = H(M)
• Principal object is data integrity
• Cryptographic hash function
• An algorithm for which it is computationally
infeasible to find either:
(a) a data object that maps to a pre-specified hash
result (the one-way property)
(b) two data objects that map to the same hash result
(the collision-free property)
Public Key Encryption & Hash functions
Public Key Encryption & Hash functions
Public Key Encryption & Hash functions
Message Authentication Code
(MAC)
• Also known as a keyed hash function
• Typically used between two parties that share a
secret key to authenticate information exchanged
between those parties
Takes as input a secret key and a data block and produces a
hash value (MAC) which is associated with the protected
message
•If the integrity of the message needs to be checked, the MAC
function can be applied to the message and the result
compared with the associated MAC value
•An attacker who alters the message will be unable to alter the
associated MAC value without knowledge of the secret key
Digital Signature
• Operation is similar to that of the MAC
• The hash value of a message is encrypted with a
user’s private key
• Anyone who knows the user’s public key can
verify the integrity of the message
• An attacker who wishes to alter the message
would need to know the user’s private key
• Implications of digital signatures go beyond just
message authentication
Public Key Encryption & Hash functions
Other Hash Function Uses
Commonly used to create
a one-way password file
When a user enters a
password, the hash of
that password is
compared to the stored
hash value for
verification
This approach to
password protection is
used by most operating
systems
Can be used for intrusion
and virus detection
Store H(F) for each file
on a system and secure
the hash values
One can later determine
if a file has been
modified by
recomputing H(F)
An intruder would need
to change F without
changing H(F)
Can be used to construct
a pseudorandom function
(PRF) or a pseudorandom
number generator (PRNG)
A common application
for a hash-based PRF is
for the generation of
symmetric keys
Two Simple Hash Functions
• Consider two simple insecure hash functions that operate
using the following general principles:
• The input is viewed as a sequence of n-bit blocks
• The input is processed one block at a time in an iterative fashion
to produce an n-bit hash function
• Bit-by-bit exclusive-OR (XOR) of every block
• Ci = bi1 xor bi2 xor . . . xor bim
• Produces a simple parity for each bit position and is known as a
longitudinal redundancy check
• Reasonably effective for random data as a data integrity check
• Perform a one-bit circular shift on the hash value after each
block is processed
• Has the effect of randomizing the input more completely and
overcoming any regularities that appear in the input
Two
Simple
Hash
Functions
Requirements and
Security
• x is the preimage of h for
a hash value h = H(x)
• Is a data block whose
hash function, using the
function H, is h
• Because H is a many-to-
one mapping, for any
given hash value h, there
will in general be multiple
preimages
• Occurs if we have x ≠ y
and H(x) = H(y)
• Because we are using
hash functions for data
integrity, collisions are
clearly undesirable
Table 11.1
Requirements for a Cryptographic Hash Function H
(Table can be found on page 323 in textbook.)
Public Key Encryption & Hash functions
* Resistance required if attacker is able to mount a chosen message attack
Table 11.2
Hash Function Resistance Properties Required for Various
Data Integrity Applications
Attacks on Hash
Functions
• Does not depend on the
specific algorithm, only
depends on bit length
• In the case of a hash
function, attack depends
only on the bit length of the
hash value
• Method is to pick values at
random and try each one
until a collision occurs
• An attack based on
weaknesses in a
particular cryptographic
algorithm
• Seek to exploit some
property of the algorithm
to perform some attack
other than an exhaustive
search
Birthday Attacks
• For a collision resistant attack, an adversary wishes to find two messages or
data blocks that yield the same hash function
• The effort required is explained by a mathematical result referred to as the
birthday paradox
• How the birthday attack works:
• The source (A) is prepared to sign a legitimate message x by appending the
appropriate m-bit hash code and encrypting that hash code with A’s private key
• Opponent generates 2m/2 variations x’ of x, all with essentially the same meaning,
and stores the messages and their hash values
• Opponent generates a fraudulent message y for which A’s signature is desired
• Two sets of messages are compared to find a pair with the same hash
• The opponent offers the valid variation to A for signature which can then be
attached to the fraudulent variation for transmission to the intended recipient
• Because the two variations have the same hash code, they will produce the same
signature and the opponent is assured of success even though the encryption key
is not known
Public Key Encryption & Hash functions
Hash Functions Based on
Cipher Block Chaining
• Can use block ciphers as hash functions
• Using H0=0 and zero-pad of final block
• Compute: Hi = E(Mi Hi-1)
• Use final block as the hash value
• Similar to CBC but without a key
• Resulting hash is too small (64-bit)
• Both due to direct birthday attack
• And “meet-in-the-middle” attack
• Other variants also susceptible to attack
Secure Hash Algorithm (SHA)
• SHA was originally designed by the National Institute
of Standards and Technology (NIST) and published as
a federal information processing standard (FIPS 180) in
1993
• Was revised in 1995 as SHA-1
• Based on the hash function MD4 and its design closely
models MD4
• Produces 160-bit hash values
• In 2002 NIST produced a revised version of the
standard that defined three new versions of SHA with
hash value lengths of 256, 384, and 512
• Collectively known as SHA-2
Note: All sizes are measured in bits.
Table 11.3
Comparison of SHA Parameters
Public Key Encryption & Hash functions
Public Key Encryption & Hash functions
Table 11.4
SHA-512 Constants
(Table can
be found
on page
333 in
textbook)
Public Key Encryption & Hash functions
Public Key Encryption & Hash functions
(Figure can be found on
page 337 in textbook)
SHA-512
Logic
SHA-3
SHA-1 has not yet been "broken”
• No one has demonstrated a technique
for producing collisions in a practical
amount of time
• Considered to be insecure and has been
phased out for SHA-2
SHA-2 shares the same structure and
mathematical operations as its
predecessors so this is a cause for
concern
• Because it will take years to find a
suitable replacement for SHA-2
should it become vulnerable, NIST
decided to begin the process of
developing a new hash standard
NIST announced in 2007 a competition
for the SHA-3 next generation NIST
hash function
• Winning design was announced by
NIST in October 2012
• SHA-3 is a cryptographic hash
function that is intended to
complement SHA-2 as the approved
standard for a wide range of
applications
The Sponge Construction
• Underlying structure of SHA-3 is a scheme referred to by its
designers as a sponge construction
• Takes an input message and partitions it into fixed-size
blocks
• Each block is processed in turn with the output of each
iteration fed into the next iteration, finally producing an
output block
• The sponge function is defined by three parameters:
• f = the internal function used to process each input block
• r = the size in bits of the input blocks, called the bitrate
• pad = the padding algorithm
Public Key Encryption & Hash functions
Public Key Encryption & Hash functions
Table 11.5
SHA-3 Parameters
Public Key Encryption & Hash functions
SHA-3
Iteration
Function f
Table
11.6
Step
Functions
in SHA-3
Public Key Encryption & Hash functions
Public Key Encryption & Hash functions
Summary
• Applications of
cryptographic hash
functions
• Message authentication
• Digital signatures
• Other applications
• Requirements and
security
• Security requirements
for cryptographic hash
functions
• Brute-force attacks
• Cryptanalysis
• Hash functions based
on cipher block
chaining
• Secure hash
algorithm (SHA)
• SHA-512 logic
• SHA-512 round
function
• SHA-3
• The sponge
construction
• The SHA-3 Iteration
Function f
Ad

More Related Content

What's hot (20)

Message Authentication Code & HMAC
Message Authentication Code & HMACMessage Authentication Code & HMAC
Message Authentication Code & HMAC
Krishna Gehlot
 
Types of attacks
Types of attacksTypes of attacks
Types of attacks
Vivek Gandhi
 
Cryptographic Hashing Functions
Cryptographic Hashing FunctionsCryptographic Hashing Functions
Cryptographic Hashing Functions
Yusuf Uzun
 
Design of Secure Hash Algorithm(SHA)
Design of Secure Hash Algorithm(SHA)Design of Secure Hash Algorithm(SHA)
Design of Secure Hash Algorithm(SHA)
Saravanan T.M
 
Firewalls
FirewallsFirewalls
Firewalls
Ram Dutt Shukla
 
Symmetric & Asymmetric Cryptography
Symmetric & Asymmetric CryptographySymmetric & Asymmetric Cryptography
Symmetric & Asymmetric Cryptography
chauhankapil
 
block ciphers
block ciphersblock ciphers
block ciphers
Asad Ali
 
AES-Advanced Encryption Standard
AES-Advanced Encryption StandardAES-Advanced Encryption Standard
AES-Advanced Encryption Standard
Prince Rachit
 
Web Security
Web SecurityWeb Security
Web Security
Dr.Florence Dayana
 
Secure Socket Layer (SSL)
Secure Socket Layer (SSL)Secure Socket Layer (SSL)
Secure Socket Layer (SSL)
Samip jain
 
Firewall in Network Security
Firewall in Network SecurityFirewall in Network Security
Firewall in Network Security
lalithambiga kamaraj
 
Cryptography and network security
Cryptography and network securityCryptography and network security
Cryptography and network security
patisa
 
Information Security (Digital Signatures)
Information Security (Digital Signatures)Information Security (Digital Signatures)
Information Security (Digital Signatures)
Zara Nawaz
 
2. public key cryptography and RSA
2. public key cryptography and RSA2. public key cryptography and RSA
2. public key cryptography and RSA
Dr.Florence Dayana
 
Firewall & its configurations
Firewall & its configurationsFirewall & its configurations
Firewall & its configurations
Student
 
Secure Hash Algorithm
Secure Hash AlgorithmSecure Hash Algorithm
Secure Hash Algorithm
Vishakha Agarwal
 
Authentication
AuthenticationAuthentication
Authentication
primeteacher32
 
Hash Techniques in Cryptography
Hash Techniques in CryptographyHash Techniques in Cryptography
Hash Techniques in Cryptography
Basudev Saha
 
Asymmetric Cryptography
Asymmetric CryptographyAsymmetric Cryptography
Asymmetric Cryptography
UTD Computer Security Group
 
Firewall and its types and function
Firewall and its types and functionFirewall and its types and function
Firewall and its types and function
Nisarg Amin
 
Message Authentication Code & HMAC
Message Authentication Code & HMACMessage Authentication Code & HMAC
Message Authentication Code & HMAC
Krishna Gehlot
 
Cryptographic Hashing Functions
Cryptographic Hashing FunctionsCryptographic Hashing Functions
Cryptographic Hashing Functions
Yusuf Uzun
 
Design of Secure Hash Algorithm(SHA)
Design of Secure Hash Algorithm(SHA)Design of Secure Hash Algorithm(SHA)
Design of Secure Hash Algorithm(SHA)
Saravanan T.M
 
Symmetric & Asymmetric Cryptography
Symmetric & Asymmetric CryptographySymmetric & Asymmetric Cryptography
Symmetric & Asymmetric Cryptography
chauhankapil
 
block ciphers
block ciphersblock ciphers
block ciphers
Asad Ali
 
AES-Advanced Encryption Standard
AES-Advanced Encryption StandardAES-Advanced Encryption Standard
AES-Advanced Encryption Standard
Prince Rachit
 
Secure Socket Layer (SSL)
Secure Socket Layer (SSL)Secure Socket Layer (SSL)
Secure Socket Layer (SSL)
Samip jain
 
Cryptography and network security
Cryptography and network securityCryptography and network security
Cryptography and network security
patisa
 
Information Security (Digital Signatures)
Information Security (Digital Signatures)Information Security (Digital Signatures)
Information Security (Digital Signatures)
Zara Nawaz
 
2. public key cryptography and RSA
2. public key cryptography and RSA2. public key cryptography and RSA
2. public key cryptography and RSA
Dr.Florence Dayana
 
Firewall & its configurations
Firewall & its configurationsFirewall & its configurations
Firewall & its configurations
Student
 
Hash Techniques in Cryptography
Hash Techniques in CryptographyHash Techniques in Cryptography
Hash Techniques in Cryptography
Basudev Saha
 
Firewall and its types and function
Firewall and its types and functionFirewall and its types and function
Firewall and its types and function
Nisarg Amin
 

Similar to Public Key Encryption & Hash functions (20)

secure hash function for authentication in CNS
secure hash function for authentication in CNSsecure hash function for authentication in CNS
secure hash function for authentication in CNS
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
 
cryptography and network security cns.pptx
cryptography and network security cns.pptxcryptography and network security cns.pptx
cryptography and network security cns.pptx
gkumar610
 
All details of cryptography and all the topics of cryptography was explained
All details of cryptography and all the topics of cryptography was explainedAll details of cryptography and all the topics of cryptography was explained
All details of cryptography and all the topics of cryptography was explained
khitishKumarSahoo1
 
Cs8792 cns - unit iv
Cs8792   cns - unit ivCs8792   cns - unit iv
Cs8792 cns - unit iv
ArthyR3
 
Cs8792 cns - unit iv
Cs8792   cns - unit ivCs8792   cns - unit iv
Cs8792 cns - unit iv
ArthyR3
 
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
Mazin Alwaaly
 
Cns
CnsCns
Cns
ArthyR3
 
BAIT1103 Chapter 2
BAIT1103 Chapter 2BAIT1103 Chapter 2
BAIT1103 Chapter 2
limsh
 
Message authentication and hash function
Message authentication and hash functionMessage authentication and hash function
Message authentication and hash function
omarShiekh1
 
UNIT3_class (1).ppt CRYPTOGRAPHY NOTES AND NETWORK
UNIT3_class (1).ppt CRYPTOGRAPHY NOTES AND NETWORKUNIT3_class (1).ppt CRYPTOGRAPHY NOTES AND NETWORK
UNIT3_class (1).ppt CRYPTOGRAPHY NOTES AND NETWORK
jeevasreemurali
 
Distribution of public keys and hmac
Distribution of public keys and hmacDistribution of public keys and hmac
Distribution of public keys and hmac
anuragjagetiya
 
Cryptography and netwrk securityunit 4
Cryptography and netwrk securityunit 4Cryptography and netwrk securityunit 4
Cryptography and netwrk securityunit 4
mallikarjun batchanaboina
 
IS413 Topic 5.pptx
IS413 Topic 5.pptxIS413 Topic 5.pptx
IS413 Topic 5.pptx
WarrenPhiri4
 
CISSP Week 20
CISSP Week 20CISSP Week 20
CISSP Week 20
jemtallon
 
HASH FUNCTIONS.pdf
HASH FUNCTIONS.pdfHASH FUNCTIONS.pdf
HASH FUNCTIONS.pdf
KalsoomTahir2
 
Hash Function & Analysis
Hash Function & AnalysisHash Function & Analysis
Hash Function & Analysis
Pawandeep Kaur
 
Cryptography 3 Cryptography 3 Cryptography 3
Cryptography 3 Cryptography 3 Cryptography 3Cryptography 3 Cryptography 3 Cryptography 3
Cryptography 3 Cryptography 3 Cryptography 3
AhmedSaeed115917
 
Message Digest message digest ppttsx.pptx
Message Digest message digest ppttsx.pptxMessage Digest message digest ppttsx.pptx
Message Digest message digest ppttsx.pptx
LaxmipujaBiradar
 
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
 
secure hash function for authentication in CNS
secure hash function for authentication in CNSsecure hash function for authentication in CNS
secure hash function for authentication in CNS
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
 
cryptography and network security cns.pptx
cryptography and network security cns.pptxcryptography and network security cns.pptx
cryptography and network security cns.pptx
gkumar610
 
All details of cryptography and all the topics of cryptography was explained
All details of cryptography and all the topics of cryptography was explainedAll details of cryptography and all the topics of cryptography was explained
All details of cryptography and all the topics of cryptography was explained
khitishKumarSahoo1
 
Cs8792 cns - unit iv
Cs8792   cns - unit ivCs8792   cns - unit iv
Cs8792 cns - unit iv
ArthyR3
 
Cs8792 cns - unit iv
Cs8792   cns - unit ivCs8792   cns - unit iv
Cs8792 cns - unit iv
ArthyR3
 
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
Mazin Alwaaly
 
BAIT1103 Chapter 2
BAIT1103 Chapter 2BAIT1103 Chapter 2
BAIT1103 Chapter 2
limsh
 
Message authentication and hash function
Message authentication and hash functionMessage authentication and hash function
Message authentication and hash function
omarShiekh1
 
UNIT3_class (1).ppt CRYPTOGRAPHY NOTES AND NETWORK
UNIT3_class (1).ppt CRYPTOGRAPHY NOTES AND NETWORKUNIT3_class (1).ppt CRYPTOGRAPHY NOTES AND NETWORK
UNIT3_class (1).ppt CRYPTOGRAPHY NOTES AND NETWORK
jeevasreemurali
 
Distribution of public keys and hmac
Distribution of public keys and hmacDistribution of public keys and hmac
Distribution of public keys and hmac
anuragjagetiya
 
IS413 Topic 5.pptx
IS413 Topic 5.pptxIS413 Topic 5.pptx
IS413 Topic 5.pptx
WarrenPhiri4
 
CISSP Week 20
CISSP Week 20CISSP Week 20
CISSP Week 20
jemtallon
 
Hash Function & Analysis
Hash Function & AnalysisHash Function & Analysis
Hash Function & Analysis
Pawandeep Kaur
 
Cryptography 3 Cryptography 3 Cryptography 3
Cryptography 3 Cryptography 3 Cryptography 3Cryptography 3 Cryptography 3 Cryptography 3
Cryptography 3 Cryptography 3 Cryptography 3
AhmedSaeed115917
 
Message Digest message digest ppttsx.pptx
Message Digest message digest ppttsx.pptxMessage Digest message digest ppttsx.pptx
Message Digest message digest ppttsx.pptx
LaxmipujaBiradar
 
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
 
Ad

More from Dr.Florence Dayana (20)

Dr.M.Florence Dayana-Cloud Computing Architecture.pdf
Dr.M.Florence Dayana-Cloud Computing Architecture.pdfDr.M.Florence Dayana-Cloud Computing Architecture.pdf
Dr.M.Florence Dayana-Cloud Computing Architecture.pdf
Dr.Florence Dayana
 
Dr.M.Florence Dayana-Cloud Computing-unit - 4.pdf
Dr.M.Florence Dayana-Cloud Computing-unit - 4.pdfDr.M.Florence Dayana-Cloud Computing-unit - 4.pdf
Dr.M.Florence Dayana-Cloud Computing-unit - 4.pdf
Dr.Florence Dayana
 
Dr.M.Florence Dayana-Cloud Computing-Unit - 1.pdf
Dr.M.Florence Dayana-Cloud Computing-Unit - 1.pdfDr.M.Florence Dayana-Cloud Computing-Unit - 1.pdf
Dr.M.Florence Dayana-Cloud Computing-Unit - 1.pdf
Dr.Florence Dayana
 
M. Florence Dayana - Hadoop Foundation for Analytics.pptx
M. Florence Dayana - Hadoop Foundation for Analytics.pptxM. Florence Dayana - Hadoop Foundation for Analytics.pptx
M. Florence Dayana - Hadoop Foundation for Analytics.pptx
Dr.Florence Dayana
 
M. FLORENCE DAYANA/unit - II logic gates and circuits.pdf
M. FLORENCE DAYANA/unit - II logic gates and circuits.pdfM. FLORENCE DAYANA/unit - II logic gates and circuits.pdf
M. FLORENCE DAYANA/unit - II logic gates and circuits.pdf
Dr.Florence Dayana
 
M.FLORENCE DAYANA/electronic mail security.pdf
M.FLORENCE DAYANA/electronic mail security.pdfM.FLORENCE DAYANA/electronic mail security.pdf
M.FLORENCE DAYANA/electronic mail security.pdf
Dr.Florence Dayana
 
M. FLORENCE DAYANA - INPUT & OUTPUT DEVICES.pdf
M. FLORENCE DAYANA - INPUT & OUTPUT DEVICES.pdfM. FLORENCE DAYANA - INPUT & OUTPUT DEVICES.pdf
M. FLORENCE DAYANA - INPUT & OUTPUT DEVICES.pdf
Dr.Florence Dayana
 
Professional English - Reading
Professional English - ReadingProfessional English - Reading
Professional English - Reading
Dr.Florence Dayana
 
Professional English - Speaking
Professional English - SpeakingProfessional English - Speaking
Professional English - Speaking
Dr.Florence Dayana
 
Professional English - Listening
Professional English - ListeningProfessional English - Listening
Professional English - Listening
Dr.Florence Dayana
 
INPUT AND OUTPUT DEVICES.pdf
INPUT  AND OUTPUT DEVICES.pdfINPUT  AND OUTPUT DEVICES.pdf
INPUT AND OUTPUT DEVICES.pdf
Dr.Florence Dayana
 
NETWORK SECURITY-SET.pptx
NETWORK SECURITY-SET.pptxNETWORK SECURITY-SET.pptx
NETWORK SECURITY-SET.pptx
Dr.Florence Dayana
 
Network Security- Secure Socket Layer
Network Security- Secure Socket LayerNetwork Security- Secure Socket Layer
Network Security- Secure Socket Layer
Dr.Florence Dayana
 
M.florence dayana dream weaver
M.florence dayana   dream weaverM.florence dayana   dream weaver
M.florence dayana dream weaver
Dr.Florence Dayana
 
M.florence dayana computer networks transport layer
M.florence dayana   computer networks transport layerM.florence dayana   computer networks transport layer
M.florence dayana computer networks transport layer
Dr.Florence Dayana
 
M.Florence Dayana Computer Networks Types
M.Florence Dayana  Computer Networks TypesM.Florence Dayana  Computer Networks Types
M.Florence Dayana Computer Networks Types
Dr.Florence Dayana
 
M.Florence Dayana Computer Networks Introduction
M.Florence Dayana   Computer Networks IntroductionM.Florence Dayana   Computer Networks Introduction
M.Florence Dayana Computer Networks Introduction
Dr.Florence Dayana
 
M. FLORENCE DAYANA/DATABASE MANAGEMENT SYSYTEM
M. FLORENCE DAYANA/DATABASE MANAGEMENT SYSYTEMM. FLORENCE DAYANA/DATABASE MANAGEMENT SYSYTEM
M. FLORENCE DAYANA/DATABASE MANAGEMENT SYSYTEM
Dr.Florence Dayana
 
M.Florence Dayana
M.Florence DayanaM.Florence Dayana
M.Florence Dayana
Dr.Florence Dayana
 
M.Florence Dayana / Basics of C Language
M.Florence Dayana / Basics of C LanguageM.Florence Dayana / Basics of C Language
M.Florence Dayana / Basics of C Language
Dr.Florence Dayana
 
Dr.M.Florence Dayana-Cloud Computing Architecture.pdf
Dr.M.Florence Dayana-Cloud Computing Architecture.pdfDr.M.Florence Dayana-Cloud Computing Architecture.pdf
Dr.M.Florence Dayana-Cloud Computing Architecture.pdf
Dr.Florence Dayana
 
Dr.M.Florence Dayana-Cloud Computing-unit - 4.pdf
Dr.M.Florence Dayana-Cloud Computing-unit - 4.pdfDr.M.Florence Dayana-Cloud Computing-unit - 4.pdf
Dr.M.Florence Dayana-Cloud Computing-unit - 4.pdf
Dr.Florence Dayana
 
Dr.M.Florence Dayana-Cloud Computing-Unit - 1.pdf
Dr.M.Florence Dayana-Cloud Computing-Unit - 1.pdfDr.M.Florence Dayana-Cloud Computing-Unit - 1.pdf
Dr.M.Florence Dayana-Cloud Computing-Unit - 1.pdf
Dr.Florence Dayana
 
M. Florence Dayana - Hadoop Foundation for Analytics.pptx
M. Florence Dayana - Hadoop Foundation for Analytics.pptxM. Florence Dayana - Hadoop Foundation for Analytics.pptx
M. Florence Dayana - Hadoop Foundation for Analytics.pptx
Dr.Florence Dayana
 
M. FLORENCE DAYANA/unit - II logic gates and circuits.pdf
M. FLORENCE DAYANA/unit - II logic gates and circuits.pdfM. FLORENCE DAYANA/unit - II logic gates and circuits.pdf
M. FLORENCE DAYANA/unit - II logic gates and circuits.pdf
Dr.Florence Dayana
 
M.FLORENCE DAYANA/electronic mail security.pdf
M.FLORENCE DAYANA/electronic mail security.pdfM.FLORENCE DAYANA/electronic mail security.pdf
M.FLORENCE DAYANA/electronic mail security.pdf
Dr.Florence Dayana
 
M. FLORENCE DAYANA - INPUT & OUTPUT DEVICES.pdf
M. FLORENCE DAYANA - INPUT & OUTPUT DEVICES.pdfM. FLORENCE DAYANA - INPUT & OUTPUT DEVICES.pdf
M. FLORENCE DAYANA - INPUT & OUTPUT DEVICES.pdf
Dr.Florence Dayana
 
Professional English - Reading
Professional English - ReadingProfessional English - Reading
Professional English - Reading
Dr.Florence Dayana
 
Professional English - Speaking
Professional English - SpeakingProfessional English - Speaking
Professional English - Speaking
Dr.Florence Dayana
 
Professional English - Listening
Professional English - ListeningProfessional English - Listening
Professional English - Listening
Dr.Florence Dayana
 
Network Security- Secure Socket Layer
Network Security- Secure Socket LayerNetwork Security- Secure Socket Layer
Network Security- Secure Socket Layer
Dr.Florence Dayana
 
M.florence dayana dream weaver
M.florence dayana   dream weaverM.florence dayana   dream weaver
M.florence dayana dream weaver
Dr.Florence Dayana
 
M.florence dayana computer networks transport layer
M.florence dayana   computer networks transport layerM.florence dayana   computer networks transport layer
M.florence dayana computer networks transport layer
Dr.Florence Dayana
 
M.Florence Dayana Computer Networks Types
M.Florence Dayana  Computer Networks TypesM.Florence Dayana  Computer Networks Types
M.Florence Dayana Computer Networks Types
Dr.Florence Dayana
 
M.Florence Dayana Computer Networks Introduction
M.Florence Dayana   Computer Networks IntroductionM.Florence Dayana   Computer Networks Introduction
M.Florence Dayana Computer Networks Introduction
Dr.Florence Dayana
 
M. FLORENCE DAYANA/DATABASE MANAGEMENT SYSYTEM
M. FLORENCE DAYANA/DATABASE MANAGEMENT SYSYTEMM. FLORENCE DAYANA/DATABASE MANAGEMENT SYSYTEM
M. FLORENCE DAYANA/DATABASE MANAGEMENT SYSYTEM
Dr.Florence Dayana
 
M.Florence Dayana / Basics of C Language
M.Florence Dayana / Basics of C LanguageM.Florence Dayana / Basics of C Language
M.Florence Dayana / Basics of C Language
Dr.Florence Dayana
 
Ad

Recently uploaded (20)

ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptxANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
Mayuri Chavan
 
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFAMEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
Dr. Nasir Mustafa
 
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales moduleHow To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
Celine George
 
Module 1: Foundations of Research
Module 1: Foundations of ResearchModule 1: Foundations of Research
Module 1: Foundations of Research
drroxannekemp
 
Cultivation Practice of Garlic in Nepal.pptx
Cultivation Practice of Garlic in Nepal.pptxCultivation Practice of Garlic in Nepal.pptx
Cultivation Practice of Garlic in Nepal.pptx
UmeshTimilsina1
 
Myasthenia gravis (Neuromuscular disorder)
Myasthenia gravis (Neuromuscular disorder)Myasthenia gravis (Neuromuscular disorder)
Myasthenia gravis (Neuromuscular disorder)
Mohamed Rizk Khodair
 
How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18
Celine George
 
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon DolabaniHistory Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
fruinkamel7m
 
TERMINOLOGIES,GRIEF PROCESS AND LOSS AMD ITS TYPES .pptx
TERMINOLOGIES,GRIEF PROCESS AND LOSS AMD ITS TYPES .pptxTERMINOLOGIES,GRIEF PROCESS AND LOSS AMD ITS TYPES .pptx
TERMINOLOGIES,GRIEF PROCESS AND LOSS AMD ITS TYPES .pptx
PoojaSen20
 
Cultivation Practice of Turmeric in Nepal.pptx
Cultivation Practice of Turmeric in Nepal.pptxCultivation Practice of Turmeric in Nepal.pptx
Cultivation Practice of Turmeric in Nepal.pptx
UmeshTimilsina1
 
CNS infections (encephalitis, meningitis & Brain abscess
CNS infections (encephalitis, meningitis & Brain abscessCNS infections (encephalitis, meningitis & Brain abscess
CNS infections (encephalitis, meningitis & Brain abscess
Mohamed Rizk Khodair
 
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptxU3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
Mayuri Chavan
 
Rock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian HistoryRock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian History
Virag Sontakke
 
Ajanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of HistoryAjanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of History
Virag Sontakke
 
Origin of Brahmi script: A breaking down of various theories
Origin of Brahmi script: A breaking down of various theoriesOrigin of Brahmi script: A breaking down of various theories
Origin of Brahmi script: A breaking down of various theories
PrachiSontakke5
 
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
Dr. Nasir Mustafa
 
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
parmarjuli1412
 
Botany Assignment Help Guide - Academic Excellence
Botany Assignment Help Guide - Academic ExcellenceBotany Assignment Help Guide - Academic Excellence
Botany Assignment Help Guide - Academic Excellence
online college homework help
 
Final Evaluation.docx...........................
Final Evaluation.docx...........................Final Evaluation.docx...........................
Final Evaluation.docx...........................
l1bbyburrell
 
The History of Kashmir Karkota Dynasty NEP.pptx
The History of Kashmir Karkota Dynasty NEP.pptxThe History of Kashmir Karkota Dynasty NEP.pptx
The History of Kashmir Karkota Dynasty NEP.pptx
Arya Mahila P. G. College, Banaras Hindu University, Varanasi, India.
 
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptxANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
Mayuri Chavan
 
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFAMEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
Dr. Nasir Mustafa
 
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales moduleHow To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
Celine George
 
Module 1: Foundations of Research
Module 1: Foundations of ResearchModule 1: Foundations of Research
Module 1: Foundations of Research
drroxannekemp
 
Cultivation Practice of Garlic in Nepal.pptx
Cultivation Practice of Garlic in Nepal.pptxCultivation Practice of Garlic in Nepal.pptx
Cultivation Practice of Garlic in Nepal.pptx
UmeshTimilsina1
 
Myasthenia gravis (Neuromuscular disorder)
Myasthenia gravis (Neuromuscular disorder)Myasthenia gravis (Neuromuscular disorder)
Myasthenia gravis (Neuromuscular disorder)
Mohamed Rizk Khodair
 
How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18
Celine George
 
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon DolabaniHistory Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
fruinkamel7m
 
TERMINOLOGIES,GRIEF PROCESS AND LOSS AMD ITS TYPES .pptx
TERMINOLOGIES,GRIEF PROCESS AND LOSS AMD ITS TYPES .pptxTERMINOLOGIES,GRIEF PROCESS AND LOSS AMD ITS TYPES .pptx
TERMINOLOGIES,GRIEF PROCESS AND LOSS AMD ITS TYPES .pptx
PoojaSen20
 
Cultivation Practice of Turmeric in Nepal.pptx
Cultivation Practice of Turmeric in Nepal.pptxCultivation Practice of Turmeric in Nepal.pptx
Cultivation Practice of Turmeric in Nepal.pptx
UmeshTimilsina1
 
CNS infections (encephalitis, meningitis & Brain abscess
CNS infections (encephalitis, meningitis & Brain abscessCNS infections (encephalitis, meningitis & Brain abscess
CNS infections (encephalitis, meningitis & Brain abscess
Mohamed Rizk Khodair
 
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptxU3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
Mayuri Chavan
 
Rock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian HistoryRock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian History
Virag Sontakke
 
Ajanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of HistoryAjanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of History
Virag Sontakke
 
Origin of Brahmi script: A breaking down of various theories
Origin of Brahmi script: A breaking down of various theoriesOrigin of Brahmi script: A breaking down of various theories
Origin of Brahmi script: A breaking down of various theories
PrachiSontakke5
 
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
Dr. Nasir Mustafa
 
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
parmarjuli1412
 
Botany Assignment Help Guide - Academic Excellence
Botany Assignment Help Guide - Academic ExcellenceBotany Assignment Help Guide - Academic Excellence
Botany Assignment Help Guide - Academic Excellence
online college homework help
 
Final Evaluation.docx...........................
Final Evaluation.docx...........................Final Evaluation.docx...........................
Final Evaluation.docx...........................
l1bbyburrell
 

Public Key Encryption & Hash functions

  • 1. NETWORK SECURITY Name of the Staff : M.FLORENCE DAYANA M.C.A.,M.Phil.,(Ph.D)., Head, Dept. of CA Bon Secours College For Women Thanjavur. Class : II MSc., CS Semester : III Unit : III Topic : Public key Encryption and Hash Functions 2/15/20191
  • 2. public-key Encryption Public-key encryption is a cryptographic system that uses two keys -- a public key known to everyone and a private or secret key known only to the recipient of the message. Example: When John wants to send a secure message to Jane, he uses Jane's public key to encrypt the message. Jane then uses her private key to decrypt it. An important element to the public key system is that the public and private keys are related in such a way that only the public key can be used to encrypt messages and only the corresponding private key can be used to decrypt them. Moreover, it is virtually impossible to deduce the private key if you know the public key.
  • 3. Public key encryption is a form of encryption that uses two keys. A public key, which everyone knows, and a private key, which only you know. To encrypt, the public key is applied to the target information, using a predefined operation (several times), to produce a pseudo-random number. To decrypt, the private key is applied to the pseudo-random number, using a different predefined operation (several times), to get the target information back. The algorithm relies on the fact that encryption is easy, and decryption is hard, making decryption impractical without the key. It was the first system to allow secure information transfer, without a shared Key.
  • 4. Hash Functions • A hash function H accepts a variable-length block of data M as input and produces a fixed-size hash value • h = H(M) • Principal object is data integrity • Cryptographic hash function • An algorithm for which it is computationally infeasible to find either: (a) a data object that maps to a pre-specified hash result (the one-way property) (b) two data objects that map to the same hash result (the collision-free property)
  • 8. Message Authentication Code (MAC) • Also known as a keyed hash function • Typically used between two parties that share a secret key to authenticate information exchanged between those parties Takes as input a secret key and a data block and produces a hash value (MAC) which is associated with the protected message •If the integrity of the message needs to be checked, the MAC function can be applied to the message and the result compared with the associated MAC value •An attacker who alters the message will be unable to alter the associated MAC value without knowledge of the secret key
  • 9. Digital Signature • Operation is similar to that of the MAC • The hash value of a message is encrypted with a user’s private key • Anyone who knows the user’s public key can verify the integrity of the message • An attacker who wishes to alter the message would need to know the user’s private key • Implications of digital signatures go beyond just message authentication
  • 11. Other Hash Function Uses Commonly used to create a one-way password file When a user enters a password, the hash of that password is compared to the stored hash value for verification This approach to password protection is used by most operating systems Can be used for intrusion and virus detection Store H(F) for each file on a system and secure the hash values One can later determine if a file has been modified by recomputing H(F) An intruder would need to change F without changing H(F) Can be used to construct a pseudorandom function (PRF) or a pseudorandom number generator (PRNG) A common application for a hash-based PRF is for the generation of symmetric keys
  • 12. Two Simple Hash Functions • Consider two simple insecure hash functions that operate using the following general principles: • The input is viewed as a sequence of n-bit blocks • The input is processed one block at a time in an iterative fashion to produce an n-bit hash function • Bit-by-bit exclusive-OR (XOR) of every block • Ci = bi1 xor bi2 xor . . . xor bim • Produces a simple parity for each bit position and is known as a longitudinal redundancy check • Reasonably effective for random data as a data integrity check • Perform a one-bit circular shift on the hash value after each block is processed • Has the effect of randomizing the input more completely and overcoming any regularities that appear in the input
  • 14. Requirements and Security • x is the preimage of h for a hash value h = H(x) • Is a data block whose hash function, using the function H, is h • Because H is a many-to- one mapping, for any given hash value h, there will in general be multiple preimages • Occurs if we have x ≠ y and H(x) = H(y) • Because we are using hash functions for data integrity, collisions are clearly undesirable
  • 15. Table 11.1 Requirements for a Cryptographic Hash Function H (Table can be found on page 323 in textbook.)
  • 17. * Resistance required if attacker is able to mount a chosen message attack Table 11.2 Hash Function Resistance Properties Required for Various Data Integrity Applications
  • 18. Attacks on Hash Functions • Does not depend on the specific algorithm, only depends on bit length • In the case of a hash function, attack depends only on the bit length of the hash value • Method is to pick values at random and try each one until a collision occurs • An attack based on weaknesses in a particular cryptographic algorithm • Seek to exploit some property of the algorithm to perform some attack other than an exhaustive search
  • 19. Birthday Attacks • For a collision resistant attack, an adversary wishes to find two messages or data blocks that yield the same hash function • The effort required is explained by a mathematical result referred to as the birthday paradox • How the birthday attack works: • The source (A) is prepared to sign a legitimate message x by appending the appropriate m-bit hash code and encrypting that hash code with A’s private key • Opponent generates 2m/2 variations x’ of x, all with essentially the same meaning, and stores the messages and their hash values • Opponent generates a fraudulent message y for which A’s signature is desired • Two sets of messages are compared to find a pair with the same hash • The opponent offers the valid variation to A for signature which can then be attached to the fraudulent variation for transmission to the intended recipient • Because the two variations have the same hash code, they will produce the same signature and the opponent is assured of success even though the encryption key is not known
  • 21. Hash Functions Based on Cipher Block Chaining • Can use block ciphers as hash functions • Using H0=0 and zero-pad of final block • Compute: Hi = E(Mi Hi-1) • Use final block as the hash value • Similar to CBC but without a key • Resulting hash is too small (64-bit) • Both due to direct birthday attack • And “meet-in-the-middle” attack • Other variants also susceptible to attack
  • 22. Secure Hash Algorithm (SHA) • SHA was originally designed by the National Institute of Standards and Technology (NIST) and published as a federal information processing standard (FIPS 180) in 1993 • Was revised in 1995 as SHA-1 • Based on the hash function MD4 and its design closely models MD4 • Produces 160-bit hash values • In 2002 NIST produced a revised version of the standard that defined three new versions of SHA with hash value lengths of 256, 384, and 512 • Collectively known as SHA-2
  • 23. Note: All sizes are measured in bits. Table 11.3 Comparison of SHA Parameters
  • 26. Table 11.4 SHA-512 Constants (Table can be found on page 333 in textbook)
  • 29. (Figure can be found on page 337 in textbook) SHA-512 Logic
  • 30. SHA-3 SHA-1 has not yet been "broken” • No one has demonstrated a technique for producing collisions in a practical amount of time • Considered to be insecure and has been phased out for SHA-2 SHA-2 shares the same structure and mathematical operations as its predecessors so this is a cause for concern • Because it will take years to find a suitable replacement for SHA-2 should it become vulnerable, NIST decided to begin the process of developing a new hash standard NIST announced in 2007 a competition for the SHA-3 next generation NIST hash function • Winning design was announced by NIST in October 2012 • SHA-3 is a cryptographic hash function that is intended to complement SHA-2 as the approved standard for a wide range of applications
  • 31. The Sponge Construction • Underlying structure of SHA-3 is a scheme referred to by its designers as a sponge construction • Takes an input message and partitions it into fixed-size blocks • Each block is processed in turn with the output of each iteration fed into the next iteration, finally producing an output block • The sponge function is defined by three parameters: • f = the internal function used to process each input block • r = the size in bits of the input blocks, called the bitrate • pad = the padding algorithm
  • 40. Summary • Applications of cryptographic hash functions • Message authentication • Digital signatures • Other applications • Requirements and security • Security requirements for cryptographic hash functions • Brute-force attacks • Cryptanalysis • Hash functions based on cipher block chaining • Secure hash algorithm (SHA) • SHA-512 logic • SHA-512 round function • SHA-3 • The sponge construction • The SHA-3 Iteration Function f
  翻译: