SlideShare a Scribd company logo
1 of 79
Unit– III Cryptography
(06 Hrs.) 14 Marks
Unit Outcomes
3a. Encrypt/Decrypt the given text using different substitution techniques.
3b. Convert plain text to cipher text and vice versa using the given
transposition technique.
3c. Convert the given message using steganography.
3d. Explain the given technique of cryptography using example.
Topics and Sub-topics
3.1 Introduction: Plain Text, Cipher Text, Cryptography, Cryptanalysis,
Cryptology, Encryption, Decryption.
3.2 Substitution Techniques: Caesar's Cipher, Modified Caesar's Cipher,
Transposition Techniques: Simple Columnar Transposition.
3.3 Steganography: Procedure
3.4 Symmetric and Asymmetric cryptography: Introduction to
Symmetric encryption, DES (Data encryption Standard) algorithm,
Asymmetric key cryptography: Digital Signature.
Introduction
• Cryptography is one of the oldest techniques at least 4,000 years to convert
readable text to unreadable and not understandable.
• Before 1900 B.C., Egyptian used symbols and pictures in a random fashion,
to hide the meaning from those who did not know the meaning.
Symbols taken from the tomb of Khnumhotep I
Introduction
• The Greek’s been wrapping a tape around a stick, and then write the
message on the wound tape.
• When the tape was unwound, the writing was meaningless.
• To decipher the message, the receiver of the message would of course have
a stick of the same diameter.
Introduction
Introduction
• The Roman method of cryptography was known as the
Caesar Cipher, the earliest known, and the simplest
cipher technique.
• It works on the idea of shifting letters by an agreed
upon number.
A statue of Julius
Caesar
Terms used in Cryptography
• Plain Text
• Cipher Text
• Cryptography
• Cryptanalysis
• Cryptology
• Encryption
• Decryption
Plain Text
• It is the original understandable message.
• Plain text is the contents of an ordinary sequential file readable as
textual material.
• Plaintext is the input to an encryption algorithm.
• Plain text means its text that hasn't been formatted
• Example: Hello how are you.
Cipher Text
• It is the transformed message.
• Cipher text is the output of the process performed on plaintext using
an encryption algorithm.
• When plain text message is modified using any suitable scheme, the
resulting message is called Cipher text or Cipher.
• Cipher text is the unreadable output of an encryption algorithm
• Example: Y0ewfmGI4/0X/RYpTijcCU52t1wxCqk5
Cryptography
• Crypto: Secret
• Graphy: Writing
• Cryptography is the art or science encompassing the principles and
methods of converting an understandable message into one that is
meaningless and then retransforming that message back to its
original form.
Cryptanalysis
• Cryptanalysis is the study of ciphertext, ciphers and cryptosystems with the aim of
understanding how they work and finding and improving techniques for defeating
or weakening them.
• It is also called as code breaking.
• Cryptanalysis is the science of exploring and breaching secure communication.
Cryptology
• Cryptology, science concerned with data communication and storage in
secure and usually secret form.
• Cryptology is the science of coding and decoding secret or hidden messages.
• It encompasses both cryptography and cryptanalysis.
Encryption
• It is the process of transforming plaintext to cipher text using a cipher
and a key.
• It is also known as enciphering or encoding.
Decryption
• Decryption is the process of converting cipher text back to plaintext.
• It is also known as deciphering or decoding.
Substitution Techniques
• A substitution technique is one in which the letters of plaintext are
replaced by other letters or by numbers or symbols.
• If the plaintext is considered as a sequence of bits, then substitution
includes replacing plaintext bit patterns with cipher text bit patterns.
Types of Substitution Techniques
• Monoalphabetic (Caesar's cipher)
• Polyalphabetic (Vigenère Cipher)
• One-time pad
Caesar’s Cipher
• Simplest and very first known substitution cipher used by Roman
Emperor Julius Caesar.
• The Caesar cipher includes replacing each letter of the alphabet with
the letter standing three places further down the alphabet.
• For example,
Plain Text : HELLO HOW ARE YOU
Cipher Text: KHOOR KRZ DUH BRX
Caesar’s Cipher
• In this technique alphabet is wrapped around, i.e. A is following letter
Z as shown below
Plain Text A B C D E F G H I J K L M
Cipher
Text
D E F G H I J K L M N O P
Plain Text N O P Q R S T U V W X Y Z
Cipher
Text
Q R S T U V W X Y Z A B C
Caesar’s Cipher
• If numbers are assigned to each alphabet the A will be assign 0 and Z
will be assign 25.
• Then algorithm can be expressed as follows.
• For each plaintext letter P, substitute the cipher text letter C, Encryption
E and Decryption D and Key K (Generally K = 3):
• Then,
C = E (3, P) = (P + 3) mod 26
• If a shift is of any amount, then the general Caesar algorithm is
C = E (K, P) = (P + K) mod 26 (Modified Caesar Cipher)
• Where, K is any value from 1 to 25. The decryption algorithm is as follow
P = D (K, C) = (C - K) mod 26
Limitation of Caesar’s Cipher
• If an adversary knows that that a given cipher text is a Caesar cipher,
then it is easy to discover plain text by performing a brute-force
cryptanalysis
• Simply adversary has to try all the 25 possible keys only.
Limitation of Caesar’s Cipher
• The encryption and decryption algorithms are known.
• There are only 25 keys to try.
• The language of the plaintext is known and easily recognizable.
Transposition Techniques
• Transposition means rearranging the order of arrival of the elements
of the plaintext.
• Transposition is also referred to as permutation.
• In this technique cipher text is generated by changing the position of
the letters or elements of the plaintext.
• For example
Rail Fence
Columnar Techniques
Simple Columnar Transposition
• A columnar transposition, also known as a row-column transpose.
• It is a very simple cipher technique.
• In this technique, the message is written out in rows of a fixed length.
• The message is then read out by column by column, where the
columns are chosen in some scrambled order.
• The number of columns and the order in which they are chosen is
defined by a keyword.
Simple Columnar Transposition
• For example, the word CIPHER is 6 letters long.
• Therefore, there are 6 columns that will be read of in the following
order: 1 4 5 3 2 6.
• The order is chosen by the alphabetical order of the letters in the
keyword.
Single Columnar Cipher (Regular Case)
• In a single columnar transposition cipher (regular case)
the empty spaces are filled with random letters.
• For Example
Plaintext: Hello how are you. Meet me tomorrow.
Key: CIPHER
• The six columns are now written out in the order as
defined by the keyword:
• HOOMOEEMWLREOOEWUERLAMTRHYTMX
C I P H E R
1 4 5 3 2 6
H E L L O H
O W A R E Y
O U M E E T
M E T O M M
O R R O W X
Double Columnar Transposition
• To make the message even more difficult to discover, the cipher text
produced by this algorithm and run it through the encryption again
using a different keyword.
• This transposes the columns twice and makes the message extremely
difficult to decipher.
Double Columnar Transposition
• After first encryption again same process for next
encryption.
• The six columns are now written out in the order as
defined by the keyword:
• HWMOWOLREMMRLETOUTOHOEROYEAEMX
C I P H E R
1 4 5 3 2 6
H O O M O E
W U E R L A
M T R L R E
O O O E E M
W H Y T M X
Steganography
• Steganography is a process that involves hiding a message in an
appropriate carrier like image or audio or video.
• It is of Greek origin and means "covered or hidden writing".
• The carrier can be sent to a receiver without anyone except the
authenticated receiver knowing the existence of this information.
• Steganography differs from Cryptography in the sense that where
cryptography focuses on keeping the contents of a message secret,
steganography focuses on keeping the existence of a message secret.
Steganography
Figure: Generic Image Steganography System
Steganography Process
• Cover-media + Hidden data + Stego-key = Stego-medium
Steganography Process
• Cover media is the file in which the data is hidden and which also can
be encrypted by using stego-key.
• The resulting file is stego-medium.
• Cover-media can be image or audio or video file.
• Steganography precedes cryptography one step further by hiding an
encrypted message so that no one suspects its existence.
Steganography Process
• Ideally, anyone scanning your data will fail to know it contains
encrypted data.
• Stenography has a number of disadvantages when compared to
encryption.
• It requires a lot of overhead to hide a relatively few bits of
information.
Terminologies used in Steganography
• Cover media: It is the media in which we hide the secret message.
• Message (pay load): It also called as hidden data. It is message which
will be hidden in cover or stego media.
• Stego medium (package, converted message): It is medium in which
secret message is hidden.
• Redundant bit: A bit in cover medium that can be modified without
compromising that mediums integrity.
• Stego key : A key used to encode and decode the data
• Stego function: The function for encoding and reverse function for
decoding
Advantages of steganography
• It can be employed by parties who have something to lose should the
fact of their secret communication be discovered.
• Steganography can protect both the message & communication
parties.
• With the help of steganography we can hide secret message within
graphics images.
Disadvantages of steganography
• Requires lots of overhead to hide few bits of information.
• Once the system is discovered it becomes virtually worthless.
• Hiding capacity is less
• Quality of the resultant stego image is a major issue
Symmetric Key Cryptography
• Symmetric Key Cryptography also known as Symmetric Encryption.
• Symmetric key cryptography is any cryptographic algorithm that is
based on a shared key that is used to encryption or decryption.
• Symmetric encryption is a type of encryption where only one key is
used for encryption as well as decryption.
Symmetric Key Cryptography
Figure: Symmetric Key Cryptography
DES (Data Encryption Standard) Algorithm
• The Data Encryption Standard (DES) is one of the most widely used
encryption algorithm.
• It demonstrates the classic Feistel structure.
• DES uses a 64-bit block and a 56-bit key.
• DES, data are encrypted in 64-bit blocks using a 56-bit key.
• The algorithm converts 64-bit input in a series of steps into a 64-bit
output.
• The same steps, using the same key, are used to reverse the encryption.
Overall structure of DES encryption
DES Encryption
• Like any encryption technique, it has two inputs to the encryption
function, the plaintext to be encrypted and the key.
• In this case, the plaintext must be 64 bits in length and the key is 56
bits in length.
DES Encryption
• From left side of figure, the processing of the plaintext is done in
three phases.
• First, the 64-bit plaintext passes through an initial permutation (IP)
that rearranges the bits to produce the permuted input.
• This is followed by a phase consisting of sixteen rounds of the same
function, which involves both permutation and substitution functions.
DES Encryption
• The output of the last (sixteenth) round consists of 64 bits that are a
function of the input plaintext and the key.
• The left and right half parts of the output are swapped to produce the
pre output.
• Finally, the pre output is passed through a permutation [IP-1] which is
the inverse of the initial permutation function that produces the final
64-bit cipher text.
• The right side of Figure shows the how the 56-bit key is used.
DES Encryption
Overall the structure of DES consists of:
• Initial Permutation (IP)
• Sixteen Rounds (Each round contains)
Expansion Permutation
S-box Substitution
XOR-ing
• Inverse Initial Permutation (IP-1)
• Key Generation
Initial Permutation (IP)
• The initial permutation (IP) and its inverse (IP-1) are described by
tables.
• The input to a table contains of 64 bits numbered from 1 to 64.
• The 64 entries in the permutation table contain a permutation of the
numbers from 1 to 64.
• Each value in the permutation table shows the position of a
numbered input bit in the output, which is also of 64 bits.
Initial Permutation (IP)
Inverse Initial Permutation (IP-1)
Single Round structure of DES Algorithm
Details of single round
• Figure shows the internal structure of a single round.
• This structure is same for all rounds.
• From the left-hand side of the diagram, it can be seen that, each
input 64-bit value is treated as separate 32-bit quantities by dividing
them into two halves (the left and right halves), labelled as L (left) and
R (right).
• The overall processing of each round is summarized in the following
formulas:
𝑳𝒊 = 𝑹𝒊 − 𝟏
𝑹𝒊 = 𝑳𝒊 − 𝟏 {𝑭 (𝑹𝒊 − 𝟏, 𝑲𝒊)
Details of single round
• The round key Ki is of 48 bits.
• The R input is 32 bits and is first expanded to 48 bits by using
expansion permutation.
• The resulting 48 bits are XOR ed with Ki.
• This 48-bit result passes through S-Box substitution function which
produces a 32-bit output.
Details of single round
• Each single round consists of:
Expansion Permutation
XOR
S-Box Substitution
Expansion Permutation
• Expansion permutation function expand 32 bits to 48 bits.
• R input, half of the block undergoes an expansion permutation.
• In this process, the expansion and transposition are achieved at the
same time by allowing the 1st and 4th bits in each 4-bit block to
appear twice in the output, i.e., the 4th input bit becomes the 5th
and 7th output bits as shown in table.
Expansion Permutation
Table: Expansion Permutation
As shown in table 1st and 4th bit of every four
bits appear twice in the output by padding 1st
bit to last and last bit to 1st position.
XOR
• The resulting 48-bit block is then XOR-ed with the appropriate subset
key for that round.
S-Box Substitution
• The next operation is to perform substitutions on the expanded block.
• There are eight substitution boxes, called S-boxes.
• The first S-box operates on the first 6 bits of the 48-bit expanded
block, the 2nd S-box on the next six, and so on.
• Each S-box operates from a table of 4 rows and 16 columns.
• Each entry in the table is a 4-bit number.
S-Box Substitution
• The 6-bit number is taken as input to S-Box and is used to look up the
appropriate entry in the table in the following way.
• The 1st and 6th bits are combined together to form a 2-bit number
which refers to a particular row number, and the 2nd to 5th bits are
combined to form a 4-bit number which refers to a particular column.
• The net result of the S-Box Substitution function is eight 4-bit blocks
which are then combined into a 32-bit block.
S-Box Substitution
Figure: S-Box Substitution
S-Box Substitution
For Example:
• Suppose for table S0 6-bit input is 110010,
• Then 1st bit and last bit is combined which is 10 here
• Then row no 2 of table S0 is selected
• And the bits remaining i.e., 1001 selects column no 9 of table S0.
• The entry at this intersection is 12 which is 4-bit value in binary.
Key Generation
• A 64-bit key is used as input to the algorithm. The figure on next slide
shows how to obtain round key from a 64-bit key
• For every round a 48-bit key is generated known as round key.
Key Generation Algorithm
Figure: Key Generation Algorithm
Key Generation
• The bits of the key are numbered from 1 through 64.
• Every eighth bit is ignored, as shown in Table PC1.
• The key is first subjected to a permutation governed by a table
labelled Permuted Choice One – PC1.
• The resulting 56-bit key is then treated as two 28-bit quantities
Key Generation
• These are separately subjected to a circular left shift or (rotation) of 1
or 2 bits, as governed by Table.
• These shifted values provided as input to the next round.
• They also serve as input to the part labelled Permuted Choice Two –
PC2 (Table PC2),
• Which produces a 48-bit output that serves as input to the function F
(Ri-1, Ki).
Key Generation (Table Input Key)
1 2 3 4 5 6 7 8
9 10 11 12 13 14 15 16
17 18 19 20 21 22 23 24
25 26 27 28 29 30 31 32
33 34 35 36 37 38 39 40
41 42 43 44 45 46 47 48
49 50 51 52 53 54 55 56
57 58 59 60 61 62 63 64
Key Generation (Table PC1)
Key Generation (Table PC2)
Asymmetric Key Cryptography
• Asymmetric key cryptography was originally conceived to address
some of the problems in symmetric encryption.
• It addresses the problems of key distribution, generation and
nonrepudiation.
• It is also called as public key cryptography.
• The key pair generated in asymmetric key cryptography systems is
commonly known as public and private keys.
• Public Key: Freely available to anyone in the group or legitimate user.
• Private Key: Kept secret, only user who is holding knows it.
Asymmetric Key Cryptography
• Any message that is encrypted by using public key can only be
decrypted by applying the same algorithm, by using the matching
private key.
• Any message encrypted by using the private key can only be
decrypted by using the matching public key.
Asymmetric Key Cryptography
Figure: Asymmetric Key Cryptography
Digital Signature
• A digital signature
is an authentication mechanism that enables the creator of a message to
attach a code that acts as a signature.
allow us to verify the author, date and time of signatures, authenticate the
message contents.
• It also includes authentication function for additional capabilities.
• Typically, the signature is formed by taking the hash of the message
and encrypting the message with the creator’s private key.
• The signature guarantees the source and integrity of the message.
Digital Signature
• A digital signature or digital signature scheme is a mathematical
scheme for demonstrating the authenticity of a digital message or
document.
• A valid digital signature gives a recipient reason to believe that the
message was created by a known sender, and that it was not altered
in transit.
• Digital signatures are commonly used for software distribution,
financial transactions, and in other cases where it is important to
detect forgery or tampering.
Digital Signature
A digital signature scheme typically consists of three algorithms
• A key generation algorithm that selects a private key uniformly at random
from a set of possible private keys.
The algorithm outputs the private key and a corresponding public key.
• A signing algorithm that, given a message and a private key, produces a
signature.
• A signature verifying algorithm that, given a message, public key and a
signature, either accepts or rejects the message's claim to authenticity.
Digital Signature (Working)
Digital Signature (Working)
• A digital signature performs the same function as its physical
counterpart, the sender “marks” the message so that the recipients
can verify that the message really came from the sender.
• The process of digitally signing a message starts with the creation of a
unique identify for the message.
The unique identifier can be created using a mathematical technique called
Hashing.
Digital Signature (Working)
• A hash function uses a mathematical algorithm to convert the
message into a short fixed-length of bits, often referred to as a “hash
value” or “message digest” that uniquely represents the message
used to create it.
• The hash value is specific to the contents of the message.
Thus, any change to the message contents will change the hash value that
would be generated by the hash function.
Digital Signature (Working)
• Next, the hash value is encrypted using the sender’s private key.
Finally, the message is sent along with the encrypted hash value.
• On receiving the message and the encrypted hash value, the recipient
can only decrypt the hash value using the sender’s public key.
• This confirms that the message came from the sender and no one
else, as long as the sender’s private key remains secure.
• The message can be rehashed and compared with the decrypted hash value-if
the values do not match, then the message has been altered since it was
same

More Related Content

Similar to Unit – III.pptx

Best book for the cryptography doctor.ppt
Best book for the cryptography doctor.pptBest book for the cryptography doctor.ppt
Best book for the cryptography doctor.pptnicolausalex722
 
detailed presentation on cryptography analysis
detailed presentation on cryptography analysisdetailed presentation on cryptography analysis
detailed presentation on cryptography analysisBARATH800940
 
7-cryptography.pptfffffffffffffffffffffffffffffffffff
7-cryptography.pptfffffffffffffffffffffffffffffffffff7-cryptography.pptfffffffffffffffffffffffffffffffffff
7-cryptography.pptfffffffffffffffffffffffffffffffffffmaninthemirrorrror
 
security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.
security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.
security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.nagwaAboElenein
 
Cryptography & Steganography
Cryptography & SteganographyCryptography & Steganography
Cryptography & SteganographyAnimesh Shaw
 
Cns 13f-lec03- Classical Encryption Techniques
Cns 13f-lec03- Classical Encryption TechniquesCns 13f-lec03- Classical Encryption Techniques
Cns 13f-lec03- Classical Encryption Techniquesbabak danyal
 
Classical Encryption Techniques in Network Security
Classical Encryption Techniques in Network SecurityClassical Encryption Techniques in Network Security
Classical Encryption Techniques in Network Securitybabak danyal
 
basic encryption and decryption
 basic encryption and decryption basic encryption and decryption
basic encryption and decryptionRashmi Burugupalli
 
Cryptography and steganography lesson and discription.pptx
Cryptography and steganography lesson and discription.pptxCryptography and steganography lesson and discription.pptx
Cryptography and steganography lesson and discription.pptxRobertCarreonBula
 
Symmetric Encryption Techniques
Symmetric Encryption Techniques Symmetric Encryption Techniques
Symmetric Encryption Techniques Dr. Kapil Gupta
 
Cryptography - Overview
Cryptography - OverviewCryptography - Overview
Cryptography - OverviewMohammed Adam
 
Enhancing security of caesar cipher using different
Enhancing security of caesar cipher using differentEnhancing security of caesar cipher using different
Enhancing security of caesar cipher using differenteSAT Publishing House
 
Cryptography 1
Cryptography 1Cryptography 1
Cryptography 1bhanu7161
 

Similar to Unit – III.pptx (20)

Best book for the cryptography doctor.ppt
Best book for the cryptography doctor.pptBest book for the cryptography doctor.ppt
Best book for the cryptography doctor.ppt
 
detailed presentation on cryptography analysis
detailed presentation on cryptography analysisdetailed presentation on cryptography analysis
detailed presentation on cryptography analysis
 
7-cryptography.pptfffffffffffffffffffffffffffffffffff
7-cryptography.pptfffffffffffffffffffffffffffffffffff7-cryptography.pptfffffffffffffffffffffffffffffffffff
7-cryptography.pptfffffffffffffffffffffffffffffffffff
 
RSA.ppt
RSA.pptRSA.ppt
RSA.ppt
 
7 cryptography
7 cryptography7 cryptography
7 cryptography
 
cryptography.ppt
cryptography.pptcryptography.ppt
cryptography.ppt
 
Cryptography
Cryptography Cryptography
Cryptography
 
security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.
security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.
security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.
 
groupWork.pptx
groupWork.pptxgroupWork.pptx
groupWork.pptx
 
Cryptography & Steganography
Cryptography & SteganographyCryptography & Steganography
Cryptography & Steganography
 
Cns 13f-lec03- Classical Encryption Techniques
Cns 13f-lec03- Classical Encryption TechniquesCns 13f-lec03- Classical Encryption Techniques
Cns 13f-lec03- Classical Encryption Techniques
 
Classical Encryption Techniques in Network Security
Classical Encryption Techniques in Network SecurityClassical Encryption Techniques in Network Security
Classical Encryption Techniques in Network Security
 
basic encryption and decryption
 basic encryption and decryption basic encryption and decryption
basic encryption and decryption
 
Cryptography and steganography lesson and discription.pptx
Cryptography and steganography lesson and discription.pptxCryptography and steganography lesson and discription.pptx
Cryptography and steganography lesson and discription.pptx
 
Symmetric Encryption Techniques
Symmetric Encryption Techniques Symmetric Encryption Techniques
Symmetric Encryption Techniques
 
Cryptography - Overview
Cryptography - OverviewCryptography - Overview
Cryptography - Overview
 
Cryptography
CryptographyCryptography
Cryptography
 
Crpto ppt
Crpto pptCrpto ppt
Crpto ppt
 
Enhancing security of caesar cipher using different
Enhancing security of caesar cipher using differentEnhancing security of caesar cipher using different
Enhancing security of caesar cipher using different
 
Cryptography 1
Cryptography 1Cryptography 1
Cryptography 1
 

Recently uploaded

Introduction to Microprocesso programming and interfacing.pptx
Introduction to Microprocesso programming and interfacing.pptxIntroduction to Microprocesso programming and interfacing.pptx
Introduction to Microprocesso programming and interfacing.pptxvipinkmenon1
 
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...srsj9000
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxpurnimasatapathy1234
 
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130Suhani Kapoor
 
Artificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxArtificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxbritheesh05
 
Current Transformer Drawing and GTP for MSETCL
Current Transformer Drawing and GTP for MSETCLCurrent Transformer Drawing and GTP for MSETCL
Current Transformer Drawing and GTP for MSETCLDeelipZope
 
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETEINFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETEroselinkalist12
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
Past, Present and Future of Generative AI
Past, Present and Future of Generative AIPast, Present and Future of Generative AI
Past, Present and Future of Generative AIabhishek36461
 
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2RajaP95
 
Concrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxConcrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxKartikeyaDwivedi3
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girlsssuser7cb4ff
 
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfCCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfAsst.prof M.Gokilavani
 
Churning of Butter, Factors affecting .
Churning of Butter, Factors affecting  .Churning of Butter, Factors affecting  .
Churning of Butter, Factors affecting .Satyam Kumar
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfAsst.prof M.Gokilavani
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort servicejennyeacort
 

Recently uploaded (20)

Introduction to Microprocesso programming and interfacing.pptx
Introduction to Microprocesso programming and interfacing.pptxIntroduction to Microprocesso programming and interfacing.pptx
Introduction to Microprocesso programming and interfacing.pptx
 
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptx
 
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
 
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
 
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCRCall Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
 
Artificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptxArtificial-Intelligence-in-Electronics (K).pptx
Artificial-Intelligence-in-Electronics (K).pptx
 
Current Transformer Drawing and GTP for MSETCL
Current Transformer Drawing and GTP for MSETCLCurrent Transformer Drawing and GTP for MSETCL
Current Transformer Drawing and GTP for MSETCL
 
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETEINFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
INFLUENCE OF NANOSILICA ON THE PROPERTIES OF CONCRETE
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
Past, Present and Future of Generative AI
Past, Present and Future of Generative AIPast, Present and Future of Generative AI
Past, Present and Future of Generative AI
 
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
 
Concrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxConcrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptx
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girls
 
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
★ CALL US 9953330565 ( HOT Young Call Girls In Badarpur delhi NCR
 
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Serviceyoung call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
 
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdfCCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
CCS355 Neural Network & Deep Learning UNIT III notes and Question bank .pdf
 
Churning of Butter, Factors affecting .
Churning of Butter, Factors affecting  .Churning of Butter, Factors affecting  .
Churning of Butter, Factors affecting .
 
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdfCCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
CCS355 Neural Network & Deep Learning Unit II Notes with Question bank .pdf
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
 

Unit – III.pptx

  • 2. Unit Outcomes 3a. Encrypt/Decrypt the given text using different substitution techniques. 3b. Convert plain text to cipher text and vice versa using the given transposition technique. 3c. Convert the given message using steganography. 3d. Explain the given technique of cryptography using example.
  • 3. Topics and Sub-topics 3.1 Introduction: Plain Text, Cipher Text, Cryptography, Cryptanalysis, Cryptology, Encryption, Decryption. 3.2 Substitution Techniques: Caesar's Cipher, Modified Caesar's Cipher, Transposition Techniques: Simple Columnar Transposition. 3.3 Steganography: Procedure 3.4 Symmetric and Asymmetric cryptography: Introduction to Symmetric encryption, DES (Data encryption Standard) algorithm, Asymmetric key cryptography: Digital Signature.
  • 4. Introduction • Cryptography is one of the oldest techniques at least 4,000 years to convert readable text to unreadable and not understandable. • Before 1900 B.C., Egyptian used symbols and pictures in a random fashion, to hide the meaning from those who did not know the meaning. Symbols taken from the tomb of Khnumhotep I
  • 5. Introduction • The Greek’s been wrapping a tape around a stick, and then write the message on the wound tape. • When the tape was unwound, the writing was meaningless. • To decipher the message, the receiver of the message would of course have a stick of the same diameter.
  • 7. Introduction • The Roman method of cryptography was known as the Caesar Cipher, the earliest known, and the simplest cipher technique. • It works on the idea of shifting letters by an agreed upon number. A statue of Julius Caesar
  • 8. Terms used in Cryptography • Plain Text • Cipher Text • Cryptography • Cryptanalysis • Cryptology • Encryption • Decryption
  • 9. Plain Text • It is the original understandable message. • Plain text is the contents of an ordinary sequential file readable as textual material. • Plaintext is the input to an encryption algorithm. • Plain text means its text that hasn't been formatted • Example: Hello how are you.
  • 10. Cipher Text • It is the transformed message. • Cipher text is the output of the process performed on plaintext using an encryption algorithm. • When plain text message is modified using any suitable scheme, the resulting message is called Cipher text or Cipher. • Cipher text is the unreadable output of an encryption algorithm • Example: Y0ewfmGI4/0X/RYpTijcCU52t1wxCqk5
  • 11. Cryptography • Crypto: Secret • Graphy: Writing • Cryptography is the art or science encompassing the principles and methods of converting an understandable message into one that is meaningless and then retransforming that message back to its original form.
  • 12. Cryptanalysis • Cryptanalysis is the study of ciphertext, ciphers and cryptosystems with the aim of understanding how they work and finding and improving techniques for defeating or weakening them. • It is also called as code breaking. • Cryptanalysis is the science of exploring and breaching secure communication.
  • 13. Cryptology • Cryptology, science concerned with data communication and storage in secure and usually secret form. • Cryptology is the science of coding and decoding secret or hidden messages. • It encompasses both cryptography and cryptanalysis.
  • 14. Encryption • It is the process of transforming plaintext to cipher text using a cipher and a key. • It is also known as enciphering or encoding.
  • 15. Decryption • Decryption is the process of converting cipher text back to plaintext. • It is also known as deciphering or decoding.
  • 16. Substitution Techniques • A substitution technique is one in which the letters of plaintext are replaced by other letters or by numbers or symbols. • If the plaintext is considered as a sequence of bits, then substitution includes replacing plaintext bit patterns with cipher text bit patterns.
  • 17. Types of Substitution Techniques • Monoalphabetic (Caesar's cipher) • Polyalphabetic (Vigenère Cipher) • One-time pad
  • 18. Caesar’s Cipher • Simplest and very first known substitution cipher used by Roman Emperor Julius Caesar. • The Caesar cipher includes replacing each letter of the alphabet with the letter standing three places further down the alphabet. • For example, Plain Text : HELLO HOW ARE YOU Cipher Text: KHOOR KRZ DUH BRX
  • 19. Caesar’s Cipher • In this technique alphabet is wrapped around, i.e. A is following letter Z as shown below Plain Text A B C D E F G H I J K L M Cipher Text D E F G H I J K L M N O P Plain Text N O P Q R S T U V W X Y Z Cipher Text Q R S T U V W X Y Z A B C
  • 20. Caesar’s Cipher • If numbers are assigned to each alphabet the A will be assign 0 and Z will be assign 25. • Then algorithm can be expressed as follows. • For each plaintext letter P, substitute the cipher text letter C, Encryption E and Decryption D and Key K (Generally K = 3): • Then, C = E (3, P) = (P + 3) mod 26 • If a shift is of any amount, then the general Caesar algorithm is C = E (K, P) = (P + K) mod 26 (Modified Caesar Cipher) • Where, K is any value from 1 to 25. The decryption algorithm is as follow P = D (K, C) = (C - K) mod 26
  • 21. Limitation of Caesar’s Cipher • If an adversary knows that that a given cipher text is a Caesar cipher, then it is easy to discover plain text by performing a brute-force cryptanalysis • Simply adversary has to try all the 25 possible keys only.
  • 22. Limitation of Caesar’s Cipher • The encryption and decryption algorithms are known. • There are only 25 keys to try. • The language of the plaintext is known and easily recognizable.
  • 23. Transposition Techniques • Transposition means rearranging the order of arrival of the elements of the plaintext. • Transposition is also referred to as permutation. • In this technique cipher text is generated by changing the position of the letters or elements of the plaintext. • For example Rail Fence Columnar Techniques
  • 24. Simple Columnar Transposition • A columnar transposition, also known as a row-column transpose. • It is a very simple cipher technique. • In this technique, the message is written out in rows of a fixed length. • The message is then read out by column by column, where the columns are chosen in some scrambled order. • The number of columns and the order in which they are chosen is defined by a keyword.
  • 25. Simple Columnar Transposition • For example, the word CIPHER is 6 letters long. • Therefore, there are 6 columns that will be read of in the following order: 1 4 5 3 2 6. • The order is chosen by the alphabetical order of the letters in the keyword.
  • 26. Single Columnar Cipher (Regular Case) • In a single columnar transposition cipher (regular case) the empty spaces are filled with random letters. • For Example Plaintext: Hello how are you. Meet me tomorrow. Key: CIPHER • The six columns are now written out in the order as defined by the keyword: • HOOMOEEMWLREOOEWUERLAMTRHYTMX C I P H E R 1 4 5 3 2 6 H E L L O H O W A R E Y O U M E E T M E T O M M O R R O W X
  • 27. Double Columnar Transposition • To make the message even more difficult to discover, the cipher text produced by this algorithm and run it through the encryption again using a different keyword. • This transposes the columns twice and makes the message extremely difficult to decipher.
  • 28. Double Columnar Transposition • After first encryption again same process for next encryption. • The six columns are now written out in the order as defined by the keyword: • HWMOWOLREMMRLETOUTOHOEROYEAEMX C I P H E R 1 4 5 3 2 6 H O O M O E W U E R L A M T R L R E O O O E E M W H Y T M X
  • 29. Steganography • Steganography is a process that involves hiding a message in an appropriate carrier like image or audio or video. • It is of Greek origin and means "covered or hidden writing". • The carrier can be sent to a receiver without anyone except the authenticated receiver knowing the existence of this information. • Steganography differs from Cryptography in the sense that where cryptography focuses on keeping the contents of a message secret, steganography focuses on keeping the existence of a message secret.
  • 30. Steganography Figure: Generic Image Steganography System
  • 31. Steganography Process • Cover-media + Hidden data + Stego-key = Stego-medium
  • 32. Steganography Process • Cover media is the file in which the data is hidden and which also can be encrypted by using stego-key. • The resulting file is stego-medium. • Cover-media can be image or audio or video file. • Steganography precedes cryptography one step further by hiding an encrypted message so that no one suspects its existence.
  • 33. Steganography Process • Ideally, anyone scanning your data will fail to know it contains encrypted data. • Stenography has a number of disadvantages when compared to encryption. • It requires a lot of overhead to hide a relatively few bits of information.
  • 34. Terminologies used in Steganography • Cover media: It is the media in which we hide the secret message. • Message (pay load): It also called as hidden data. It is message which will be hidden in cover or stego media. • Stego medium (package, converted message): It is medium in which secret message is hidden. • Redundant bit: A bit in cover medium that can be modified without compromising that mediums integrity. • Stego key : A key used to encode and decode the data • Stego function: The function for encoding and reverse function for decoding
  • 35. Advantages of steganography • It can be employed by parties who have something to lose should the fact of their secret communication be discovered. • Steganography can protect both the message & communication parties. • With the help of steganography we can hide secret message within graphics images.
  • 36. Disadvantages of steganography • Requires lots of overhead to hide few bits of information. • Once the system is discovered it becomes virtually worthless. • Hiding capacity is less • Quality of the resultant stego image is a major issue
  • 37. Symmetric Key Cryptography • Symmetric Key Cryptography also known as Symmetric Encryption. • Symmetric key cryptography is any cryptographic algorithm that is based on a shared key that is used to encryption or decryption. • Symmetric encryption is a type of encryption where only one key is used for encryption as well as decryption.
  • 38. Symmetric Key Cryptography Figure: Symmetric Key Cryptography
  • 39. DES (Data Encryption Standard) Algorithm • The Data Encryption Standard (DES) is one of the most widely used encryption algorithm. • It demonstrates the classic Feistel structure. • DES uses a 64-bit block and a 56-bit key. • DES, data are encrypted in 64-bit blocks using a 56-bit key. • The algorithm converts 64-bit input in a series of steps into a 64-bit output. • The same steps, using the same key, are used to reverse the encryption.
  • 40. Overall structure of DES encryption
  • 41. DES Encryption • Like any encryption technique, it has two inputs to the encryption function, the plaintext to be encrypted and the key. • In this case, the plaintext must be 64 bits in length and the key is 56 bits in length.
  • 42. DES Encryption • From left side of figure, the processing of the plaintext is done in three phases. • First, the 64-bit plaintext passes through an initial permutation (IP) that rearranges the bits to produce the permuted input. • This is followed by a phase consisting of sixteen rounds of the same function, which involves both permutation and substitution functions.
  • 43. DES Encryption • The output of the last (sixteenth) round consists of 64 bits that are a function of the input plaintext and the key. • The left and right half parts of the output are swapped to produce the pre output. • Finally, the pre output is passed through a permutation [IP-1] which is the inverse of the initial permutation function that produces the final 64-bit cipher text. • The right side of Figure shows the how the 56-bit key is used.
  • 44. DES Encryption Overall the structure of DES consists of: • Initial Permutation (IP) • Sixteen Rounds (Each round contains) Expansion Permutation S-box Substitution XOR-ing • Inverse Initial Permutation (IP-1) • Key Generation
  • 45. Initial Permutation (IP) • The initial permutation (IP) and its inverse (IP-1) are described by tables. • The input to a table contains of 64 bits numbered from 1 to 64. • The 64 entries in the permutation table contain a permutation of the numbers from 1 to 64. • Each value in the permutation table shows the position of a numbered input bit in the output, which is also of 64 bits.
  • 48. Single Round structure of DES Algorithm
  • 49. Details of single round • Figure shows the internal structure of a single round. • This structure is same for all rounds. • From the left-hand side of the diagram, it can be seen that, each input 64-bit value is treated as separate 32-bit quantities by dividing them into two halves (the left and right halves), labelled as L (left) and R (right). • The overall processing of each round is summarized in the following formulas: 𝑳𝒊 = 𝑹𝒊 − 𝟏 𝑹𝒊 = 𝑳𝒊 − 𝟏 {𝑭 (𝑹𝒊 − 𝟏, 𝑲𝒊)
  • 50. Details of single round • The round key Ki is of 48 bits. • The R input is 32 bits and is first expanded to 48 bits by using expansion permutation. • The resulting 48 bits are XOR ed with Ki. • This 48-bit result passes through S-Box substitution function which produces a 32-bit output.
  • 51. Details of single round • Each single round consists of: Expansion Permutation XOR S-Box Substitution
  • 52. Expansion Permutation • Expansion permutation function expand 32 bits to 48 bits. • R input, half of the block undergoes an expansion permutation. • In this process, the expansion and transposition are achieved at the same time by allowing the 1st and 4th bits in each 4-bit block to appear twice in the output, i.e., the 4th input bit becomes the 5th and 7th output bits as shown in table.
  • 53. Expansion Permutation Table: Expansion Permutation As shown in table 1st and 4th bit of every four bits appear twice in the output by padding 1st bit to last and last bit to 1st position.
  • 54. XOR • The resulting 48-bit block is then XOR-ed with the appropriate subset key for that round.
  • 55. S-Box Substitution • The next operation is to perform substitutions on the expanded block. • There are eight substitution boxes, called S-boxes. • The first S-box operates on the first 6 bits of the 48-bit expanded block, the 2nd S-box on the next six, and so on. • Each S-box operates from a table of 4 rows and 16 columns. • Each entry in the table is a 4-bit number.
  • 56. S-Box Substitution • The 6-bit number is taken as input to S-Box and is used to look up the appropriate entry in the table in the following way. • The 1st and 6th bits are combined together to form a 2-bit number which refers to a particular row number, and the 2nd to 5th bits are combined to form a 4-bit number which refers to a particular column. • The net result of the S-Box Substitution function is eight 4-bit blocks which are then combined into a 32-bit block.
  • 58.
  • 59.
  • 60.
  • 61.
  • 62. S-Box Substitution For Example: • Suppose for table S0 6-bit input is 110010, • Then 1st bit and last bit is combined which is 10 here • Then row no 2 of table S0 is selected • And the bits remaining i.e., 1001 selects column no 9 of table S0. • The entry at this intersection is 12 which is 4-bit value in binary.
  • 63. Key Generation • A 64-bit key is used as input to the algorithm. The figure on next slide shows how to obtain round key from a 64-bit key • For every round a 48-bit key is generated known as round key.
  • 64. Key Generation Algorithm Figure: Key Generation Algorithm
  • 65. Key Generation • The bits of the key are numbered from 1 through 64. • Every eighth bit is ignored, as shown in Table PC1. • The key is first subjected to a permutation governed by a table labelled Permuted Choice One – PC1. • The resulting 56-bit key is then treated as two 28-bit quantities
  • 66. Key Generation • These are separately subjected to a circular left shift or (rotation) of 1 or 2 bits, as governed by Table. • These shifted values provided as input to the next round. • They also serve as input to the part labelled Permuted Choice Two – PC2 (Table PC2), • Which produces a 48-bit output that serves as input to the function F (Ri-1, Ki).
  • 67. Key Generation (Table Input Key) 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64
  • 70. Asymmetric Key Cryptography • Asymmetric key cryptography was originally conceived to address some of the problems in symmetric encryption. • It addresses the problems of key distribution, generation and nonrepudiation. • It is also called as public key cryptography. • The key pair generated in asymmetric key cryptography systems is commonly known as public and private keys. • Public Key: Freely available to anyone in the group or legitimate user. • Private Key: Kept secret, only user who is holding knows it.
  • 71. Asymmetric Key Cryptography • Any message that is encrypted by using public key can only be decrypted by applying the same algorithm, by using the matching private key. • Any message encrypted by using the private key can only be decrypted by using the matching public key.
  • 72. Asymmetric Key Cryptography Figure: Asymmetric Key Cryptography
  • 73. Digital Signature • A digital signature is an authentication mechanism that enables the creator of a message to attach a code that acts as a signature. allow us to verify the author, date and time of signatures, authenticate the message contents. • It also includes authentication function for additional capabilities. • Typically, the signature is formed by taking the hash of the message and encrypting the message with the creator’s private key. • The signature guarantees the source and integrity of the message.
  • 74. Digital Signature • A digital signature or digital signature scheme is a mathematical scheme for demonstrating the authenticity of a digital message or document. • A valid digital signature gives a recipient reason to believe that the message was created by a known sender, and that it was not altered in transit. • Digital signatures are commonly used for software distribution, financial transactions, and in other cases where it is important to detect forgery or tampering.
  • 75. Digital Signature A digital signature scheme typically consists of three algorithms • A key generation algorithm that selects a private key uniformly at random from a set of possible private keys. The algorithm outputs the private key and a corresponding public key. • A signing algorithm that, given a message and a private key, produces a signature. • A signature verifying algorithm that, given a message, public key and a signature, either accepts or rejects the message's claim to authenticity.
  • 77. Digital Signature (Working) • A digital signature performs the same function as its physical counterpart, the sender “marks” the message so that the recipients can verify that the message really came from the sender. • The process of digitally signing a message starts with the creation of a unique identify for the message. The unique identifier can be created using a mathematical technique called Hashing.
  • 78. Digital Signature (Working) • A hash function uses a mathematical algorithm to convert the message into a short fixed-length of bits, often referred to as a “hash value” or “message digest” that uniquely represents the message used to create it. • The hash value is specific to the contents of the message. Thus, any change to the message contents will change the hash value that would be generated by the hash function.
  • 79. Digital Signature (Working) • Next, the hash value is encrypted using the sender’s private key. Finally, the message is sent along with the encrypted hash value. • On receiving the message and the encrypted hash value, the recipient can only decrypt the hash value using the sender’s public key. • This confirms that the message came from the sender and no one else, as long as the sender’s private key remains secure. • The message can be rehashed and compared with the decrypted hash value-if the values do not match, then the message has been altered since it was same