SlideShare a Scribd company logo
Message authentication: MAC,
hashes
Message authentication
• Goal here: having received a message one would like to make sure that the
message has not been altered on the way
– �Produce a short sequence of bits that depends on the message and on a
secret key
– �To authenticate the message, the partner will compute the same bit pattern,
assuming he shares the same secret key
• �This does not necessarily includes encrypting or signing the message
– �The message can be sent in plain, with the authenticator appended
– �This is not a digital signature: the receiver can produce the same MAC
– �One may encrypt the authenticator with his private key to produce a digital
signature
– �One may encrypt both the message and the authenticator
• �Possible attacks on message authentication:
– �Content modification
– �Sequence modification–modifications to a sequence of messages, including
insertion, deletion, reordering
– �Timing modification–delay or replay message
Authentication functions
• Three types of authentication exist
• �Message encryption–the ciphertext serves as
authenticator
• �Message authentication code (MAC)–a public function
of the message and a secret key producing a fixed-
length value to serve as authenticator
• �This does not provide a digital signature because A
and B share the same key
• �Hash function–a public function mapping an arbitrary
length message into a fixed-length hash value to serve
as authenticator
– �This does not provide a digital signature because there is no
key
I. Message encryption as
authentication
• Main idea here: the message must have come
from A because the ciphertext can be decrypted
using his (secret or public) key
• �Also, none of the bits in the message have
been altered because an opponent does not
know how to manipulate the bits of the ciphertext
to induce meaningful changes to the plaintext
• �Conclusion: encryption (either symmetric or
public-key) provides authentication as well as
confidentiality
More to authentication than simple
encryption?
• �Often one needs alternative authentication schemes than just
encrypting the message
– �Sometimes one needs to avoid encryption of full messages due to
legal requirements
– �Encryption and authentication may be separated in the system
architecture
– �If a message is broadcast to several destinations in a network (such
as a military control center), then it is cheaper and more reliable to have
just one node responsible to evaluate the authenticity –message will be
sent in plain with an attached authenticator
– �If one side has a heavy load, it cannot afford to decrypt all messages –
it will just check the authenticity of some randomly selected messages
– �If the message is sent encrypted, it is of course protected over the
network. However, once the receiver decrypts the message, it is no
longer secure. Using a different type of authentication protects the
message also on the local computer
Message authentication code
(MAC)
• To generate the MAC of a message M, Alice gives M and the secret key K to a MAC
function C: MAC=CK(M)
– �Alice will send M plus the MAC to Bob
– �Bob has the same secret key K and generates the MAC himself to check the match
• �Typical attacks on MACs
– �Produce an illegitimate message with the same signature as a given (or chosen) legitimate
one
– �Produce a valid MAC for an illegitimate message
• �Requirements for MACs
– �The MAC function is in general many-to-one –messages are arbitrarily long and the MAC
has fixed length, thus there will be more than one message with the same MAC
– �Computationally easy to compute the MAC
– �Knowing M and CK(M) it is computationally infeasible to construct another message M’
with CK(M’)= CK(M)
– �CK(M) is uniformly distributed –if the attacker chooses a random bit pattern of length n, the
chances of it being the correct signature is 2-n
– �If M’ is obtained from M by certain transformations (even switching one bit), then the
probability that the two have the same MAC is 2-n
Basic uses of MAC
cryptographic hash
• A "hash" (also called a "digest", and informally a "checksum") is a
kind of "signature" for a stream of data that represents the contents
• We'll note here that though hashes and digests are often informally
called "checksums", they really aren't. True checksums, such as a
Cyclic Redundancy Check are designed to catch data-transmission
errors and not deliberate attempts at tampering with data
• Many Unix and Linux systems provide the md5sum program, which
reads a stream of data and produces a fixed, 128-bit number that
summarizes that stream using the popular "MD5" method.
• This shows that all input streams yield hashes of the same length,
and to experiment, try changing just one character of a small test
file. You'll find that even very small changes to the input yields
sweeping changes in the value of the hash, and this is known as the
avalanche effect.
Hashes are "digests", not
"encryption"
• Encryption transforms data from a
cleartext to ciphertext and back (given
the right keys), and the two texts
should roughly correspond to each
other in size: big cleartext yields big
ciphertext, and so on. "Encryption" is a
two-way operation.
Hashes one way
• Hashes, on the other hand,
compile a stream of data into a
small digest (a summarized form:
think "Reader's Digest"), and it's
strictly a one way operation. All
hashes of the same type - this
example shows the "MD5" variety
- have the same size no matter
how big the inputs are:
Authentication based on hash
functions• A fixed-length hash value h is generated by a function H that takes as input
a message of arbitrary length: h=H(M)
– �A sends M and H(M)
– �B authenticates the message by computing H(M) and checking the match
• �Requirements for a hash function
– �H can be applied to a message of any size
– �H produces fixed-length output
– �Computationally easy to compute H(M)
– �Computationally infeasible to find M such that H(M)=h, for a given h
– �Computationally infeasible to find M’ such that H(M’)=H(M), for a given M
– �Computationally infeasible to find M,M’ with H(M)=H(M’) (to resist to birthday
attacks)
• �Note: the hash function is not considered secret –some other means
are required to protect it
• �Note 2: Hash function plus secrecy (key) gives a MAC –these are called
HMACs
Ad

More Related Content

What's hot (20)

Ch11
Ch11Ch11
Ch11
Joe Christensen
 
Cryptography and Message Authentication NS3
Cryptography and Message Authentication NS3Cryptography and Message Authentication NS3
Cryptography and Message Authentication NS3
koolkampus
 
Message digest 5
Message digest 5Message digest 5
Message digest 5
Tirthika Bandi
 
MAC-Message Authentication Codes
MAC-Message Authentication CodesMAC-Message Authentication Codes
MAC-Message Authentication Codes
DarshanPatil82
 
Message AUthentication Code
Message AUthentication CodeMessage AUthentication Code
Message AUthentication Code
Keval Bhogayata
 
Message authentication and hash function
Message authentication and hash functionMessage authentication and hash function
Message authentication and hash function
omarShiekh1
 
Hash& mac algorithms
Hash& mac algorithmsHash& mac algorithms
Hash& mac algorithms
Harry Potter
 
Message Authentication
Message AuthenticationMessage Authentication
Message Authentication
chauhankapil
 
Message integrity protocol
Message integrity protocolMessage integrity protocol
Message integrity protocol
PriyaKarnan3
 
Cryptographic hash function md5
Cryptographic hash function md5Cryptographic hash function md5
Cryptographic hash function md5
Khulna University, Khulna, Bangladesh
 
HMAC authentication
HMAC authenticationHMAC authentication
HMAC authentication
Siu Tin
 
Distribution of public keys and hmac
Distribution of public keys and hmacDistribution of public keys and hmac
Distribution of public keys and hmac
anuragjagetiya
 
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
 
Public Key Encryption & Hash functions
Public Key Encryption & Hash functionsPublic Key Encryption & Hash functions
Public Key Encryption & Hash functions
Dr.Florence Dayana
 
6.hash mac
6.hash mac6.hash mac
6.hash mac
Virendrakumar Dhotre
 
Lecture 2 Message Authentication
Lecture 2   Message AuthenticationLecture 2   Message Authentication
Lecture 2 Message Authentication
University of Rome "La Sapienza"
 
Public key cryptography and message authentication
Public key cryptography and message authenticationPublic key cryptography and message authentication
Public key cryptography and message authentication
CAS
 
Hash Function
Hash FunctionHash Function
Hash Function
Siddharth Srivastava
 
Hash
HashHash
Hash
Tazo Al
 
20CS2008 Computer Networks
20CS2008 Computer Networks 20CS2008 Computer Networks
20CS2008 Computer Networks
Kathirvel Ayyaswamy
 
Cryptography and Message Authentication NS3
Cryptography and Message Authentication NS3Cryptography and Message Authentication NS3
Cryptography and Message Authentication NS3
koolkampus
 
MAC-Message Authentication Codes
MAC-Message Authentication CodesMAC-Message Authentication Codes
MAC-Message Authentication Codes
DarshanPatil82
 
Message AUthentication Code
Message AUthentication CodeMessage AUthentication Code
Message AUthentication Code
Keval Bhogayata
 
Message authentication and hash function
Message authentication and hash functionMessage authentication and hash function
Message authentication and hash function
omarShiekh1
 
Hash& mac algorithms
Hash& mac algorithmsHash& mac algorithms
Hash& mac algorithms
Harry Potter
 
Message Authentication
Message AuthenticationMessage Authentication
Message Authentication
chauhankapil
 
Message integrity protocol
Message integrity protocolMessage integrity protocol
Message integrity protocol
PriyaKarnan3
 
HMAC authentication
HMAC authenticationHMAC authentication
HMAC authentication
Siu Tin
 
Distribution of public keys and hmac
Distribution of public keys and hmacDistribution of public keys and hmac
Distribution of public keys and hmac
anuragjagetiya
 
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
 
Public Key Encryption & Hash functions
Public Key Encryption & Hash functionsPublic Key Encryption & Hash functions
Public Key Encryption & Hash functions
Dr.Florence Dayana
 
Public key cryptography and message authentication
Public key cryptography and message authenticationPublic key cryptography and message authentication
Public key cryptography and message authentication
CAS
 

Viewers also liked (13)

L8 signal encoding techniques
L8 signal encoding techniquesL8 signal encoding techniques
L8 signal encoding techniques
Md. Shafiul Alam Sagor
 
05 signal encoding
05 signal encoding05 signal encoding
05 signal encoding
Bestha Harish
 
signal encoding techniques
signal encoding techniquessignal encoding techniques
signal encoding techniques
Srinivasa Rao
 
10 lecture - ospf part1 , introduction to ospf , areas and abr
10   lecture  - ospf part1 , introduction to ospf , areas and abr10   lecture  - ospf part1 , introduction to ospf , areas and abr
10 lecture - ospf part1 , introduction to ospf , areas and abr
Shafaan Khaliq Bhatti
 
Encoding techniques
Encoding techniquesEncoding techniques
Encoding techniques
Goriha Naveed
 
Data encoding
Data encodingData encoding
Data encoding
Akash Bhandari
 
4 signal encodingtechniques
4 signal encodingtechniques4 signal encodingtechniques
4 signal encodingtechniques
Hattori Sidek
 
Data Encoding
Data EncodingData Encoding
Data Encoding
Luka M G
 
15 lecture - acl part1, introduction to access control list
15   lecture  - acl part1, introduction to access control list15   lecture  - acl part1, introduction to access control list
15 lecture - acl part1, introduction to access control list
Shafaan Khaliq Bhatti
 
13 lecture - introduction and configuration of eigrp
13   lecture  - introduction and configuration of eigrp13   lecture  - introduction and configuration of eigrp
13 lecture - introduction and configuration of eigrp
Shafaan Khaliq Bhatti
 
Chapter 5 - Signal Encoding Techniques 9e
Chapter 5 - Signal Encoding Techniques 9eChapter 5 - Signal Encoding Techniques 9e
Chapter 5 - Signal Encoding Techniques 9e
adpeer
 
Chapter 1: Introduction to Data Communication and Networks
Chapter 1: Introduction to Data Communication and NetworksChapter 1: Introduction to Data Communication and Networks
Chapter 1: Introduction to Data Communication and Networks
Shafaan Khaliq Bhatti
 
Chapter 4 - Digital Transmission
Chapter 4 - Digital TransmissionChapter 4 - Digital Transmission
Chapter 4 - Digital Transmission
Wayne Jones Jnr
 
signal encoding techniques
signal encoding techniquessignal encoding techniques
signal encoding techniques
Srinivasa Rao
 
10 lecture - ospf part1 , introduction to ospf , areas and abr
10   lecture  - ospf part1 , introduction to ospf , areas and abr10   lecture  - ospf part1 , introduction to ospf , areas and abr
10 lecture - ospf part1 , introduction to ospf , areas and abr
Shafaan Khaliq Bhatti
 
4 signal encodingtechniques
4 signal encodingtechniques4 signal encodingtechniques
4 signal encodingtechniques
Hattori Sidek
 
Data Encoding
Data EncodingData Encoding
Data Encoding
Luka M G
 
15 lecture - acl part1, introduction to access control list
15   lecture  - acl part1, introduction to access control list15   lecture  - acl part1, introduction to access control list
15 lecture - acl part1, introduction to access control list
Shafaan Khaliq Bhatti
 
13 lecture - introduction and configuration of eigrp
13   lecture  - introduction and configuration of eigrp13   lecture  - introduction and configuration of eigrp
13 lecture - introduction and configuration of eigrp
Shafaan Khaliq Bhatti
 
Chapter 5 - Signal Encoding Techniques 9e
Chapter 5 - Signal Encoding Techniques 9eChapter 5 - Signal Encoding Techniques 9e
Chapter 5 - Signal Encoding Techniques 9e
adpeer
 
Chapter 1: Introduction to Data Communication and Networks
Chapter 1: Introduction to Data Communication and NetworksChapter 1: Introduction to Data Communication and Networks
Chapter 1: Introduction to Data Communication and Networks
Shafaan Khaliq Bhatti
 
Chapter 4 - Digital Transmission
Chapter 4 - Digital TransmissionChapter 4 - Digital Transmission
Chapter 4 - Digital Transmission
Wayne Jones Jnr
 
Ad

Similar to Message Authentication: MAC, Hashes (20)

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
 
unit - III.pptx
unit - III.pptxunit - III.pptx
unit - III.pptx
sandyBS
 
Information and network security 41 message authentication code
Information and network security 41 message authentication codeInformation and network security 41 message authentication code
Information and network security 41 message authentication code
Vaibhav Khanna
 
cryptography and network security by william stallings
cryptography and network security by william stallingscryptography and network security by william stallings
cryptography and network security by william stallings
HimaniP19CSE013
 
ch11.ppt
ch11.pptch11.ppt
ch11.ppt
ssuser4198c4
 
BAIT1103 Chapter 2
BAIT1103 Chapter 2BAIT1103 Chapter 2
BAIT1103 Chapter 2
limsh
 
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 network security 42 security of message authentication code
Information and network security 42 security of message authentication codeInformation and network security 42 security of message authentication code
Information and network security 42 security of message authentication code
Vaibhav Khanna
 
Cns
CnsCns
Cns
ArthyR3
 
TLS/SSL Protocol Design 201006
TLS/SSL Protocol Design 201006TLS/SSL Protocol Design 201006
TLS/SSL Protocol Design 201006
Nate Lawson
 
Message auth. code Based on Hash Functions.pptx
Message auth. code Based on Hash Functions.pptxMessage auth. code Based on Hash Functions.pptx
Message auth. code Based on Hash Functions.pptx
aribariaz507
 
cryptography and network security cns.pptx
cryptography and network security cns.pptxcryptography and network security cns.pptx
cryptography and network security cns.pptx
gkumar610
 
ch11.ppt
ch11.pptch11.ppt
ch11.ppt
SomuPatil8
 
final ppt TS.pptx
final ppt TS.pptxfinal ppt TS.pptx
final ppt TS.pptx
paluribalu2001
 
Message Authentication Requirement-MAC
Message Authentication Requirement-MACMessage Authentication Requirement-MAC
Message Authentication Requirement-MAC
Sou Jana
 
Module 2.pdf
Module 2.pdfModule 2.pdf
Module 2.pdf
Sitamarhi Institute of Technology
 
Module 2.Cryptography and Cryptanalysis
Module 2.Cryptography and CryptanalysisModule 2.Cryptography and Cryptanalysis
Module 2.Cryptography and Cryptanalysis
Sitamarhi Institute of Technology
 
Unit 3
Unit 3Unit 3
Unit 3
tamil arasan
 
crypto.pptx
crypto.pptxcrypto.pptx
crypto.pptx
GayathriP95
 
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
 
unit - III.pptx
unit - III.pptxunit - III.pptx
unit - III.pptx
sandyBS
 
Information and network security 41 message authentication code
Information and network security 41 message authentication codeInformation and network security 41 message authentication code
Information and network security 41 message authentication code
Vaibhav Khanna
 
cryptography and network security by william stallings
cryptography and network security by william stallingscryptography and network security by william stallings
cryptography and network security by william stallings
HimaniP19CSE013
 
BAIT1103 Chapter 2
BAIT1103 Chapter 2BAIT1103 Chapter 2
BAIT1103 Chapter 2
limsh
 
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 network security 42 security of message authentication code
Information and network security 42 security of message authentication codeInformation and network security 42 security of message authentication code
Information and network security 42 security of message authentication code
Vaibhav Khanna
 
TLS/SSL Protocol Design 201006
TLS/SSL Protocol Design 201006TLS/SSL Protocol Design 201006
TLS/SSL Protocol Design 201006
Nate Lawson
 
Message auth. code Based on Hash Functions.pptx
Message auth. code Based on Hash Functions.pptxMessage auth. code Based on Hash Functions.pptx
Message auth. code Based on Hash Functions.pptx
aribariaz507
 
cryptography and network security cns.pptx
cryptography and network security cns.pptxcryptography and network security cns.pptx
cryptography and network security cns.pptx
gkumar610
 
Message Authentication Requirement-MAC
Message Authentication Requirement-MACMessage Authentication Requirement-MAC
Message Authentication Requirement-MAC
Sou Jana
 
Ad

More from Shafaan Khaliq Bhatti (20)

1- Introduction to Red Hat
1- Introduction to Red Hat1- Introduction to Red Hat
1- Introduction to Red Hat
Shafaan Khaliq Bhatti
 
Linux Servers
Linux ServersLinux Servers
Linux Servers
Shafaan Khaliq Bhatti
 
5 - Networking in Red Hat
5 - Networking in Red Hat5 - Networking in Red Hat
5 - Networking in Red Hat
Shafaan Khaliq Bhatti
 
2- System Initialization in Red Hat
2- System Initialization in Red Hat2- System Initialization in Red Hat
2- System Initialization in Red Hat
Shafaan Khaliq Bhatti
 
3 - Disk Partitioning in Red Hat
3 - Disk Partitioning in Red Hat3 - Disk Partitioning in Red Hat
3 - Disk Partitioning in Red Hat
Shafaan Khaliq Bhatti
 
6 - Package Management in Red Hat
6 - Package Management in Red Hat6 - Package Management in Red Hat
6 - Package Management in Red Hat
Shafaan Khaliq Bhatti
 
11 - SELinux in Red Hat
11 - SELinux in Red Hat11 - SELinux in Red Hat
11 - SELinux in Red Hat
Shafaan Khaliq Bhatti
 
7 - User Administration in Red Hat
7 - User Administration in Red Hat7 - User Administration in Red Hat
7 - User Administration in Red Hat
Shafaan Khaliq Bhatti
 
12 - System Security in Red Hat
12 - System Security in Red Hat12 - System Security in Red Hat
12 - System Security in Red Hat
Shafaan Khaliq Bhatti
 
Protocols for Public Key Management
Protocols for Public Key ManagementProtocols for Public Key Management
Protocols for Public Key Management
Shafaan Khaliq Bhatti
 
Authentication: keys, MAC
Authentication: keys, MACAuthentication: keys, MAC
Authentication: keys, MAC
Shafaan Khaliq Bhatti
 
Public key cryptography and RSA
Public key cryptography and RSAPublic key cryptography and RSA
Public key cryptography and RSA
Shafaan Khaliq Bhatti
 
Block Ciphers Modes of Operation
Block Ciphers Modes of OperationBlock Ciphers Modes of Operation
Block Ciphers Modes of Operation
Shafaan Khaliq Bhatti
 
Chapter 3: Block Ciphers and the Data Encryption Standard
Chapter 3: Block Ciphers and the Data Encryption StandardChapter 3: Block Ciphers and the Data Encryption Standard
Chapter 3: Block Ciphers and the Data Encryption Standard
Shafaan Khaliq Bhatti
 
Chapter 1: Overview of Network Security
Chapter 1: Overview of Network SecurityChapter 1: Overview of Network Security
Chapter 1: Overview of Network Security
Shafaan Khaliq Bhatti
 
Chapter 3: Processes
Chapter 3: ProcessesChapter 3: Processes
Chapter 3: Processes
Shafaan Khaliq Bhatti
 
Chapter 2: Operating System Structures
Chapter 2: Operating System StructuresChapter 2: Operating System Structures
Chapter 2: Operating System Structures
Shafaan Khaliq Bhatti
 
Chapter 1: Introduction to Operating System
Chapter 1: Introduction to Operating SystemChapter 1: Introduction to Operating System
Chapter 1: Introduction to Operating System
Shafaan Khaliq Bhatti
 
Chapter 2: Network Models
Chapter 2: Network ModelsChapter 2: Network Models
Chapter 2: Network Models
Shafaan Khaliq Bhatti
 
Chapter 20: Internet Protocol
Chapter 20: Internet ProtocolChapter 20: Internet Protocol
Chapter 20: Internet Protocol
Shafaan Khaliq Bhatti
 
Chapter 3: Block Ciphers and the Data Encryption Standard
Chapter 3: Block Ciphers and the Data Encryption StandardChapter 3: Block Ciphers and the Data Encryption Standard
Chapter 3: Block Ciphers and the Data Encryption Standard
Shafaan Khaliq Bhatti
 
Chapter 1: Overview of Network Security
Chapter 1: Overview of Network SecurityChapter 1: Overview of Network Security
Chapter 1: Overview of Network Security
Shafaan Khaliq Bhatti
 
Chapter 2: Operating System Structures
Chapter 2: Operating System StructuresChapter 2: Operating System Structures
Chapter 2: Operating System Structures
Shafaan Khaliq Bhatti
 
Chapter 1: Introduction to Operating System
Chapter 1: Introduction to Operating SystemChapter 1: Introduction to Operating System
Chapter 1: Introduction to Operating System
Shafaan Khaliq Bhatti
 

Recently uploaded (20)

Drive Supporter Growth from Awareness to Advocacy with TechSoup Marketing Ser...
Drive Supporter Growth from Awareness to Advocacy with TechSoup Marketing Ser...Drive Supporter Growth from Awareness to Advocacy with TechSoup Marketing Ser...
Drive Supporter Growth from Awareness to Advocacy with TechSoup Marketing Ser...
TechSoup
 
LDMMIA Reiki News Ed3 Vol1 For Team and Guests
LDMMIA Reiki News Ed3 Vol1 For Team and GuestsLDMMIA Reiki News Ed3 Vol1 For Team and Guests
LDMMIA Reiki News Ed3 Vol1 For Team and Guests
LDM Mia eStudios
 
Cultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptxCultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptx
UmeshTimilsina1
 
LDMMIA Reiki Yoga S5 Daily Living Workshop
LDMMIA Reiki Yoga S5 Daily Living WorkshopLDMMIA Reiki Yoga S5 Daily Living Workshop
LDMMIA Reiki Yoga S5 Daily Living Workshop
LDM Mia eStudios
 
All About the 990 Unlocking Its Mysteries and Its Power.pdf
All About the 990 Unlocking Its Mysteries and Its Power.pdfAll About the 990 Unlocking Its Mysteries and Its Power.pdf
All About the 990 Unlocking Its Mysteries and Its Power.pdf
TechSoup
 
BỘ ĐỀ TUYỂN SINH VÀO LỚP 10 TIẾNG ANH - 25 ĐỀ THI BÁM SÁT CẤU TRÚC MỚI NHẤT, ...
BỘ ĐỀ TUYỂN SINH VÀO LỚP 10 TIẾNG ANH - 25 ĐỀ THI BÁM SÁT CẤU TRÚC MỚI NHẤT, ...BỘ ĐỀ TUYỂN SINH VÀO LỚP 10 TIẾNG ANH - 25 ĐỀ THI BÁM SÁT CẤU TRÚC MỚI NHẤT, ...
BỘ ĐỀ TUYỂN SINH VÀO LỚP 10 TIẾNG ANH - 25 ĐỀ THI BÁM SÁT CẤU TRÚC MỚI NHẤT, ...
Nguyen Thanh Tu Collection
 
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Leonel Morgado
 
Kenan Fellows Participants, Projects 2025-26 Cohort
Kenan Fellows Participants, Projects 2025-26 CohortKenan Fellows Participants, Projects 2025-26 Cohort
Kenan Fellows Participants, Projects 2025-26 Cohort
EducationNC
 
Grade 2 - Mathematics - Printable Worksheet
Grade 2 - Mathematics - Printable WorksheetGrade 2 - Mathematics - Printable Worksheet
Grade 2 - Mathematics - Printable Worksheet
Sritoma Majumder
 
Tax evasion, Tax planning & Tax avoidance.pptx
Tax evasion, Tax  planning &  Tax avoidance.pptxTax evasion, Tax  planning &  Tax avoidance.pptx
Tax evasion, Tax planning & Tax avoidance.pptx
manishbaidya2017
 
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptxSCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
Ronisha Das
 
How to Manage Purchase Alternatives in Odoo 18
How to Manage Purchase Alternatives in Odoo 18How to Manage Purchase Alternatives in Odoo 18
How to Manage Purchase Alternatives in Odoo 18
Celine George
 
Lecture 4 INSECT CUTICLE and moulting.pptx
Lecture 4 INSECT CUTICLE and moulting.pptxLecture 4 INSECT CUTICLE and moulting.pptx
Lecture 4 INSECT CUTICLE and moulting.pptx
Arshad Shaikh
 
What is the Philosophy of Statistics? (and how I was drawn to it)
What is the Philosophy of Statistics? (and how I was drawn to it)What is the Philosophy of Statistics? (and how I was drawn to it)
What is the Philosophy of Statistics? (and how I was drawn to it)
jemille6
 
Ancient Stone Sculptures of India: As a Source of Indian History
Ancient Stone Sculptures of India: As a Source of Indian HistoryAncient Stone Sculptures of India: As a Source of Indian History
Ancient Stone Sculptures of India: As a Source of Indian History
Virag Sontakke
 
Exercise Physiology MCQS By DR. NASIR MUSTAFA
Exercise Physiology MCQS By DR. NASIR MUSTAFAExercise Physiology MCQS By DR. NASIR MUSTAFA
Exercise Physiology MCQS By DR. NASIR MUSTAFA
Dr. Nasir Mustafa
 
How to Configure Public Holidays & Mandatory Days in Odoo 18
How to Configure Public Holidays & Mandatory Days in Odoo 18How to Configure Public Holidays & Mandatory Days in Odoo 18
How to Configure Public Holidays & Mandatory Days in Odoo 18
Celine George
 
Link your Lead Opportunities into Spreadsheet using odoo CRM
Link your Lead Opportunities into Spreadsheet using odoo CRMLink your Lead Opportunities into Spreadsheet using odoo CRM
Link your Lead Opportunities into Spreadsheet using odoo CRM
Celine George
 
Grade 3 - English - Printable Worksheet (PDF Format)
Grade 3 - English - Printable Worksheet  (PDF Format)Grade 3 - English - Printable Worksheet  (PDF Format)
Grade 3 - English - Printable Worksheet (PDF Format)
Sritoma Majumder
 
Herbs Used in Cosmetic Formulations .pptx
Herbs Used in Cosmetic Formulations .pptxHerbs Used in Cosmetic Formulations .pptx
Herbs Used in Cosmetic Formulations .pptx
RAJU THENGE
 
Drive Supporter Growth from Awareness to Advocacy with TechSoup Marketing Ser...
Drive Supporter Growth from Awareness to Advocacy with TechSoup Marketing Ser...Drive Supporter Growth from Awareness to Advocacy with TechSoup Marketing Ser...
Drive Supporter Growth from Awareness to Advocacy with TechSoup Marketing Ser...
TechSoup
 
LDMMIA Reiki News Ed3 Vol1 For Team and Guests
LDMMIA Reiki News Ed3 Vol1 For Team and GuestsLDMMIA Reiki News Ed3 Vol1 For Team and Guests
LDMMIA Reiki News Ed3 Vol1 For Team and Guests
LDM Mia eStudios
 
Cultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptxCultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptx
UmeshTimilsina1
 
LDMMIA Reiki Yoga S5 Daily Living Workshop
LDMMIA Reiki Yoga S5 Daily Living WorkshopLDMMIA Reiki Yoga S5 Daily Living Workshop
LDMMIA Reiki Yoga S5 Daily Living Workshop
LDM Mia eStudios
 
All About the 990 Unlocking Its Mysteries and Its Power.pdf
All About the 990 Unlocking Its Mysteries and Its Power.pdfAll About the 990 Unlocking Its Mysteries and Its Power.pdf
All About the 990 Unlocking Its Mysteries and Its Power.pdf
TechSoup
 
BỘ ĐỀ TUYỂN SINH VÀO LỚP 10 TIẾNG ANH - 25 ĐỀ THI BÁM SÁT CẤU TRÚC MỚI NHẤT, ...
BỘ ĐỀ TUYỂN SINH VÀO LỚP 10 TIẾNG ANH - 25 ĐỀ THI BÁM SÁT CẤU TRÚC MỚI NHẤT, ...BỘ ĐỀ TUYỂN SINH VÀO LỚP 10 TIẾNG ANH - 25 ĐỀ THI BÁM SÁT CẤU TRÚC MỚI NHẤT, ...
BỘ ĐỀ TUYỂN SINH VÀO LỚP 10 TIẾNG ANH - 25 ĐỀ THI BÁM SÁT CẤU TRÚC MỚI NHẤT, ...
Nguyen Thanh Tu Collection
 
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Leonel Morgado
 
Kenan Fellows Participants, Projects 2025-26 Cohort
Kenan Fellows Participants, Projects 2025-26 CohortKenan Fellows Participants, Projects 2025-26 Cohort
Kenan Fellows Participants, Projects 2025-26 Cohort
EducationNC
 
Grade 2 - Mathematics - Printable Worksheet
Grade 2 - Mathematics - Printable WorksheetGrade 2 - Mathematics - Printable Worksheet
Grade 2 - Mathematics - Printable Worksheet
Sritoma Majumder
 
Tax evasion, Tax planning & Tax avoidance.pptx
Tax evasion, Tax  planning &  Tax avoidance.pptxTax evasion, Tax  planning &  Tax avoidance.pptx
Tax evasion, Tax planning & Tax avoidance.pptx
manishbaidya2017
 
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptxSCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
SCI BIZ TECH QUIZ (OPEN) PRELIMS XTASY 2025.pptx
Ronisha Das
 
How to Manage Purchase Alternatives in Odoo 18
How to Manage Purchase Alternatives in Odoo 18How to Manage Purchase Alternatives in Odoo 18
How to Manage Purchase Alternatives in Odoo 18
Celine George
 
Lecture 4 INSECT CUTICLE and moulting.pptx
Lecture 4 INSECT CUTICLE and moulting.pptxLecture 4 INSECT CUTICLE and moulting.pptx
Lecture 4 INSECT CUTICLE and moulting.pptx
Arshad Shaikh
 
What is the Philosophy of Statistics? (and how I was drawn to it)
What is the Philosophy of Statistics? (and how I was drawn to it)What is the Philosophy of Statistics? (and how I was drawn to it)
What is the Philosophy of Statistics? (and how I was drawn to it)
jemille6
 
Ancient Stone Sculptures of India: As a Source of Indian History
Ancient Stone Sculptures of India: As a Source of Indian HistoryAncient Stone Sculptures of India: As a Source of Indian History
Ancient Stone Sculptures of India: As a Source of Indian History
Virag Sontakke
 
Exercise Physiology MCQS By DR. NASIR MUSTAFA
Exercise Physiology MCQS By DR. NASIR MUSTAFAExercise Physiology MCQS By DR. NASIR MUSTAFA
Exercise Physiology MCQS By DR. NASIR MUSTAFA
Dr. Nasir Mustafa
 
How to Configure Public Holidays & Mandatory Days in Odoo 18
How to Configure Public Holidays & Mandatory Days in Odoo 18How to Configure Public Holidays & Mandatory Days in Odoo 18
How to Configure Public Holidays & Mandatory Days in Odoo 18
Celine George
 
Link your Lead Opportunities into Spreadsheet using odoo CRM
Link your Lead Opportunities into Spreadsheet using odoo CRMLink your Lead Opportunities into Spreadsheet using odoo CRM
Link your Lead Opportunities into Spreadsheet using odoo CRM
Celine George
 
Grade 3 - English - Printable Worksheet (PDF Format)
Grade 3 - English - Printable Worksheet  (PDF Format)Grade 3 - English - Printable Worksheet  (PDF Format)
Grade 3 - English - Printable Worksheet (PDF Format)
Sritoma Majumder
 
Herbs Used in Cosmetic Formulations .pptx
Herbs Used in Cosmetic Formulations .pptxHerbs Used in Cosmetic Formulations .pptx
Herbs Used in Cosmetic Formulations .pptx
RAJU THENGE
 

Message Authentication: MAC, Hashes

  • 2. Message authentication • Goal here: having received a message one would like to make sure that the message has not been altered on the way – �Produce a short sequence of bits that depends on the message and on a secret key – �To authenticate the message, the partner will compute the same bit pattern, assuming he shares the same secret key • �This does not necessarily includes encrypting or signing the message – �The message can be sent in plain, with the authenticator appended – �This is not a digital signature: the receiver can produce the same MAC – �One may encrypt the authenticator with his private key to produce a digital signature – �One may encrypt both the message and the authenticator • �Possible attacks on message authentication: – �Content modification – �Sequence modification–modifications to a sequence of messages, including insertion, deletion, reordering – �Timing modification–delay or replay message
  • 3. Authentication functions • Three types of authentication exist • �Message encryption–the ciphertext serves as authenticator • �Message authentication code (MAC)–a public function of the message and a secret key producing a fixed- length value to serve as authenticator • �This does not provide a digital signature because A and B share the same key • �Hash function–a public function mapping an arbitrary length message into a fixed-length hash value to serve as authenticator – �This does not provide a digital signature because there is no key
  • 4. I. Message encryption as authentication • Main idea here: the message must have come from A because the ciphertext can be decrypted using his (secret or public) key • �Also, none of the bits in the message have been altered because an opponent does not know how to manipulate the bits of the ciphertext to induce meaningful changes to the plaintext • �Conclusion: encryption (either symmetric or public-key) provides authentication as well as confidentiality
  • 5. More to authentication than simple encryption? • �Often one needs alternative authentication schemes than just encrypting the message – �Sometimes one needs to avoid encryption of full messages due to legal requirements – �Encryption and authentication may be separated in the system architecture – �If a message is broadcast to several destinations in a network (such as a military control center), then it is cheaper and more reliable to have just one node responsible to evaluate the authenticity –message will be sent in plain with an attached authenticator – �If one side has a heavy load, it cannot afford to decrypt all messages – it will just check the authenticity of some randomly selected messages – �If the message is sent encrypted, it is of course protected over the network. However, once the receiver decrypts the message, it is no longer secure. Using a different type of authentication protects the message also on the local computer
  • 6. Message authentication code (MAC) • To generate the MAC of a message M, Alice gives M and the secret key K to a MAC function C: MAC=CK(M) – �Alice will send M plus the MAC to Bob – �Bob has the same secret key K and generates the MAC himself to check the match • �Typical attacks on MACs – �Produce an illegitimate message with the same signature as a given (or chosen) legitimate one – �Produce a valid MAC for an illegitimate message • �Requirements for MACs – �The MAC function is in general many-to-one –messages are arbitrarily long and the MAC has fixed length, thus there will be more than one message with the same MAC – �Computationally easy to compute the MAC – �Knowing M and CK(M) it is computationally infeasible to construct another message M’ with CK(M’)= CK(M) – �CK(M) is uniformly distributed –if the attacker chooses a random bit pattern of length n, the chances of it being the correct signature is 2-n – �If M’ is obtained from M by certain transformations (even switching one bit), then the probability that the two have the same MAC is 2-n
  • 8. cryptographic hash • A "hash" (also called a "digest", and informally a "checksum") is a kind of "signature" for a stream of data that represents the contents • We'll note here that though hashes and digests are often informally called "checksums", they really aren't. True checksums, such as a Cyclic Redundancy Check are designed to catch data-transmission errors and not deliberate attempts at tampering with data • Many Unix and Linux systems provide the md5sum program, which reads a stream of data and produces a fixed, 128-bit number that summarizes that stream using the popular "MD5" method. • This shows that all input streams yield hashes of the same length, and to experiment, try changing just one character of a small test file. You'll find that even very small changes to the input yields sweeping changes in the value of the hash, and this is known as the avalanche effect.
  • 9. Hashes are "digests", not "encryption" • Encryption transforms data from a cleartext to ciphertext and back (given the right keys), and the two texts should roughly correspond to each other in size: big cleartext yields big ciphertext, and so on. "Encryption" is a two-way operation.
  • 10. Hashes one way • Hashes, on the other hand, compile a stream of data into a small digest (a summarized form: think "Reader's Digest"), and it's strictly a one way operation. All hashes of the same type - this example shows the "MD5" variety - have the same size no matter how big the inputs are:
  • 11. Authentication based on hash functions• A fixed-length hash value h is generated by a function H that takes as input a message of arbitrary length: h=H(M) – �A sends M and H(M) – �B authenticates the message by computing H(M) and checking the match • �Requirements for a hash function – �H can be applied to a message of any size – �H produces fixed-length output – �Computationally easy to compute H(M) – �Computationally infeasible to find M such that H(M)=h, for a given h – �Computationally infeasible to find M’ such that H(M’)=H(M), for a given M – �Computationally infeasible to find M,M’ with H(M)=H(M’) (to resist to birthday attacks) • �Note: the hash function is not considered secret –some other means are required to protect it • �Note 2: Hash function plus secrecy (key) gives a MAC –these are called HMACs