SlideShare a Scribd company logo
1 of 24
NORTH WESTERN UNIVERSITY
Computer Science & Engineering
Course Titel: Computer Networks
Course Code: CSE-3205
Presentation on: Symmetric and Asymmetric
key cryptography. Submitted by:
Name : MD. MONIRUL ISLAM
ID: 20151116010
Submitted to:
Name : Romana Rahman
Senior Lecturer
Computer Science & Engineering
North Western University , Khulna
INDEX:
* General Introduction of Cryptography.
* Objectives
* Types of Cryptography.
* Symmetric Cryptosystems.
* Limitations of Symmetric Cryptography
* Asymmetric Cryptosystems.
* Limitations of Asymmetric Cryptography.
* References.
General Introduction of Cryptography
Cryptography is a method of protecting information and communications through the use of
codes, so that only those for whom the information is intended can read and process it.
It has two main Components:
1. Encryption
– Practice of hiding messages so that they can not be read by anyone other than
the intended recipient
2. Authentication
– Ensuring that users of data/resources are the persons they claim to be and that
a message has not been surreptitiously altered
How does it work?
 Two functions are needed:
Fig 01: Encoder & Decoder
Example
 encoder function is next letter in the alphabet.
 decoder function is …
Fig 02: Encoder & Decoder
Encryption and Decryption
- Plain text
- Cipher text
 Encoding :- The contents of the message (the plain text) in such a way that hides
its contents from outsiders is called encryption.
 The process of retrieving the plaintext from the cipher-text is called
decryption.
 Encryption and decryption usually make use of a key, and the coding method is
such that decryption. Can be performed only by knowing the proper key.
Objectives
Cryptography has four main objectives:
 Confidentiality of the message: Only the authorized recipient should be able to extract the
content of the cypher. In addition, obtaining information about the content of the message
(such as a statistical distribution of certain characters) should not be possible, once the
cryptographic analysis becomes easier.
 Message integrity: The recipient must be able to determine if the message was altered
during transmission.
 Authentication of the sender: The recipient should be able to identify the sender and verify
if it was him who sent the message.
 Irrevocability of the sender: It should not be possible to deny the authorship of the
message.
Types of Cryptography
Two kinds of Cryptography:
Symmetric
1) Alice and Bob agree on a
cryptosystem
2) Alice and Bob agree on a key.
3) Alice takes her plaintext
message and encrypts it using
the encryption algorithm and the
key. This creates a cipher text
message.
4) Alice sends the cipher text
message to Bob.
5) Bob decrypts the cipher text
message with the same algorithm
and key and reads it.
Asymmetric
1) Alice and Bob agree on a
public-key cryptosystem.
2) Bob sends Alice his public
key.
3) Alice encrypts her message
using Bob’s public key and
sends it to Bob.
4) Bob decrypts Alice’s message
using his private key.
Symmetric Cryptosystem
Both the sender and receiver share a single key. The sender uses this key to encrypt plaintext and send
the cipher text to the receiver. On the other side the receiver applies the same key to decrypt the
message and recover the plain text.
Material to
keep secret:
Text
Data
Audio
Video
Graphics
Material to
keep secret:
Text
Data
Audio
Video
Graphics
Lock
Encryption
Algorithm
Decryption
Algorithm
Shared Key
Sender and recipient Must both know
the key.
This is a weakness!
Fig 03: Symmetric Cryptosystem
Traditional ciphers
Traditional cipher are two types
 Simple substitution Cipher.
 Transposition Cipher.
Fig 04: Traditional Ciphers
Simple Substitution Ciphers
It is an improvement to the Caesar Cipher. Instead of shifting the alphabets by some number, this
scheme uses some permutation of the letters in alphabet.
For example, A.B…..Y.Z and Z.Y……B.A are two obvious permutation of all the letters in
alphabet. Permutation is nothing but a jumbled up set of alphabets.
With 26 letters in alphabet, the possible permutations are 26! (Factorial of 26) which is equal to
4x1026. The sender and the receiver may choose any one of these possible permutation as a cipher
text alphabet. This permutation is the secret key of the scheme.
Process of Simple Substitution Cipher
1.Write the alphabets A, B, C,...,Z in the natural order.
2. The sender and the receiver decide on a randomly selected permutation of the letters of the alphabet.
3. Underneath the natural order alphabets, write out the chosen permutation of the letters of the alphabet. For
encryption, sender replaces each plaintext letters by substituting the permutation letter that is directly beneath it in
the table. This process is shown in the following illustration. In this example, the chosen permutation is K,D, G, ...,
O. The plaintext ‘point’ is encrypted to ‘MJBXZ’.
Here is a jumbled Cipher text alphabet, where the order of the cipher text letters is a key.
On receiving the cipher text, the receiver, who also knows the randomly chosen permutation, replaces each cipher
text letter on the bottom row with the corresponding plaintext letter in the top row. The cipher text ‘MJBXZ’ is
decrypted to ‘point’.
Mono alphabetic Cipher
Mono alphabetic cipher is a substitution cipher in which for a given key, the cipher alphabet for
each plain alphabet is fixed throughout the encryption process.
A simple example is where each letter is encrypted as the next letter in the alphabet: "a simple
message" becomes "B TJNQMF NFTTBHF". In general, when performing a simple
substitution manually, it is easiest to generate the cipher text alphabet first, and encrypt by
comparing this to the plaintext alphabet. The table below shows how one might choose to, and
we will, lay them out for this example.
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 cipher text is a one-to-many relationship.
As an example we shall encrypt the plaintext "Leon Battista albert". To keep with the convention of writing cipher text in
uppercase, we shall invert Alberta's own rule, and use lowercase letters to signify the change.
We start by referencing the starting position of the cipher disc, which in this case is "a" is encrypted as "V", so we start the
Cipher text with a lowercase "v". We then encrypt the first few letters as a Caesar Shift, using the cipher text alphabet
given below.
The 1st shift used, as the disk in shown
Plaintext: leonbat...
Cipher text: vGZJIWVOg...
The uppercase letters above encrypt the plaintext letters given. The "v" indicates the starting position of the disc, and
the "g" indicates that we need to change the position so that "G" is beneath "a". We then get the new cipher text
Alphabet as shown below.
Plaintext: ...tistaa...
Cipher text: ...gZOYZGGm...
This time the plaintext letters are encrypted to the cipher text letters using the cipher text alphabet above, and the "m“
indicates that we are changing alphabet again to get the final cipher text alphabet below.
Plaintext: ...lberti
Cipher text: ...mXNQDFU
So we get the final cipher text "vGZJIWVOgZOYZGGmXNQDFU".
Transposition Cipher
Transposition Ciphers are a bit different to Substitution Ciphers. Whereas Substitution ciphers replace each
letter with a different letter or symbol to produce the cipher text, in a Transposition cipher, the letters are just
moved around.
The letters or words of the plaintext are reordered in some way, fixed by a given rule (the key).
One example of a transposition cipher, is to reverse the order of the letters in a plaintext. So "a simple
example" becomes "ELPMAXE ELPMIS A". Another, similar, way to encrypt a message would be to reverse
the letters of each word, but not the order in which the words are written. In this case "a simple example“
becomes "A ELPMIS ELPMAXE". Both of these are available in the activity at the bottom of the page.
Limitations of Symmetric Cryptography
 Many people need to communicate with a server (many-to-one communications).
 cannot keep server key secret for long.
 Once the secret key is compromised, the security of all subsequent.
messages is suspect and a new key has to be generated.
 Authentication service must know private key.
 privacy implications---someone else knows your key.
 two possible points of attack.
 changing authentication service requires a new key.
 Digital signatures are difficult.
 Crossrealm authentication.
 accessing services outside the domain or realm of your authentication server is problematic.
 requires agreement and trust between authentication services.
 introduces another potential point of attack.
Asymmetric Cryptosystems
In asymmetric-key cryptography, users do not need to know a symmetric shared key; everyone
• shields a private key and
• advertises a public key
Material to
keep secret:
Text
Data
Audio
Video
Graphics
Material to
keep secret:
Text
Data
Audio
Video
Graphics
Lock
Encryption
Algorithm
Decryption
Algorithm
Decryption keyEncryption Key
Sender knows public key
Recipient knows private key.
Fig 05: Asymmetric Cryptosystem
RSA Cryptography
RSA algorithm is a public key encryption technique and is considered as the most secure way of encryption.
It was invented by Rivest, Shamir and Adleman in year 1978 and hence name RSA algorithm.
Process of RSA
 Choose two large prime numbers p & q
 Compute n= p q and z=(p-1)(q-1)
 Choose number e, less than n, which has no common factor (other than 1) with z
 Find number d, such that e d – 1 is exactly divisible by z Keys are generated using n, d, e
-Public key is (n, e)
-Private key is (n, d)
 Encryption: c = me mod n
-m is plain text
-c is cipher text
 Decryption: m = cd mod n
 Public key is shared and the private key is hidden
P=5 & q=7
n=5*7=35 and z=(4)*(6) = 24
e = 5
d = 29 , (29x5 –1) is exactly divisible by 24
Keys generated are
-Public key: (35,5)
-Private key is (35, 29)
Encrypt the word love using (c = me mod n)
-Assume that the alphabets are between 1 & 26
 Decrypt the word love using (m = cd mod n)
-n = 35, c=29
Limitations of Asymmetric Cryptography
 It is a slow process.
 Its public keys are not authenticated.
 It risks loss of private key, which may be irreparable.
 It risks widespread security compromise.
References
[1] Thomas H. Cormen, Charles E. Leiserson, Ronald L. Rivest, and Clifford Stein. Introduction to Algorithms. MIT Press
and McGraw-Hill, 2001. ISBN 0-262-03293-7. Section 31.7: The RSA public-key cryptosystem, pp.881–887
[2] Bruce Schneier. Applied Cryptography. John Wiley & Sons, Inc. 1996. (ISBN: 0471128457)
[3] Bob Thibadeau http://dollar.ecom.cmu.edu/sec/lec02.ppt.
[4] [2]Data Communications and Networking By Behrouz A.Forouzan.
THANK YOU

More Related Content

What's hot

Network security cryptographic hash function
Network security  cryptographic hash functionNetwork security  cryptographic hash function
Network security cryptographic hash functionMijanur Rahman Milon
 
Cryptography and network security
Cryptography and network securityCryptography and network security
Cryptography and network securitypatisa
 
Public Key Cryptography
Public Key CryptographyPublic Key Cryptography
Public Key CryptographyGopal Sakarkar
 
Introduction to Cryptography
Introduction to CryptographyIntroduction to Cryptography
Introduction to CryptographySeema Goel
 
Cryptography and Information Security
Cryptography and Information SecurityCryptography and Information Security
Cryptography and Information SecurityDr Naim R Kidwai
 
5. message authentication and hash function
5. message authentication and hash function5. message authentication and hash function
5. message authentication and hash functionChirag Patel
 
Classical encryption techniques
Classical encryption techniquesClassical encryption techniques
Classical encryption techniquesDr.Florence Dayana
 
Cryptography - Block cipher & stream cipher
Cryptography - Block cipher & stream cipherCryptography - Block cipher & stream cipher
Cryptography - Block cipher & stream cipherNiloy Biswas
 
SHA- Secure hashing algorithm
SHA- Secure hashing algorithmSHA- Secure hashing algorithm
SHA- Secure hashing algorithmRuchi Maurya
 
Public Key Cryptosystem
Public Key CryptosystemPublic Key Cryptosystem
Public Key CryptosystemDevakumar Kp
 
Diffie hellman key exchange algorithm
Diffie hellman key exchange algorithmDiffie hellman key exchange algorithm
Diffie hellman key exchange algorithmSunita Kharayat
 
Data Encryption Standard (DES)
Data Encryption Standard (DES)Data Encryption Standard (DES)
Data Encryption Standard (DES)Haris Ahmed
 
Information Security & Cryptography
Information Security & CryptographyInformation Security & Cryptography
Information Security & CryptographyArun ACE
 

What's hot (20)

Network security cryptographic hash function
Network security  cryptographic hash functionNetwork security  cryptographic hash function
Network security cryptographic hash function
 
Cryptography
CryptographyCryptography
Cryptography
 
RSA Algorithm
RSA AlgorithmRSA Algorithm
RSA Algorithm
 
Cryptography and network security
Cryptography and network securityCryptography and network security
Cryptography and network security
 
Public Key Cryptography
Public Key CryptographyPublic Key Cryptography
Public Key Cryptography
 
RSA algorithm
RSA algorithmRSA algorithm
RSA algorithm
 
Hash Function
Hash FunctionHash Function
Hash Function
 
Introduction to Cryptography
Introduction to CryptographyIntroduction to Cryptography
Introduction to Cryptography
 
Asymmetric Cryptography
Asymmetric CryptographyAsymmetric Cryptography
Asymmetric Cryptography
 
Cryptography and Information Security
Cryptography and Information SecurityCryptography and Information Security
Cryptography and Information Security
 
5. message authentication and hash function
5. message authentication and hash function5. message authentication and hash function
5. message authentication and hash function
 
Classical encryption techniques
Classical encryption techniquesClassical encryption techniques
Classical encryption techniques
 
Basic cryptography
Basic cryptographyBasic cryptography
Basic cryptography
 
Cryptography - Block cipher & stream cipher
Cryptography - Block cipher & stream cipherCryptography - Block cipher & stream cipher
Cryptography - Block cipher & stream cipher
 
SHA- Secure hashing algorithm
SHA- Secure hashing algorithmSHA- Secure hashing algorithm
SHA- Secure hashing algorithm
 
Encryption ppt
Encryption pptEncryption ppt
Encryption ppt
 
Public Key Cryptosystem
Public Key CryptosystemPublic Key Cryptosystem
Public Key Cryptosystem
 
Diffie hellman key exchange algorithm
Diffie hellman key exchange algorithmDiffie hellman key exchange algorithm
Diffie hellman key exchange algorithm
 
Data Encryption Standard (DES)
Data Encryption Standard (DES)Data Encryption Standard (DES)
Data Encryption Standard (DES)
 
Information Security & Cryptography
Information Security & CryptographyInformation Security & Cryptography
Information Security & Cryptography
 

Similar to Symmetric and asymmetric key cryptography

Computer Network Unit-5 (Part-1).pdf
Computer Network Unit-5 (Part-1).pdfComputer Network Unit-5 (Part-1).pdf
Computer Network Unit-5 (Part-1).pdfParshantYadav13
 
Secret key cryptography
Secret key cryptographySecret key cryptography
Secret key cryptographyPrabhat Goel
 
Cryptography (Revised Edition)
Cryptography (Revised Edition)Cryptography (Revised Edition)
Cryptography (Revised Edition)Somaditya Basak
 
Caesar Cipher , Substitution Cipher, PlayFair and Vigenere Cipher
Caesar Cipher , Substitution Cipher, PlayFair and Vigenere CipherCaesar Cipher , Substitution Cipher, PlayFair and Vigenere Cipher
Caesar Cipher , Substitution Cipher, PlayFair and Vigenere CipherMona Rajput
 
Cryptography
CryptographyCryptography
Cryptographyfsl khan
 
Introduction to Cryptography and the Public Key Infrastructure
Introduction to Cryptography and the Public Key InfrastructureIntroduction to Cryptography and the Public Key Infrastructure
Introduction to Cryptography and the Public Key InfrastructureMike Gates
 
substitution and transposition techniques_ppt.pptx
substitution and transposition techniques_ppt.pptxsubstitution and transposition techniques_ppt.pptx
substitution and transposition techniques_ppt.pptxGauriBornare1
 
security system by desu star chapter 2 (1).pptx
security system by desu star chapter 2 (1).pptxsecurity system by desu star chapter 2 (1).pptx
security system by desu star chapter 2 (1).pptxdesalewminale
 
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 Journals
 
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
 
Introduction to Cryptography Week4 Part1-ISrevisionSu.docx
Introduction to Cryptography  Week4 Part1-ISrevisionSu.docxIntroduction to Cryptography  Week4 Part1-ISrevisionSu.docx
Introduction to Cryptography Week4 Part1-ISrevisionSu.docxmariuse18nolet
 
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
 
SYMMETRIC CRYPTOGRAPHY
SYMMETRIC CRYPTOGRAPHY SYMMETRIC CRYPTOGRAPHY
SYMMETRIC CRYPTOGRAPHY Santosh Naidu
 
A New Modified Version of Caser Cipher Algorithm
A New Modified Version of Caser Cipher AlgorithmA New Modified Version of Caser Cipher Algorithm
A New Modified Version of Caser Cipher AlgorithmIJERD Editor
 
Classical cyphers python programming
Classical cyphers python programmingClassical cyphers python programming
Classical cyphers python programmingShaishavShah8
 

Similar to Symmetric and asymmetric key cryptography (20)

Computer Network Unit-5 (Part-1).pdf
Computer Network Unit-5 (Part-1).pdfComputer Network Unit-5 (Part-1).pdf
Computer Network Unit-5 (Part-1).pdf
 
Secret key cryptography
Secret key cryptographySecret key cryptography
Secret key cryptography
 
Module 1.pptx
Module 1.pptxModule 1.pptx
Module 1.pptx
 
Cryptography (Revised Edition)
Cryptography (Revised Edition)Cryptography (Revised Edition)
Cryptography (Revised Edition)
 
Caesar Cipher , Substitution Cipher, PlayFair and Vigenere Cipher
Caesar Cipher , Substitution Cipher, PlayFair and Vigenere CipherCaesar Cipher , Substitution Cipher, PlayFair and Vigenere Cipher
Caesar Cipher , Substitution Cipher, PlayFair and Vigenere Cipher
 
Cryptography
CryptographyCryptography
Cryptography
 
Cns 1
Cns 1Cns 1
Cns 1
 
Cryptography
CryptographyCryptography
Cryptography
 
Introduction to Cryptography and the Public Key Infrastructure
Introduction to Cryptography and the Public Key InfrastructureIntroduction to Cryptography and the Public Key Infrastructure
Introduction to Cryptography and the Public Key Infrastructure
 
substitution and transposition techniques_ppt.pptx
substitution and transposition techniques_ppt.pptxsubstitution and transposition techniques_ppt.pptx
substitution and transposition techniques_ppt.pptx
 
security system by desu star chapter 2 (1).pptx
security system by desu star chapter 2 (1).pptxsecurity system by desu star chapter 2 (1).pptx
security system by desu star chapter 2 (1).pptx
 
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
 
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
 
Introduction to Cryptography Week4 Part1-ISrevisionSu.docx
Introduction to Cryptography  Week4 Part1-ISrevisionSu.docxIntroduction to Cryptography  Week4 Part1-ISrevisionSu.docx
Introduction to Cryptography Week4 Part1-ISrevisionSu.docx
 
Crypt
CryptCrypt
Crypt
 
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.
 
SYMMETRIC CRYPTOGRAPHY
SYMMETRIC CRYPTOGRAPHY SYMMETRIC CRYPTOGRAPHY
SYMMETRIC CRYPTOGRAPHY
 
A New Modified Version of Caser Cipher Algorithm
A New Modified Version of Caser Cipher AlgorithmA New Modified Version of Caser Cipher Algorithm
A New Modified Version of Caser Cipher Algorithm
 
Classical cyphers python programming
Classical cyphers python programmingClassical cyphers python programming
Classical cyphers python programming
 
Encryption
EncryptionEncryption
Encryption
 

Recently uploaded

TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor CatchersTechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catcherssdickerson1
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvLewisJB
 
Indian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptIndian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptMadan Karki
 
Oxy acetylene welding presentation note.
Oxy acetylene welding presentation note.Oxy acetylene welding presentation note.
Oxy acetylene welding presentation note.eptoze12
 
welding defects observed during the welding
welding defects observed during the weldingwelding defects observed during the welding
welding defects observed during the weldingMuhammadUzairLiaqat
 
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
 
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
 
US Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionUS Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionMebane Rash
 
Correctly Loading Incremental Data at Scale
Correctly Loading Incremental Data at ScaleCorrectly Loading Incremental Data at Scale
Correctly Loading Incremental Data at ScaleAlluxio, Inc.
 
An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...Chandu841456
 
Class 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm SystemClass 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm Systemirfanmechengr
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfROCENODodongVILLACER
 
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
 
Vishratwadi & Ghorpadi Bridge Tender documents
Vishratwadi & Ghorpadi Bridge Tender documentsVishratwadi & Ghorpadi Bridge Tender documents
Vishratwadi & Ghorpadi Bridge Tender documentsSachinPawar510423
 
Arduino_CSE ece ppt for working and principal of arduino.ppt
Arduino_CSE ece ppt for working and principal of arduino.pptArduino_CSE ece ppt for working and principal of arduino.ppt
Arduino_CSE ece ppt for working and principal of arduino.pptSAURABHKUMAR892774
 
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
 
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsyncWhy does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsyncssuser2ae721
 

Recently uploaded (20)

TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor CatchersTechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
 
Work Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvvWork Experience-Dalton Park.pptxfvvvvvvv
Work Experience-Dalton Park.pptxfvvvvvvv
 
Indian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.pptIndian Dairy Industry Present Status and.ppt
Indian Dairy Industry Present Status and.ppt
 
Oxy acetylene welding presentation note.
Oxy acetylene welding presentation note.Oxy acetylene welding presentation note.
Oxy acetylene welding presentation note.
 
welding defects observed during the welding
welding defects observed during the weldingwelding defects observed during the welding
welding defects observed during the welding
 
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
 
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
 
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
 
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
 
US Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of ActionUS Department of Education FAFSA Week of Action
US Department of Education FAFSA Week of Action
 
Correctly Loading Incremental Data at Scale
Correctly Loading Incremental Data at ScaleCorrectly Loading Incremental Data at Scale
Correctly Loading Incremental Data at Scale
 
An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...An experimental study in using natural admixture as an alternative for chemic...
An experimental study in using natural admixture as an alternative for chemic...
 
Class 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm SystemClass 1 | NFPA 72 | Overview Fire Alarm System
Class 1 | NFPA 72 | Overview Fire Alarm System
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdf
 
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
 
Vishratwadi & Ghorpadi Bridge Tender documents
Vishratwadi & Ghorpadi Bridge Tender documentsVishratwadi & Ghorpadi Bridge Tender documents
Vishratwadi & Ghorpadi Bridge Tender documents
 
Arduino_CSE ece ppt for working and principal of arduino.ppt
Arduino_CSE ece ppt for working and principal of arduino.pptArduino_CSE ece ppt for working and principal of arduino.ppt
Arduino_CSE ece ppt for working and principal of arduino.ppt
 
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
 
young call girls in Green Park🔝 9953056974 🔝 escort Service
young call girls in Green Park🔝 9953056974 🔝 escort Serviceyoung call girls in Green Park🔝 9953056974 🔝 escort Service
young call girls in Green Park🔝 9953056974 🔝 escort Service
 
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsyncWhy does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
 

Symmetric and asymmetric key cryptography

  • 1. NORTH WESTERN UNIVERSITY Computer Science & Engineering Course Titel: Computer Networks Course Code: CSE-3205 Presentation on: Symmetric and Asymmetric key cryptography. Submitted by: Name : MD. MONIRUL ISLAM ID: 20151116010 Submitted to: Name : Romana Rahman Senior Lecturer Computer Science & Engineering North Western University , Khulna
  • 2. INDEX: * General Introduction of Cryptography. * Objectives * Types of Cryptography. * Symmetric Cryptosystems. * Limitations of Symmetric Cryptography * Asymmetric Cryptosystems. * Limitations of Asymmetric Cryptography. * References.
  • 3. General Introduction of Cryptography Cryptography is a method of protecting information and communications through the use of codes, so that only those for whom the information is intended can read and process it. It has two main Components: 1. Encryption – Practice of hiding messages so that they can not be read by anyone other than the intended recipient 2. Authentication – Ensuring that users of data/resources are the persons they claim to be and that a message has not been surreptitiously altered
  • 4. How does it work?  Two functions are needed: Fig 01: Encoder & Decoder
  • 5. Example  encoder function is next letter in the alphabet.  decoder function is … Fig 02: Encoder & Decoder
  • 6. Encryption and Decryption - Plain text - Cipher text  Encoding :- The contents of the message (the plain text) in such a way that hides its contents from outsiders is called encryption.  The process of retrieving the plaintext from the cipher-text is called decryption.  Encryption and decryption usually make use of a key, and the coding method is such that decryption. Can be performed only by knowing the proper key.
  • 7. Objectives Cryptography has four main objectives:  Confidentiality of the message: Only the authorized recipient should be able to extract the content of the cypher. In addition, obtaining information about the content of the message (such as a statistical distribution of certain characters) should not be possible, once the cryptographic analysis becomes easier.  Message integrity: The recipient must be able to determine if the message was altered during transmission.  Authentication of the sender: The recipient should be able to identify the sender and verify if it was him who sent the message.  Irrevocability of the sender: It should not be possible to deny the authorship of the message.
  • 8. Types of Cryptography Two kinds of Cryptography: Symmetric 1) Alice and Bob agree on a cryptosystem 2) Alice and Bob agree on a key. 3) Alice takes her plaintext message and encrypts it using the encryption algorithm and the key. This creates a cipher text message. 4) Alice sends the cipher text message to Bob. 5) Bob decrypts the cipher text message with the same algorithm and key and reads it. Asymmetric 1) Alice and Bob agree on a public-key cryptosystem. 2) Bob sends Alice his public key. 3) Alice encrypts her message using Bob’s public key and sends it to Bob. 4) Bob decrypts Alice’s message using his private key.
  • 9. Symmetric Cryptosystem Both the sender and receiver share a single key. The sender uses this key to encrypt plaintext and send the cipher text to the receiver. On the other side the receiver applies the same key to decrypt the message and recover the plain text. Material to keep secret: Text Data Audio Video Graphics Material to keep secret: Text Data Audio Video Graphics Lock Encryption Algorithm Decryption Algorithm Shared Key Sender and recipient Must both know the key. This is a weakness! Fig 03: Symmetric Cryptosystem
  • 10. Traditional ciphers Traditional cipher are two types  Simple substitution Cipher.  Transposition Cipher. Fig 04: Traditional Ciphers
  • 11. Simple Substitution Ciphers It is an improvement to the Caesar Cipher. Instead of shifting the alphabets by some number, this scheme uses some permutation of the letters in alphabet. For example, A.B…..Y.Z and Z.Y……B.A are two obvious permutation of all the letters in alphabet. Permutation is nothing but a jumbled up set of alphabets. With 26 letters in alphabet, the possible permutations are 26! (Factorial of 26) which is equal to 4x1026. The sender and the receiver may choose any one of these possible permutation as a cipher text alphabet. This permutation is the secret key of the scheme.
  • 12. Process of Simple Substitution Cipher 1.Write the alphabets A, B, C,...,Z in the natural order. 2. The sender and the receiver decide on a randomly selected permutation of the letters of the alphabet. 3. Underneath the natural order alphabets, write out the chosen permutation of the letters of the alphabet. For encryption, sender replaces each plaintext letters by substituting the permutation letter that is directly beneath it in the table. This process is shown in the following illustration. In this example, the chosen permutation is K,D, G, ..., O. The plaintext ‘point’ is encrypted to ‘MJBXZ’. Here is a jumbled Cipher text alphabet, where the order of the cipher text letters is a key. On receiving the cipher text, the receiver, who also knows the randomly chosen permutation, replaces each cipher text letter on the bottom row with the corresponding plaintext letter in the top row. The cipher text ‘MJBXZ’ is decrypted to ‘point’.
  • 13. Mono alphabetic Cipher Mono alphabetic cipher is a substitution cipher in which for a given key, the cipher alphabet for each plain alphabet is fixed throughout the encryption process. A simple example is where each letter is encrypted as the next letter in the alphabet: "a simple message" becomes "B TJNQMF NFTTBHF". In general, when performing a simple substitution manually, it is easiest to generate the cipher text alphabet first, and encrypt by comparing this to the plaintext alphabet. The table below shows how one might choose to, and we will, lay them out for this example.
  • 14. 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 cipher text is a one-to-many relationship. As an example we shall encrypt the plaintext "Leon Battista albert". To keep with the convention of writing cipher text in uppercase, we shall invert Alberta's own rule, and use lowercase letters to signify the change. We start by referencing the starting position of the cipher disc, which in this case is "a" is encrypted as "V", so we start the Cipher text with a lowercase "v". We then encrypt the first few letters as a Caesar Shift, using the cipher text alphabet given below. The 1st shift used, as the disk in shown Plaintext: leonbat... Cipher text: vGZJIWVOg...
  • 15. The uppercase letters above encrypt the plaintext letters given. The "v" indicates the starting position of the disc, and the "g" indicates that we need to change the position so that "G" is beneath "a". We then get the new cipher text Alphabet as shown below. Plaintext: ...tistaa... Cipher text: ...gZOYZGGm... This time the plaintext letters are encrypted to the cipher text letters using the cipher text alphabet above, and the "m“ indicates that we are changing alphabet again to get the final cipher text alphabet below. Plaintext: ...lberti Cipher text: ...mXNQDFU So we get the final cipher text "vGZJIWVOgZOYZGGmXNQDFU".
  • 16. Transposition Cipher Transposition Ciphers are a bit different to Substitution Ciphers. Whereas Substitution ciphers replace each letter with a different letter or symbol to produce the cipher text, in a Transposition cipher, the letters are just moved around. The letters or words of the plaintext are reordered in some way, fixed by a given rule (the key). One example of a transposition cipher, is to reverse the order of the letters in a plaintext. So "a simple example" becomes "ELPMAXE ELPMIS A". Another, similar, way to encrypt a message would be to reverse the letters of each word, but not the order in which the words are written. In this case "a simple example“ becomes "A ELPMIS ELPMAXE". Both of these are available in the activity at the bottom of the page.
  • 17. Limitations of Symmetric Cryptography  Many people need to communicate with a server (many-to-one communications).  cannot keep server key secret for long.  Once the secret key is compromised, the security of all subsequent. messages is suspect and a new key has to be generated.  Authentication service must know private key.  privacy implications---someone else knows your key.  two possible points of attack.  changing authentication service requires a new key.  Digital signatures are difficult.  Crossrealm authentication.  accessing services outside the domain or realm of your authentication server is problematic.  requires agreement and trust between authentication services.  introduces another potential point of attack.
  • 18. Asymmetric Cryptosystems In asymmetric-key cryptography, users do not need to know a symmetric shared key; everyone • shields a private key and • advertises a public key Material to keep secret: Text Data Audio Video Graphics Material to keep secret: Text Data Audio Video Graphics Lock Encryption Algorithm Decryption Algorithm Decryption keyEncryption Key Sender knows public key Recipient knows private key. Fig 05: Asymmetric Cryptosystem
  • 19. RSA Cryptography RSA algorithm is a public key encryption technique and is considered as the most secure way of encryption. It was invented by Rivest, Shamir and Adleman in year 1978 and hence name RSA algorithm. Process of RSA  Choose two large prime numbers p & q  Compute n= p q and z=(p-1)(q-1)  Choose number e, less than n, which has no common factor (other than 1) with z  Find number d, such that e d – 1 is exactly divisible by z Keys are generated using n, d, e -Public key is (n, e) -Private key is (n, d)  Encryption: c = me mod n -m is plain text -c is cipher text  Decryption: m = cd mod n  Public key is shared and the private key is hidden
  • 20. P=5 & q=7 n=5*7=35 and z=(4)*(6) = 24 e = 5 d = 29 , (29x5 –1) is exactly divisible by 24 Keys generated are -Public key: (35,5) -Private key is (35, 29) Encrypt the word love using (c = me mod n) -Assume that the alphabets are between 1 & 26
  • 21.  Decrypt the word love using (m = cd mod n) -n = 35, c=29
  • 22. Limitations of Asymmetric Cryptography  It is a slow process.  Its public keys are not authenticated.  It risks loss of private key, which may be irreparable.  It risks widespread security compromise.
  • 23. References [1] Thomas H. Cormen, Charles E. Leiserson, Ronald L. Rivest, and Clifford Stein. Introduction to Algorithms. MIT Press and McGraw-Hill, 2001. ISBN 0-262-03293-7. Section 31.7: The RSA public-key cryptosystem, pp.881–887 [2] Bruce Schneier. Applied Cryptography. John Wiley & Sons, Inc. 1996. (ISBN: 0471128457) [3] Bob Thibadeau http://dollar.ecom.cmu.edu/sec/lec02.ppt. [4] [2]Data Communications and Networking By Behrouz A.Forouzan.