SlideShare a Scribd company logo
Cryptology
DUH BRX UHDGB?
Slides by Raymond Borges




                           1
Outline
•   Background
•   Ancient Cryptography
•   Frequency Analysis
•   Modern Cryptography
•   Secure Communication
•   Tools of the trade
•   Conclusion

                            2
Background




             3
Background




             4
The Ancient Art of Secret Messages




                                 5
Background

Principles and methods for:
1. Transforming message into unintelligible
2. Transforming message back to original form




                                                6
Background

Principles and methods for:
• Retransforming message back to original form
• Without knowledge of key




                                                 7
Background




             8
Encryption
• Plaintext: This is what you want to encrypt
• Ciphertext: The encrypted output
• Enciphering or encryption: process which
  converts plaintext to ciphertext
• Encryption algorithm: Sequence processing
  steps to transform plaintext into ciphertext
• Secret key: Sets some or all parameters used
  by encryption algorithm
                                                 9
Practice (transposition)
Caesar Cipher
Ciphertext: DUH BRX UHDGB
Solution:
c = E(k, p) = (p + k) mod 26
c = E(3, p) = (p + 3) mod 26 for k=key=3
4 mod 26 = 4 so A=D

p = D(k, c) = (c − k) mod 26
D=4 (4-3) mod 26 = 1

                                           10
Practice (substitution)
Monoalphabetic cipher
• plaintext letters: a b c d e f .....
• substitution letters: t h i j a b .....
Key is sequence of substitution letters
26 ! = 4.03291461 × 1026
Impossible to crack? No….

Polyalphabetic tougher…

                                            11
ETAOIN SHRDLU (Frequency analysis)
• ‘E’ is the most common letter in the English
  language,
• ‘Th’ is the most common bigram
• ‘The’ most common trigram
• Letter frequency English 




                                                 12
Frequency analysis
• Most frequently occurring trigrams ordered by
  decreasing frequency are:




                                              13
Polyalphabetic Ciphers
•   The Vigenère cipher
•   First letter use key 1
•   Second uses key 2
•   Third uses key 3

To Decrypt go backwards



                                    14
Modern Cryptography
Data Encryption Standard (DES) 1976
• 64 bit key (uses 56bits)
• 16 stages
• Block divided into two 32-bit halves
• XOR
• Subkeys made key schedule



                                         15
Modern Cryptography
Feistel function:
1. Expansion- the 32-bit half-block is expanded
   to 48 bits by duplicating half of the bits
2. Key mixing — the result is combined with a
   subkey using an XOR operation.
3. Substitution —block divided into eight 6-bit
   pieces then uses substitution boxes
4. Permutation
                                                  16
Modern Cryptography
Advanced Encryption Standard (AES) 2001
• Substitution-permutation network
• Not Feistel
• Fixed block size 128 bits
• Key size of 128, 192, or 256 bits




                                          17
Modern Cryptography
                   Advanced Encryption Standard (AES)
1. KeyExpansion
2. Initial Round
         1. AddRoundKey
3. Rounds
         1. SubEytes
         2. ShiftRows
         3. MixColumns
         4. AddRoundKey
4.Final Round
         1. SubBytes
         2. ShiftRows
         3. AddRoundKey
                                                        18
Public-key cryptography
RSA- Ron Rivest, Adi Shamir, Leonard Adleman 1978
• Uses factoring problem (large primes)
• Two large primes of similar size > 100 digits

Example:
Public (n = 3233, e = 17)
Private key is (n = 3233, d = 2753)

n=p1*p2,
e=coprime number to (p1-1)(p2-1)
d =modular multiplicative inverse of e          19
Public-key cryptography
     Encryption               Decryption
   c = me (mod n)            m = cd (mod n)

Example:
To encrypt m = 65
c = 6517 (mod 3233) = 2790

To decrypt c = 2790, we calculate
m = 27902753 (mod 3233) = 65
                                              20
Secure Communication
• AES 256 bit key
• 15360-bit RSA keys are equivalent 256-bit
  symmetric keys
• 2^256 = 1.15792089 × 1077 brute-force?

Use RSA then AES for secure communication
HTTPS, SSH, SFTP, SSL and TLS and others

                                              21
Some Tools of the trade
File Encryption
• Axantum
• WinZip

Disk encryption
• TrueCrypt

Network
• Open SSH

                                  22
References
• http://www.axantum.com/axcrypt/Downloads
  .html
• http://dottech.org/freeware-reviews/15996/
• http://technet.microsoft.com/en-
  us/library/cc757819(v=ws.10).aspx




                                           23
Questions?




             24

More Related Content

What's hot

Crypto theory to practice
Crypto theory to practiceCrypto theory to practice
Crypto theory to practice
Harry Potter
 
Cryptography and SSL in Smalltalk - StS 2003
Cryptography and SSL in Smalltalk - StS 2003Cryptography and SSL in Smalltalk - StS 2003
Cryptography and SSL in Smalltalk - StS 2003
Martin Kobetic
 
Cryptography
CryptographyCryptography
Cryptography
Harry Potter
 
A promising approach for debugging remote promises
A promising approach for debugging remote promisesA promising approach for debugging remote promises
A promising approach for debugging remote promises
ESUG
 
AREA41 - Anatomy of attacks aimed at financial sector by the Lazarus group
AREA41 - Anatomy of attacks aimed at financial sector by the Lazarus groupAREA41 - Anatomy of attacks aimed at financial sector by the Lazarus group
AREA41 - Anatomy of attacks aimed at financial sector by the Lazarus group
SeongsuPark8
 
Implementation of RSA Algorithm for Speech Data Encryption and Decryption
Implementation of RSA Algorithm for Speech Data Encryption and DecryptionImplementation of RSA Algorithm for Speech Data Encryption and Decryption
Implementation of RSA Algorithm for Speech Data Encryption and Decryption
Md. Ariful Hoque
 
Strong cryptography in PHP
Strong cryptography in PHPStrong cryptography in PHP
Strong cryptography in PHP
Enrico Zimuel
 
VisualWorks Security Reloaded - STIC 2012
VisualWorks Security Reloaded - STIC 2012VisualWorks Security Reloaded - STIC 2012
VisualWorks Security Reloaded - STIC 2012
Martin Kobetic
 
How does cryptography work? by Jeroen Ooms
How does cryptography work?  by Jeroen OomsHow does cryptography work?  by Jeroen Ooms
How does cryptography work? by Jeroen Ooms
Ajay Ohri
 
How-to crack 43kk passwords while drinking your juice/smoozie in the Hood
How-to crack 43kk passwords  while drinking your  juice/smoozie in the HoodHow-to crack 43kk passwords  while drinking your  juice/smoozie in the Hood
How-to crack 43kk passwords while drinking your juice/smoozie in the Hood
Yurii Bilyk
 
Applying Security Algorithms Using openSSL crypto library
Applying Security Algorithms Using openSSL crypto libraryApplying Security Algorithms Using openSSL crypto library
Applying Security Algorithms Using openSSL crypto library
Priyank Kapadia
 
OWASP Poland Day 2018 - Damian Rusinek - Outsmarting smart contracts
OWASP Poland Day 2018 - Damian Rusinek - Outsmarting smart contractsOWASP Poland Day 2018 - Damian Rusinek - Outsmarting smart contracts
OWASP Poland Day 2018 - Damian Rusinek - Outsmarting smart contracts
OWASP
 
Compiler basics: lisp to assembly
Compiler basics: lisp to assemblyCompiler basics: lisp to assembly
Compiler basics: lisp to assembly
Phil Eaton
 

What's hot (13)

Crypto theory to practice
Crypto theory to practiceCrypto theory to practice
Crypto theory to practice
 
Cryptography and SSL in Smalltalk - StS 2003
Cryptography and SSL in Smalltalk - StS 2003Cryptography and SSL in Smalltalk - StS 2003
Cryptography and SSL in Smalltalk - StS 2003
 
Cryptography
CryptographyCryptography
Cryptography
 
A promising approach for debugging remote promises
A promising approach for debugging remote promisesA promising approach for debugging remote promises
A promising approach for debugging remote promises
 
AREA41 - Anatomy of attacks aimed at financial sector by the Lazarus group
AREA41 - Anatomy of attacks aimed at financial sector by the Lazarus groupAREA41 - Anatomy of attacks aimed at financial sector by the Lazarus group
AREA41 - Anatomy of attacks aimed at financial sector by the Lazarus group
 
Implementation of RSA Algorithm for Speech Data Encryption and Decryption
Implementation of RSA Algorithm for Speech Data Encryption and DecryptionImplementation of RSA Algorithm for Speech Data Encryption and Decryption
Implementation of RSA Algorithm for Speech Data Encryption and Decryption
 
Strong cryptography in PHP
Strong cryptography in PHPStrong cryptography in PHP
Strong cryptography in PHP
 
VisualWorks Security Reloaded - STIC 2012
VisualWorks Security Reloaded - STIC 2012VisualWorks Security Reloaded - STIC 2012
VisualWorks Security Reloaded - STIC 2012
 
How does cryptography work? by Jeroen Ooms
How does cryptography work?  by Jeroen OomsHow does cryptography work?  by Jeroen Ooms
How does cryptography work? by Jeroen Ooms
 
How-to crack 43kk passwords while drinking your juice/smoozie in the Hood
How-to crack 43kk passwords  while drinking your  juice/smoozie in the HoodHow-to crack 43kk passwords  while drinking your  juice/smoozie in the Hood
How-to crack 43kk passwords while drinking your juice/smoozie in the Hood
 
Applying Security Algorithms Using openSSL crypto library
Applying Security Algorithms Using openSSL crypto libraryApplying Security Algorithms Using openSSL crypto library
Applying Security Algorithms Using openSSL crypto library
 
OWASP Poland Day 2018 - Damian Rusinek - Outsmarting smart contracts
OWASP Poland Day 2018 - Damian Rusinek - Outsmarting smart contractsOWASP Poland Day 2018 - Damian Rusinek - Outsmarting smart contracts
OWASP Poland Day 2018 - Damian Rusinek - Outsmarting smart contracts
 
Compiler basics: lisp to assembly
Compiler basics: lisp to assemblyCompiler basics: lisp to assembly
Compiler basics: lisp to assembly
 

Similar to Cybersecurity cyberlab3

Cryptography - 101
Cryptography - 101Cryptography - 101
Overview on Cryptography and Network Security
Overview on Cryptography and Network SecurityOverview on Cryptography and Network Security
Overview on Cryptography and Network Security
Dr. Rupa Ch
 
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
RobertCarreonBula
 
Cryptography & Steganography
Cryptography & SteganographyCryptography & Steganography
Cryptography & Steganography
Animesh Shaw
 
Trible data encryption standard (3DES)
Trible data encryption standard (3DES)Trible data encryption standard (3DES)
Trible data encryption standard (3DES)
Ahmed Mohamed Mahmoud
 
1 DES.pdf
1 DES.pdf1 DES.pdf
1 DES.pdf
nitin571047
 
Cryptography and network security Nit701
Cryptography and network security Nit701Cryptography and network security Nit701
Cryptography and network security Nit701
Amit Pathak
 
Cryptography.ppt
Cryptography.pptCryptography.ppt
Cryptography.ppt
PriyanshuGupta896141
 
4. Block Ciphers
4. Block Ciphers 4. Block Ciphers
4. Block Ciphers
Sam Bowne
 
Different types of Symmetric key Cryptography
Different types of Symmetric key CryptographyDifferent types of Symmetric key Cryptography
Different types of Symmetric key Cryptographysubhradeep mitra
 
Introduction to cryptography part2-final
Introduction to cryptography  part2-finalIntroduction to cryptography  part2-final
Introduction to cryptography part2-final
Taymoor Nazmy
 
Cryptography
CryptographyCryptography
Cryptography
subodh pawar
 
Symmetric encryption
Symmetric encryptionSymmetric encryption
Symmetric encryption
DR RICHMOND ADEBIAYE
 
CRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITYCRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITY
Kathirvel Ayyaswamy
 
block ciphers
block ciphersblock ciphers
block ciphers
Asad Ali
 
3 Basics of Cryptography Basics of Cryptography
3 Basics of Cryptography  Basics of Cryptography3 Basics of Cryptography  Basics of Cryptography
3 Basics of Cryptography Basics of Cryptography
MohammedMorhafJaely
 
Fundamentals of Information Encryption
Fundamentals of Information EncryptionFundamentals of Information Encryption
Fundamentals of Information Encryption
Amna Magzoub
 

Similar to Cybersecurity cyberlab3 (20)

Cryptography - 101
Cryptography - 101Cryptography - 101
Cryptography - 101
 
Cryptography-101
Cryptography-101Cryptography-101
Cryptography-101
 
Overview on Cryptography and Network Security
Overview on Cryptography and Network SecurityOverview on Cryptography and Network Security
Overview on Cryptography and Network Security
 
Class3
Class3Class3
Class3
 
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
 
Cryptography & Steganography
Cryptography & SteganographyCryptography & Steganography
Cryptography & Steganography
 
Trible data encryption standard (3DES)
Trible data encryption standard (3DES)Trible data encryption standard (3DES)
Trible data encryption standard (3DES)
 
1 DES.pdf
1 DES.pdf1 DES.pdf
1 DES.pdf
 
section-8.ppt
section-8.pptsection-8.ppt
section-8.ppt
 
Cryptography and network security Nit701
Cryptography and network security Nit701Cryptography and network security Nit701
Cryptography and network security Nit701
 
Cryptography.ppt
Cryptography.pptCryptography.ppt
Cryptography.ppt
 
4. Block Ciphers
4. Block Ciphers 4. Block Ciphers
4. Block Ciphers
 
Different types of Symmetric key Cryptography
Different types of Symmetric key CryptographyDifferent types of Symmetric key Cryptography
Different types of Symmetric key Cryptography
 
Introduction to cryptography part2-final
Introduction to cryptography  part2-finalIntroduction to cryptography  part2-final
Introduction to cryptography part2-final
 
Cryptography
CryptographyCryptography
Cryptography
 
Symmetric encryption
Symmetric encryptionSymmetric encryption
Symmetric encryption
 
CRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITYCRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITY
 
block ciphers
block ciphersblock ciphers
block ciphers
 
3 Basics of Cryptography Basics of Cryptography
3 Basics of Cryptography  Basics of Cryptography3 Basics of Cryptography  Basics of Cryptography
3 Basics of Cryptography Basics of Cryptography
 
Fundamentals of Information Encryption
Fundamentals of Information EncryptionFundamentals of Information Encryption
Fundamentals of Information Encryption
 

More from rayborg

Borges rprojectcs691y
Borges rprojectcs691yBorges rprojectcs691y
Borges rprojectcs691y
rayborg
 
Cybersecurity cyberlab2
Cybersecurity cyberlab2Cybersecurity cyberlab2
Cybersecurity cyberlab2
rayborg
 
Cybersecurity cyberlab1
Cybersecurity cyberlab1Cybersecurity cyberlab1
Cybersecurity cyberlab1
rayborg
 
Research week3 idea
Research week3 ideaResearch week3 idea
Research week3 idea
rayborg
 
Mushroom tutorial http://rjdatamining.weebly.com
Mushroom tutorial http://rjdatamining.weebly.comMushroom tutorial http://rjdatamining.weebly.com
Mushroom tutorial http://rjdatamining.weebly.com
rayborg
 
Project 2 Data Mining Part 1
Project 2 Data Mining Part 1Project 2 Data Mining Part 1
Project 2 Data Mining Part 1rayborg
 

More from rayborg (6)

Borges rprojectcs691y
Borges rprojectcs691yBorges rprojectcs691y
Borges rprojectcs691y
 
Cybersecurity cyberlab2
Cybersecurity cyberlab2Cybersecurity cyberlab2
Cybersecurity cyberlab2
 
Cybersecurity cyberlab1
Cybersecurity cyberlab1Cybersecurity cyberlab1
Cybersecurity cyberlab1
 
Research week3 idea
Research week3 ideaResearch week3 idea
Research week3 idea
 
Mushroom tutorial http://rjdatamining.weebly.com
Mushroom tutorial http://rjdatamining.weebly.comMushroom tutorial http://rjdatamining.weebly.com
Mushroom tutorial http://rjdatamining.weebly.com
 
Project 2 Data Mining Part 1
Project 2 Data Mining Part 1Project 2 Data Mining Part 1
Project 2 Data Mining Part 1
 

Cybersecurity cyberlab3

  • 1. Cryptology DUH BRX UHDGB? Slides by Raymond Borges 1
  • 2. Outline • Background • Ancient Cryptography • Frequency Analysis • Modern Cryptography • Secure Communication • Tools of the trade • Conclusion 2
  • 5. The Ancient Art of Secret Messages 5
  • 6. Background Principles and methods for: 1. Transforming message into unintelligible 2. Transforming message back to original form 6
  • 7. Background Principles and methods for: • Retransforming message back to original form • Without knowledge of key 7
  • 9. Encryption • Plaintext: This is what you want to encrypt • Ciphertext: The encrypted output • Enciphering or encryption: process which converts plaintext to ciphertext • Encryption algorithm: Sequence processing steps to transform plaintext into ciphertext • Secret key: Sets some or all parameters used by encryption algorithm 9
  • 10. Practice (transposition) Caesar Cipher Ciphertext: DUH BRX UHDGB Solution: c = E(k, p) = (p + k) mod 26 c = E(3, p) = (p + 3) mod 26 for k=key=3 4 mod 26 = 4 so A=D p = D(k, c) = (c − k) mod 26 D=4 (4-3) mod 26 = 1 10
  • 11. Practice (substitution) Monoalphabetic cipher • plaintext letters: a b c d e f ..... • substitution letters: t h i j a b ..... Key is sequence of substitution letters 26 ! = 4.03291461 × 1026 Impossible to crack? No…. Polyalphabetic tougher… 11
  • 12. ETAOIN SHRDLU (Frequency analysis) • ‘E’ is the most common letter in the English language, • ‘Th’ is the most common bigram • ‘The’ most common trigram • Letter frequency English  12
  • 13. Frequency analysis • Most frequently occurring trigrams ordered by decreasing frequency are: 13
  • 14. Polyalphabetic Ciphers • The Vigenère cipher • First letter use key 1 • Second uses key 2 • Third uses key 3 To Decrypt go backwards 14
  • 15. Modern Cryptography Data Encryption Standard (DES) 1976 • 64 bit key (uses 56bits) • 16 stages • Block divided into two 32-bit halves • XOR • Subkeys made key schedule 15
  • 16. Modern Cryptography Feistel function: 1. Expansion- the 32-bit half-block is expanded to 48 bits by duplicating half of the bits 2. Key mixing — the result is combined with a subkey using an XOR operation. 3. Substitution —block divided into eight 6-bit pieces then uses substitution boxes 4. Permutation 16
  • 17. Modern Cryptography Advanced Encryption Standard (AES) 2001 • Substitution-permutation network • Not Feistel • Fixed block size 128 bits • Key size of 128, 192, or 256 bits 17
  • 18. Modern Cryptography Advanced Encryption Standard (AES) 1. KeyExpansion 2. Initial Round 1. AddRoundKey 3. Rounds 1. SubEytes 2. ShiftRows 3. MixColumns 4. AddRoundKey 4.Final Round 1. SubBytes 2. ShiftRows 3. AddRoundKey 18
  • 19. Public-key cryptography RSA- Ron Rivest, Adi Shamir, Leonard Adleman 1978 • Uses factoring problem (large primes) • Two large primes of similar size > 100 digits Example: Public (n = 3233, e = 17) Private key is (n = 3233, d = 2753) n=p1*p2, e=coprime number to (p1-1)(p2-1) d =modular multiplicative inverse of e 19
  • 20. Public-key cryptography Encryption Decryption c = me (mod n) m = cd (mod n) Example: To encrypt m = 65 c = 6517 (mod 3233) = 2790 To decrypt c = 2790, we calculate m = 27902753 (mod 3233) = 65 20
  • 21. Secure Communication • AES 256 bit key • 15360-bit RSA keys are equivalent 256-bit symmetric keys • 2^256 = 1.15792089 × 1077 brute-force? Use RSA then AES for secure communication HTTPS, SSH, SFTP, SSL and TLS and others 21
  • 22. Some Tools of the trade File Encryption • Axantum • WinZip Disk encryption • TrueCrypt Network • Open SSH 22
  • 23. References • http://www.axantum.com/axcrypt/Downloads .html • http://dottech.org/freeware-reviews/15996/ • http://technet.microsoft.com/en- us/library/cc757819(v=ws.10).aspx 23

Editor's Notes

  1. 1. Are you ready
  2. M=message c=ciphertext n and e define in keys