SlideShare a Scribd company logo
Cryptography
Basic Concepts:- 
• Cryptography - the art or science encompassing 
the principles and methods of transforming an 
intelligible message into one that is 
unintelligible, and then retransforming that 
message back to its original form. 
• Plaintext - the original intelligible message. 
• Cipher Text - the transformed message.
• Cipher - an algorithm for transforming an 
intelligible message into one that is 
unintelligible by transposition and/or 
substitution methods 
• Key - some critical information used by the 
cipher, known only to the sender and receiver 
• Encipher (encode) - the process of converting 
plaintext to cipher text using a cipher and a key
• Decipher (decode) - the process of 
converting cipher text back into plaintext 
using a cipher and a key. 
• Cryptanalysis - the study of principles and 
methods of transforming an unintelligible 
message back into an intelligible message 
without knowledge of the key. Also called 
codebreaking.
Working :-
Example:-
Applications:- 
• ATM cards, 
• Computer passwords, 
• Electronic commerce, etc.
Categories:-
Symmetric-Key 
• In symmetric-key cryptography, the 
same key is used by both parties. The 
sender uses this key and an encryption 
algorithm to encrypt data; the receiver 
uses the same key and the 
corresponding decryption algorithm to 
decrypt the data.
Cryptography
Asymmetric-Key 
• In asymmetric or public-key cryptography, there 
are two keys: a private key and a public key. 
The private key is kept by the receiver. The 
public key is announced to the public. The 
public key that is used for encryption is 
different from the private key that is used for 
decryption. The public key is available to the 
public; the private key is available only to an 
individual.
Cryptography
Symmetric-Key Ciphers:- 
• Traditional Ciphers: These are character 
oriented ciphers.
Substitution Cipher:- 
• A substitution cipher substitutes one symbol 
with another. If the symbols in the plaintext 
are alphabetic characters, we replace one 
character with another. For example, we can 
replace character A with D, and character T 
with Z. If the symbols are digits (0 to9), we can 
replace 3 with 7, and 2 with 6. Substitution 
ciphers can be categorized as either 
monoalphabetic or polyalphabetic ciphers.
Monoalphabetic Cipher:- 
• In a monoalphabetic cipher, a character (or a 
symbol) in the plaintext is always changed to 
the same character (or symbol) in the ciphertext 
regardless of its position in the text. For 
example, if the algorithm says that character A 
in the plaintext is changed to character D, every 
character A is changed to character D. In other 
words, the relationship between characters in 
the plaintext and the ciphertext is a one-to-one 
relationship.
Polyalphabetic Cipher:- 
• In a polyalphabetic cipher, each occurrence 
of a character can have a different 
substitute. The relationship between a 
character in the plaintext to a character in 
the ciphertext is a one-to-many 
relationship. For example, character A 
could be changed to D in the beginning of 
the text, but it could be changed to N at 
the middle.
Example:- 
• The following shows a plaintext and its 
corresponding ciphertext. Is the cipher 
monoalphabetic? 
Plaintext: HELLO 
Ciphertext: KHOOR 
• The cipher is probably monoalphabetic 
because both occurrences of L's are 
encrypted as O's
• The following shows a plaintext and its 
corresponding ciphertext. Is the cipher 
monoalphabetic? 
Plaintext: HELLO 
Ciphertext: ABNZF 
• The cipher is not monoalphabetic because each 
occurrence of L is encrypted by a different 
character. The first L is encrypted as N; the 
second as Z.
Shift Cipher:- 
• The simplest monoalphabetic cipher is probably the 
shift cipher. In this cipher, the encryption 
algorithm is "shift key characters down," with key 
equal to some number. The decryption algorithm is 
"shift key characters up." For example, if the key is 
5, the encryption algorithm is "shift 5 characters 
down" (toward the end of the alphabet). The 
decryption algorithm is "shift 5 characters up" 
(toward the beginning of the alphabet). Of course, 
if we reach the end or beginning of the alphabet, 
we wrap around.
Example:- 
• Use the shift cipher with key = 15 to 
encrypt the message HELLO. 
• We encrypt one character at a time. Each 
character is shifted 15 characters down. 
Letter H is encrypted to W. Letter E is 
encrypted to T. The first L is encrypted to 
A. The second L is also encrypted to A. 
And 0 is encrypted to D. The cipher text is 
WTAAD.
• Use the shift cipher with key =15 to 
decrypt the message "WTAAD.“ 
• We decrypt one character at a time. Each 
character is shifted 15 characters up. 
Letter W is decrypted to H. Letter T is 
decrypted to E. The first A is decrypted to 
L. The second A is decrypted to L. And, 
finally, D is decrypted to O. The plaintext 
is HELLO
Transcomposition Cipher:- 
• In a transposition cipher, there is no 
substitution of characters; instead, their 
locations change. A character in the first 
position of the plaintext may appear in the 
tenth position of the ciphertext. A character in 
the eighth position may appear in the first 
position. In other words, a transposition cipher 
reorders the symbols in a block of symbols.
• Key in a transposition cipher is a mapping between 
the position of the symbols in the plaintext and cipher 
text. For example, the following shows the key using 
a block of four characters: 
Plaintext: 2 4 31 
Ciphertext: 1 2 3 4 
• In encryption, we move the character at position 2 to 
position 1, the character at position 4 to position 2, 
and so on. In decryption, we do the reverse
Example:- 
• Encrypt the message “DEAR" using the 
key: 
Plaintext: 2 4 31 
Ciphertext: 1 2 3 4 
• Solution: RDAE
Simple Modern Ciphers:- 
• The traditional ciphers we have studied so far 
are character-oriented. With the advent of the 
computer, ciphers need to be bit-oriented. This is 
so because the information to be encrypted is 
not just text; it can also consist of numbers, 
graphics, audio, and video data. It is 
convenient to convert these types of data into a 
stream of bits, encrypt the stream, and then 
send the encrypted stream.
XOR Cipher:- 
• An XOR operation needs two data inputs 
plaintext, as the first and a key as the second. 
In other words, one of the inputs is the block to 
be the encrypted, the other input is a key; the 
result is the encrypted block. Note that in an 
XOR cipher, the size of the key, the plaintext, 
and the ciphertext are all the same. XOR ciphers 
have a very interesting property: the encryption 
and decryption are the same.
Cryptography
Rotation Cipher:- 
• Another common cipher is the rotation cipher, in 
which the input bits are rotated to the left or right. 
The rotation cipher can be keyed or keyless. In keyed 
rotation, the value of the key defines the number of 
rotations; in keyless rotation the number of rotations 
is fixed.
Other Types:- 
• Modern Round Ciphers 
• Data Encryption Standard (DES) 
• Advanced Encryption Standard (AES) 
• Electronic Code Book 
• RSA (Rivest, Shamir and Adleman) 
• Diffie-Hellman
Cryptography

More Related Content

PPTX
Number theory and cryptography
PPTX
cryptography
PPT
Cryptography Fundamentals
PPTX
Diffie hellman key exchange algorithm
PDF
2. Stream Ciphers
PPTX
Cryptography.ppt
PPTX
Booth's algorithm part 1
Number theory and cryptography
cryptography
Cryptography Fundamentals
Diffie hellman key exchange algorithm
2. Stream Ciphers
Cryptography.ppt
Booth's algorithm part 1

What's hot (20)

PDF
Elliptic Curve Cryptography Message Exchange
DOCX
What is AES? Advanced Encryption Standards
PDF
JK flip flops
PPTX
Elliptic Curve Cryptography
PPTX
Elliptic Curve Cryptography
PPTX
Cryptography - Block cipher & stream cipher
PPTX
Introduction to Cryptography
PPT
1524 elliptic curve cryptography
PPTX
Cryptography.ppt
PPT
Diffiehellman
PPTX
Booth’s algorithm.(a014& a015)
DOCX
Number Theory In Cryptography
PPTX
instruction cycle ppt
PPTX
Classical encryption techniques
PPT
Secret sharing schemes
PPT
Cryptography
PDF
Zero Knowledge Proofs: What they are and how they work
PDF
CNS - Unit - 2 - Stream Ciphers and Block Ciphers
PPTX
Instruction set of 8085 microprocessor
PPTX
RSA Algorithm
Elliptic Curve Cryptography Message Exchange
What is AES? Advanced Encryption Standards
JK flip flops
Elliptic Curve Cryptography
Elliptic Curve Cryptography
Cryptography - Block cipher & stream cipher
Introduction to Cryptography
1524 elliptic curve cryptography
Cryptography.ppt
Diffiehellman
Booth’s algorithm.(a014& a015)
Number Theory In Cryptography
instruction cycle ppt
Classical encryption techniques
Secret sharing schemes
Cryptography
Zero Knowledge Proofs: What they are and how they work
CNS - Unit - 2 - Stream Ciphers and Block Ciphers
Instruction set of 8085 microprocessor
RSA Algorithm
Ad

Similar to Cryptography (20)

PPTX
IANSunit 1_cryptography_2.pptxv xvxvxvxv
PPTX
Cryptography cryptography CryptographyCryptography
PPTX
cryptographyyy .pptx
PPTX
Cryptography
PDF
basic encryption and decryption
PPTX
cryptographyandnetworksecu-module-1.pptx
PPTX
Symmetric and asymmetric key cryptography
PPTX
Classical cyphers python programming
PPTX
Cryptography .pptx
PPTX
Secret writing in forensic science .pptx
PPTX
Information system security Unit 2.pptx
PPTX
security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.
PPTX
Cryptography
PPT
Computer systems security 7-cryptography.ppt
PPTX
Cryptography
PPT
encryptcryptographyyyyyyyyyyyyyyyyyy.ppt
PDF
Caesar Cipher , Substitution Cipher, PlayFair and Vigenere Cipher
PPTX
Unit – III.pptx
PPT
cryptography.ppt
PPT
9-crypthvvy6u7btyjibuibuibryjijighhnm.ppt
IANSunit 1_cryptography_2.pptxv xvxvxvxv
Cryptography cryptography CryptographyCryptography
cryptographyyy .pptx
Cryptography
basic encryption and decryption
cryptographyandnetworksecu-module-1.pptx
Symmetric and asymmetric key cryptography
Classical cyphers python programming
Cryptography .pptx
Secret writing in forensic science .pptx
Information system security Unit 2.pptx
security Symmetric Key Cryptography Substitution Cipher, Transposition Cipher.
Cryptography
Computer systems security 7-cryptography.ppt
Cryptography
encryptcryptographyyyyyyyyyyyyyyyyyy.ppt
Caesar Cipher , Substitution Cipher, PlayFair and Vigenere Cipher
Unit – III.pptx
cryptography.ppt
9-crypthvvy6u7btyjibuibuibryjijighhnm.ppt
Ad

Cryptography

  • 2. Basic Concepts:- • Cryptography - the art or science encompassing the principles and methods of transforming an intelligible message into one that is unintelligible, and then retransforming that message back to its original form. • Plaintext - the original intelligible message. • Cipher Text - the transformed message.
  • 3. • Cipher - an algorithm for transforming an intelligible message into one that is unintelligible by transposition and/or substitution methods • Key - some critical information used by the cipher, known only to the sender and receiver • Encipher (encode) - the process of converting plaintext to cipher text using a cipher and a key
  • 4. • Decipher (decode) - the process of converting cipher text back into plaintext using a cipher and a key. • Cryptanalysis - the study of principles and methods of transforming an unintelligible message back into an intelligible message without knowledge of the key. Also called codebreaking.
  • 7. Applications:- • ATM cards, • Computer passwords, • Electronic commerce, etc.
  • 9. Symmetric-Key • In symmetric-key cryptography, the same key is used by both parties. The sender uses this key and an encryption algorithm to encrypt data; the receiver uses the same key and the corresponding decryption algorithm to decrypt the data.
  • 11. Asymmetric-Key • In asymmetric or public-key cryptography, there are two keys: a private key and a public key. The private key is kept by the receiver. The public key is announced to the public. The public key that is used for encryption is different from the private key that is used for decryption. The public key is available to the public; the private key is available only to an individual.
  • 13. Symmetric-Key Ciphers:- • Traditional Ciphers: These are character oriented ciphers.
  • 14. Substitution Cipher:- • A substitution cipher substitutes one symbol with another. If the symbols in the plaintext are alphabetic characters, we replace one character with another. For example, we can replace character A with D, and character T with Z. If the symbols are digits (0 to9), we can replace 3 with 7, and 2 with 6. Substitution ciphers can be categorized as either monoalphabetic or polyalphabetic ciphers.
  • 15. Monoalphabetic Cipher:- • In a monoalphabetic cipher, a character (or a symbol) in the plaintext is always changed to the same character (or symbol) in the ciphertext regardless of its position in the text. For example, if the algorithm says that character A in the plaintext is changed to character D, every character A is changed to character D. In other words, the relationship between characters in the plaintext and the ciphertext is a one-to-one relationship.
  • 16. Polyalphabetic Cipher:- • In a polyalphabetic cipher, each occurrence of a character can have a different substitute. The relationship between a character in the plaintext to a character in the ciphertext is a one-to-many relationship. For example, character A could be changed to D in the beginning of the text, but it could be changed to N at the middle.
  • 17. Example:- • The following shows a plaintext and its corresponding ciphertext. Is the cipher monoalphabetic? Plaintext: HELLO Ciphertext: KHOOR • The cipher is probably monoalphabetic because both occurrences of L's are encrypted as O's
  • 18. • The following shows a plaintext and its corresponding ciphertext. Is the cipher monoalphabetic? Plaintext: HELLO Ciphertext: ABNZF • The cipher is not monoalphabetic because each occurrence of L is encrypted by a different character. The first L is encrypted as N; the second as Z.
  • 19. Shift Cipher:- • The simplest monoalphabetic cipher is probably the shift cipher. In this cipher, the encryption algorithm is "shift key characters down," with key equal to some number. The decryption algorithm is "shift key characters up." For example, if the key is 5, the encryption algorithm is "shift 5 characters down" (toward the end of the alphabet). The decryption algorithm is "shift 5 characters up" (toward the beginning of the alphabet). Of course, if we reach the end or beginning of the alphabet, we wrap around.
  • 20. Example:- • Use the shift cipher with key = 15 to encrypt the message HELLO. • We encrypt one character at a time. Each character is shifted 15 characters down. Letter H is encrypted to W. Letter E is encrypted to T. The first L is encrypted to A. The second L is also encrypted to A. And 0 is encrypted to D. The cipher text is WTAAD.
  • 21. • Use the shift cipher with key =15 to decrypt the message "WTAAD.“ • We decrypt one character at a time. Each character is shifted 15 characters up. Letter W is decrypted to H. Letter T is decrypted to E. The first A is decrypted to L. The second A is decrypted to L. And, finally, D is decrypted to O. The plaintext is HELLO
  • 22. Transcomposition Cipher:- • In a transposition cipher, there is no substitution of characters; instead, their locations change. A character in the first position of the plaintext may appear in the tenth position of the ciphertext. A character in the eighth position may appear in the first position. In other words, a transposition cipher reorders the symbols in a block of symbols.
  • 23. • Key in a transposition cipher is a mapping between the position of the symbols in the plaintext and cipher text. For example, the following shows the key using a block of four characters: Plaintext: 2 4 31 Ciphertext: 1 2 3 4 • In encryption, we move the character at position 2 to position 1, the character at position 4 to position 2, and so on. In decryption, we do the reverse
  • 24. Example:- • Encrypt the message “DEAR" using the key: Plaintext: 2 4 31 Ciphertext: 1 2 3 4 • Solution: RDAE
  • 25. Simple Modern Ciphers:- • The traditional ciphers we have studied so far are character-oriented. With the advent of the computer, ciphers need to be bit-oriented. This is so because the information to be encrypted is not just text; it can also consist of numbers, graphics, audio, and video data. It is convenient to convert these types of data into a stream of bits, encrypt the stream, and then send the encrypted stream.
  • 26. XOR Cipher:- • An XOR operation needs two data inputs plaintext, as the first and a key as the second. In other words, one of the inputs is the block to be the encrypted, the other input is a key; the result is the encrypted block. Note that in an XOR cipher, the size of the key, the plaintext, and the ciphertext are all the same. XOR ciphers have a very interesting property: the encryption and decryption are the same.
  • 28. Rotation Cipher:- • Another common cipher is the rotation cipher, in which the input bits are rotated to the left or right. The rotation cipher can be keyed or keyless. In keyed rotation, the value of the key defines the number of rotations; in keyless rotation the number of rotations is fixed.
  • 29. Other Types:- • Modern Round Ciphers • Data Encryption Standard (DES) • Advanced Encryption Standard (AES) • Electronic Code Book • RSA (Rivest, Shamir and Adleman) • Diffie-Hellman