SlideShare uma empresa Scribd logo
1 de 95
Baixar para ler offline
Introducing
                     cryptography and PKI
                            David Galichet




mercredi 23 novembre 2011
Cryptography challenges




mercredi 23 novembre 2011
Authentication

                   • Application authentication
                   • Single Sign On
                   • One Time Password
                   • Remember me
                   • ...

mercredi 23 novembre 2011
Integrity



                   • Data are not corrupted
                   • Data are not intentionally altered


mercredi 23 novembre 2011
Privacy


                   • Protect data transfer
                   • Protect stored data



mercredi 23 novembre 2011
Identity
                   • Authentication (user and server side)
                   • Signature (document, application packages ...)
                   • Non repudiation
                   • Trusted Timestamps
                   • Anonymity (electronic vote, alternative
                            currency ...)
                   • ...
mercredi 23 novembre 2011
Cryptography basis


                   • Hash functions
                   • Symmetric ciphering
                   • Asymmetric ciphering


mercredi 23 novembre 2011
Hash algorithms
                  • Generate a constant size fingerprint whatever
                            data in entry
                  • It’s hard to find the message from the given hash
                            (First Preimage Resistance)
                  • It’s hard to modify a message without hash
                            being changed (Second Preimage Resistance)
                  • It’s hard to find two different messages with the
                            same hash (Resistance to Collisions)
                  • Very fast calculation
mercredi 23 novembre 2011
Cryptographic
                                  Hash algorithms
                  • Generate a constant size fingerprint whatever
                            data in entry
                               infeasible
                  •         It’s hard to find the message from the given hash
                            (First Preimage Resistance)
                               infeasible
                  •         It’s hard to modify a message without hash
                            being changed (Second Preimage Resistance)
                               infeasible
                  •         It’s hard to find two different messages with the
                            same hash (Resistance to Collisions)
                  • Very fast calculation
mercredi 23 novembre 2011
Hash functions
                Integrity checking :

                            hash()
                   File                415a15b606eff4d4ba97ef64ecd2e598




mercredi 23 novembre 2011
Hash functions
                Integrity checking :        Fingerprint or checksum

                            hash()
                   File                415a15b606eff4d4ba97ef64ecd2e598




mercredi 23 novembre 2011
Hash functions
                Integrity checking :              Fingerprint or checksum

                                  hash()
                   File                      415a15b606eff4d4ba97ef64ecd2e598




                            Very low probability of collision !
                Hard to change file without changing hash !
                                     Fast algorithm !

mercredi 23 novembre 2011
Hash functions
            Password encryption :

                            hash()
            password                 415a15b606eff4d4ba97ef64ecd2e598




mercredi 23 novembre 2011
Hash functions
            Password encryption :

                                  hash()
            password                        415a15b606eff4d4ba97ef64ecd2e598




                            Hard to calculate password from the
                                           hash !


mercredi 23 novembre 2011
Hash functions
           Remember me tokens :

                            username + expiration date + hash(password)


                                                   hash()



                                  415a15b606eff4d4ba97ef64ecd2e598



             Remember me token = hash(...) + username + expiration date


mercredi 23 novembre 2011
Password hashing leaks

                   • Brute force
                   • Dictionary
                   • Rainbow table



mercredi 23 novembre 2011
Password hashing leaks

                   • Brute force
                   • Dictionary
                   • Rainbow table



mercredi 23 novembre 2011
Salted hash functions
        Salted hash password :
                                     hash()
               salt + password                hash(salt+password)




mercredi 23 novembre 2011
Salted hash functions
        Salted hash password :
                                     hash()
               salt + password                hash(salt+password)



        secret and / or
        user dependent




mercredi 23 novembre 2011
Salted hash functions
        Salted hash password :
                                        hash()
               salt + password                      hash(salt+password)



        secret and / or
        user dependent

                              Prevents from dictionary and
                                 rainbow table attacks !


mercredi 23 novembre 2011
Hash function algorithms

                   •        Message Digest 5

                            •   128 bits fingerprint size

                   •        Secured Hash Algorithm

                            •   many version (SHA1, SHA256 ...)

                            •   160 to 512 bits fingerprint size




mercredi 23 novembre 2011
Hash function algorithms

                   •        Message Digest 5       @deprecated
                            •   128 bits fingerprint size

                   •        Secured Hash Algorithm

                            •   many version (SHA1, SHA256 ...)

                            •   160 to 512 bits fingerprint size




mercredi 23 novembre 2011
Symmetric algorithms


                   • Shared secret key algorithm
                   • Same key used to cipher and decipher
                   • Fast algorithm


mercredi 23 novembre 2011
Popular symmetric
                               algorithms

                   • Advanced Encryption Standard
                   • Blowfish
                   • Digital Encryption Standard and 3DES


mercredi 23 novembre 2011
Popular symmetric
                               algorithms

                   • Advanced Encryption Standard
                   • Blowfish
                   • Digital Encryption Standard and 3DES
                                  @deprecated



mercredi 23 novembre 2011
Private message exchange




mercredi 23 novembre 2011
Private message exchange
                            Shared secret key




mercredi 23 novembre 2011
Private message exchange
                                 Shared secret key




                            Ciphering
                             with Ks



mercredi 23 novembre 2011
Private message exchange
                                 Shared secret key




                            Ciphering        Deciphering
                             with Ks          with Ks



mercredi 23 novembre 2011
Secret key exchange
                                  problem




mercredi 23 novembre 2011
Secret key exchange
                                   problem




                            High number of secret keys to manage !


mercredi 23 novembre 2011
Secret key exchange
                                   problem




                            High number of secret keys to manage !
                                 How to share the secret key ?
mercredi 23 novembre 2011
Asymmetric algorithm

                   • Key pair based algorithm
                   • Shared public key
                   • Protected private key
                   • Key size :1024 to 4096 bits
                   • Slow algorithm
                   • Max encryption size = key size
mercredi 23 novembre 2011
Popular asymmetric
                                  algorithm

                   • Rivest, Shamir and Adelman (signing and
                            encryption)
                   • Digital Signature Algorithm (signature
                            only)
                   • Elliptic Curves Cryptography

mercredi 23 novembre 2011
Asymmetric ciphering
                                 analogy




mercredi 23 novembre 2011
Asymmetric ciphering
                                 analogy
                                              Public key


                                                   Private key




mercredi 23 novembre 2011
Asymmetric ciphering
                                 analogy
                                              Public key


                                                   Private key




mercredi 23 novembre 2011
Asymmetric ciphering
                                 analogy
                                              Public key


                                                   Private key




mercredi 23 novembre 2011
Asymmetric ciphering
                                 analogy
                                              Public key


                                                   Private key




mercredi 23 novembre 2011
Asymmetric ciphering




mercredi 23 novembre 2011
Asymmetric ciphering




                                 Ciphering
                            with Bob Public Key



mercredi 23 novembre 2011
Asymmetric ciphering




                                                      Deciphering
                                 Ciphering        with Bob Private Key
                            with Bob Public Key



mercredi 23 novembre 2011
Digital signature




mercredi 23 novembre 2011
Digital signature




 dsa(hash(ˮHello.ˮ),PrK.alice


                              Alice sign with
   Only hash of the           her private key
   message is signed
mercredi 23 novembre 2011
Digital signature




mercredi 23 novembre 2011
Digital signature
                                          Unchanged hash means
                                            unaltered message




                                  compare hash("hello.")
                                          with :
                                dsa("er2f@!e..", PuK.alice)


                                          Bob checks signature
                                          with Alice public key
mercredi 23 novembre 2011
Diffie-Hellman
key exchange
  algorithm




mercredi 23 novembre 2011
Diffie-Hellman
key exchange
  algorithm




mercredi 23 novembre 2011
Diffie-Hellman
key exchange
  algorithm




mercredi 23 novembre 2011
Diffie-Hellman
key exchange
  algorithm




mercredi 23 novembre 2011
Diffie-Hellman
key exchange
  algorithm




mercredi 23 novembre 2011
Diffie-Hellman
key exchange
  algorithm




mercredi 23 novembre 2011
Diffie-Hellman
key exchange
  algorithm




mercredi 23 novembre 2011
Diffie-Hellman
key exchange
  algorithm




mercredi 23 novembre 2011
Public key sharing




mercredi 23 novembre 2011
Public key management


mercredi 23 novembre 2011
Public Key Infrastructure !



                   • Public key certificate
                   • Certificate management


mercredi 23 novembre 2011
Public key certificates
                   • Binds public key with Identity
                   • Can be used to :
                            •   authenticate a user

                            •   cipher data (email, communications ...)

                            •   prove identity (SSL)

                            •   signing a document

                            •   signing a certificate (CA certificate)

                            •   ...
mercredi 23 novembre 2011
Public key
   certificate
    anatomy
(TLS certificate)




mercredi 23 novembre 2011
Public key certificate anatomy -
                               Issuer




mercredi 23 novembre 2011
Public key certificate anatomy -
                               Issuer
 Issuer Distinguished Name




mercredi 23 novembre 2011
Public key certificate anatomy -
                               Issuer
 Issuer Distinguished Name




                    Issuer ≠ Subject :
                    • Not a CA certificate
                    • Not a self signed certificate


mercredi 23 novembre 2011
Public key certificate anatomy -
                           Subject




mercredi 23 novembre 2011
Public key certificate anatomy -
                           Subject
                                  Certificate validity




mercredi 23 novembre 2011
Public key certificate anatomy -
                           Subject
 Subject Distinguished Name       Certificate validity




mercredi 23 novembre 2011
Public key certificate anatomy -
                           Subject
 Subject Distinguished Name       Certificate validity




                                              Certified URL




mercredi 23 novembre 2011
Public key certificate anatomy -
                           Subject
 Subject Distinguished Name       Certificate validity




                                              Certified URL




                                          Public key


mercredi 23 novembre 2011
Public key certificate anatomy -
                         Extensions




mercredi 23 novembre 2011
Public key certificate anatomy -
                         Extensions
                            Not a CA certificate




mercredi 23 novembre 2011
Public key certificate anatomy -
                         Extensions
                            Not a CA certificate
                                            Revocation List




mercredi 23 novembre 2011
Public key certificate anatomy -
                         Extensions
                            Not a CA certificate
                                            Revocation List

                                                    Certificate usage (TLS)




mercredi 23 novembre 2011
Public key certificate anatomy -
                         Extensions
                            Not a CA certificate
                                            Revocation List

                                                    Certificate usage (TLS)




                                     Issuer CA certificate location



mercredi 23 novembre 2011
Public key certificate anatomy -
                 Certificate signature




mercredi 23 novembre 2011
Public key certificate anatomy -
                 Certificate signature




      The certificate SHA1 fingerprint is signed with Issuer
                          private key



mercredi 23 novembre 2011
Certificate fingerprint
                                    signature

                   • Self signed or signed by CA
                   • Prevents certificate corruption
                   • CA signing proves identity if the CA is
                            trusted




mercredi 23 novembre 2011
Certification chain of trust
                       (certification path)




mercredi 23 novembre 2011
Certificate management




mercredi 23 novembre 2011
Certificate management




mercredi 23 novembre 2011
Certificate management




mercredi 23 novembre 2011
Certificate management




mercredi 23 novembre 2011
Certificate management




mercredi 23 novembre 2011
Certificate management
                             CR is signed with
                              CA private key




mercredi 23 novembre 2011
Certificate management
                             CR is signed with
                              CA private key




mercredi 23 novembre 2011
Certificate management
                             CR is signed with
                              CA private key




mercredi 23 novembre 2011
Certificate management
                             CR is signed with
                              CA private key




mercredi 23 novembre 2011
Certificate management
                             CR is signed with   Manage CRL or OCSP
                              CA private key




mercredi 23 novembre 2011
Certificate management
                             CR is signed with   Manage CRL or OCSP
                              CA private key




mercredi 23 novembre 2011
Certificate management
                             CR is signed with   Manage CRL or OCSP
                              CA private key




                                                      Check Bob certificate
                                                       with CA certificate




mercredi 23 novembre 2011
Certificate management
                             CR is signed with   Manage CRL or OCSP
                              CA private key




                                                      Check Bob certificate
                                                       with CA certificate




mercredi 23 novembre 2011
Certificate management
                             CR is signed with   Manage CRL or OCSP
                              CA private key
                                                          Check Bob
                                                       certificate validity



                                                      Check Bob certificate
                                                       with CA certificate




mercredi 23 novembre 2011
Private key storage
                   • Password protected PKCS12 file
                   • Cryptographic token :
                            •   password protected

                            •   key pair generation (not possible to take the
                                private key out)

                            •   process asymmetric algorithms (RSA, DSA,
                                Diffie-Hellman ...)




mercredi 23 novembre 2011
Private key storage
                   • Password protected PKCS12 file
                   • Cryptographic token :
                            •   password protected

                            •   key pair generation (not possible to take the
                                private key out)

                            •   process asymmetric algorithms (RSA, DSA,
                                Diffie-Hellman ...)
               Two Factors Authentication :
     protect with something you know and something
                        you have
mercredi 23 novembre 2011
Certificate revocation

                   • Two protocols :
                            •   Certificate Revocation List

                            •   Online Certificate Status Protocol

                   • CRL provides a full certificates revocation
                            list
                   • OCSP is request/response protocol

mercredi 23 novembre 2011
One Time Password

                            • Token and password (PIN) based
                              authentication system
                            • Token uses a clock and a secret algorithm
                              to generate a OTP
                            • OTP server use the same algorithm to
                              validate the OTP



mercredi 23 novembre 2011
Conclusion


                            • What’s going on if you loose your
                              ciphering private key (or PKCS12
                              password) ?
                            • Are the Registration Authority validation
                              process safe ?




mercredi 23 novembre 2011

Mais conteúdo relacionado

Destaque (16)

Primero corporate presentation january 2012 rev
Primero corporate presentation january 2012 revPrimero corporate presentation january 2012 rev
Primero corporate presentation january 2012 rev
 
Jam muraずばっ! pdf
Jam muraずばっ! pdfJam muraずばっ! pdf
Jam muraずばっ! pdf
 
Vkontakte.ru
Vkontakte.ruVkontakte.ru
Vkontakte.ru
 
We didn't watch tv
We didn't watch tvWe didn't watch tv
We didn't watch tv
 
Media Pitch
Media Pitch Media Pitch
Media Pitch
 
Myocardial infarction
Myocardial infarctionMyocardial infarction
Myocardial infarction
 
Aneurisma della succlavia dissecato
Aneurisma della succlavia dissecatoAneurisma della succlavia dissecato
Aneurisma della succlavia dissecato
 
Pengatar si
Pengatar siPengatar si
Pengatar si
 
Brochure sbs
Brochure sbsBrochure sbs
Brochure sbs
 
電子書籍販売サイト「印刷の泉」について
電子書籍販売サイト「印刷の泉」について電子書籍販売サイト「印刷の泉」について
電子書籍販売サイト「印刷の泉」について
 
2012 world label awards presentation
2012 world label awards presentation2012 world label awards presentation
2012 world label awards presentation
 
Roles and function attacking defending roles22
Roles and function attacking defending roles22Roles and function attacking defending roles22
Roles and function attacking defending roles22
 
Tema para forooo
Tema para foroooTema para forooo
Tema para forooo
 
Sumes
SumesSumes
Sumes
 
Acquisition of Cerro Del Gallo
Acquisition of Cerro Del GalloAcquisition of Cerro Del Gallo
Acquisition of Cerro Del Gallo
 
Vroege renaissance
Vroege renaissanceVroege renaissance
Vroege renaissance
 

Mais de David Galichet (6)

Property Based Testing with ScalaCheck
Property Based Testing with ScalaCheckProperty Based Testing with ScalaCheck
Property Based Testing with ScalaCheck
 
Writing DSL with Applicative Functors
Writing DSL with Applicative FunctorsWriting DSL with Applicative Functors
Writing DSL with Applicative Functors
 
Introducing Monads and State Monad at PSUG
Introducing Monads and State Monad at PSUGIntroducing Monads and State Monad at PSUG
Introducing Monads and State Monad at PSUG
 
Playing with State Monad
Playing with State MonadPlaying with State Monad
Playing with State Monad
 
Demystifying Scala Type System
Demystifying Scala Type SystemDemystifying Scala Type System
Demystifying Scala Type System
 
Simple Build Tool
Simple Build ToolSimple Build Tool
Simple Build Tool
 

Último

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Último (20)

Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 

Crypto and PKI

  • 1. Introducing cryptography and PKI David Galichet mercredi 23 novembre 2011
  • 3. Authentication • Application authentication • Single Sign On • One Time Password • Remember me • ... mercredi 23 novembre 2011
  • 4. Integrity • Data are not corrupted • Data are not intentionally altered mercredi 23 novembre 2011
  • 5. Privacy • Protect data transfer • Protect stored data mercredi 23 novembre 2011
  • 6. Identity • Authentication (user and server side) • Signature (document, application packages ...) • Non repudiation • Trusted Timestamps • Anonymity (electronic vote, alternative currency ...) • ... mercredi 23 novembre 2011
  • 7. Cryptography basis • Hash functions • Symmetric ciphering • Asymmetric ciphering mercredi 23 novembre 2011
  • 8. Hash algorithms • Generate a constant size fingerprint whatever data in entry • It’s hard to find the message from the given hash (First Preimage Resistance) • It’s hard to modify a message without hash being changed (Second Preimage Resistance) • It’s hard to find two different messages with the same hash (Resistance to Collisions) • Very fast calculation mercredi 23 novembre 2011
  • 9. Cryptographic Hash algorithms • Generate a constant size fingerprint whatever data in entry infeasible • It’s hard to find the message from the given hash (First Preimage Resistance) infeasible • It’s hard to modify a message without hash being changed (Second Preimage Resistance) infeasible • It’s hard to find two different messages with the same hash (Resistance to Collisions) • Very fast calculation mercredi 23 novembre 2011
  • 10. Hash functions Integrity checking : hash() File 415a15b606eff4d4ba97ef64ecd2e598 mercredi 23 novembre 2011
  • 11. Hash functions Integrity checking : Fingerprint or checksum hash() File 415a15b606eff4d4ba97ef64ecd2e598 mercredi 23 novembre 2011
  • 12. Hash functions Integrity checking : Fingerprint or checksum hash() File 415a15b606eff4d4ba97ef64ecd2e598 Very low probability of collision ! Hard to change file without changing hash ! Fast algorithm ! mercredi 23 novembre 2011
  • 13. Hash functions Password encryption : hash() password 415a15b606eff4d4ba97ef64ecd2e598 mercredi 23 novembre 2011
  • 14. Hash functions Password encryption : hash() password 415a15b606eff4d4ba97ef64ecd2e598 Hard to calculate password from the hash ! mercredi 23 novembre 2011
  • 15. Hash functions Remember me tokens : username + expiration date + hash(password) hash() 415a15b606eff4d4ba97ef64ecd2e598 Remember me token = hash(...) + username + expiration date mercredi 23 novembre 2011
  • 16. Password hashing leaks • Brute force • Dictionary • Rainbow table mercredi 23 novembre 2011
  • 17. Password hashing leaks • Brute force • Dictionary • Rainbow table mercredi 23 novembre 2011
  • 18. Salted hash functions Salted hash password : hash() salt + password hash(salt+password) mercredi 23 novembre 2011
  • 19. Salted hash functions Salted hash password : hash() salt + password hash(salt+password) secret and / or user dependent mercredi 23 novembre 2011
  • 20. Salted hash functions Salted hash password : hash() salt + password hash(salt+password) secret and / or user dependent Prevents from dictionary and rainbow table attacks ! mercredi 23 novembre 2011
  • 21. Hash function algorithms • Message Digest 5 • 128 bits fingerprint size • Secured Hash Algorithm • many version (SHA1, SHA256 ...) • 160 to 512 bits fingerprint size mercredi 23 novembre 2011
  • 22. Hash function algorithms • Message Digest 5 @deprecated • 128 bits fingerprint size • Secured Hash Algorithm • many version (SHA1, SHA256 ...) • 160 to 512 bits fingerprint size mercredi 23 novembre 2011
  • 23. Symmetric algorithms • Shared secret key algorithm • Same key used to cipher and decipher • Fast algorithm mercredi 23 novembre 2011
  • 24. Popular symmetric algorithms • Advanced Encryption Standard • Blowfish • Digital Encryption Standard and 3DES mercredi 23 novembre 2011
  • 25. Popular symmetric algorithms • Advanced Encryption Standard • Blowfish • Digital Encryption Standard and 3DES @deprecated mercredi 23 novembre 2011
  • 27. Private message exchange Shared secret key mercredi 23 novembre 2011
  • 28. Private message exchange Shared secret key Ciphering with Ks mercredi 23 novembre 2011
  • 29. Private message exchange Shared secret key Ciphering Deciphering with Ks with Ks mercredi 23 novembre 2011
  • 30. Secret key exchange problem mercredi 23 novembre 2011
  • 31. Secret key exchange problem High number of secret keys to manage ! mercredi 23 novembre 2011
  • 32. Secret key exchange problem High number of secret keys to manage ! How to share the secret key ? mercredi 23 novembre 2011
  • 33. Asymmetric algorithm • Key pair based algorithm • Shared public key • Protected private key • Key size :1024 to 4096 bits • Slow algorithm • Max encryption size = key size mercredi 23 novembre 2011
  • 34. Popular asymmetric algorithm • Rivest, Shamir and Adelman (signing and encryption) • Digital Signature Algorithm (signature only) • Elliptic Curves Cryptography mercredi 23 novembre 2011
  • 35. Asymmetric ciphering analogy mercredi 23 novembre 2011
  • 36. Asymmetric ciphering analogy Public key Private key mercredi 23 novembre 2011
  • 37. Asymmetric ciphering analogy Public key Private key mercredi 23 novembre 2011
  • 38. Asymmetric ciphering analogy Public key Private key mercredi 23 novembre 2011
  • 39. Asymmetric ciphering analogy Public key Private key mercredi 23 novembre 2011
  • 41. Asymmetric ciphering Ciphering with Bob Public Key mercredi 23 novembre 2011
  • 42. Asymmetric ciphering Deciphering Ciphering with Bob Private Key with Bob Public Key mercredi 23 novembre 2011
  • 44. Digital signature dsa(hash(ˮHello.ˮ),PrK.alice Alice sign with Only hash of the her private key message is signed mercredi 23 novembre 2011
  • 46. Digital signature Unchanged hash means unaltered message compare hash("hello.") with : dsa("er2f@!e..", PuK.alice) Bob checks signature with Alice public key mercredi 23 novembre 2011
  • 47. Diffie-Hellman key exchange algorithm mercredi 23 novembre 2011
  • 48. Diffie-Hellman key exchange algorithm mercredi 23 novembre 2011
  • 49. Diffie-Hellman key exchange algorithm mercredi 23 novembre 2011
  • 50. Diffie-Hellman key exchange algorithm mercredi 23 novembre 2011
  • 51. Diffie-Hellman key exchange algorithm mercredi 23 novembre 2011
  • 52. Diffie-Hellman key exchange algorithm mercredi 23 novembre 2011
  • 53. Diffie-Hellman key exchange algorithm mercredi 23 novembre 2011
  • 54. Diffie-Hellman key exchange algorithm mercredi 23 novembre 2011
  • 55. Public key sharing mercredi 23 novembre 2011
  • 56. Public key management mercredi 23 novembre 2011
  • 57. Public Key Infrastructure ! • Public key certificate • Certificate management mercredi 23 novembre 2011
  • 58. Public key certificates • Binds public key with Identity • Can be used to : • authenticate a user • cipher data (email, communications ...) • prove identity (SSL) • signing a document • signing a certificate (CA certificate) • ... mercredi 23 novembre 2011
  • 59. Public key certificate anatomy (TLS certificate) mercredi 23 novembre 2011
  • 60. Public key certificate anatomy - Issuer mercredi 23 novembre 2011
  • 61. Public key certificate anatomy - Issuer Issuer Distinguished Name mercredi 23 novembre 2011
  • 62. Public key certificate anatomy - Issuer Issuer Distinguished Name Issuer ≠ Subject : • Not a CA certificate • Not a self signed certificate mercredi 23 novembre 2011
  • 63. Public key certificate anatomy - Subject mercredi 23 novembre 2011
  • 64. Public key certificate anatomy - Subject Certificate validity mercredi 23 novembre 2011
  • 65. Public key certificate anatomy - Subject Subject Distinguished Name Certificate validity mercredi 23 novembre 2011
  • 66. Public key certificate anatomy - Subject Subject Distinguished Name Certificate validity Certified URL mercredi 23 novembre 2011
  • 67. Public key certificate anatomy - Subject Subject Distinguished Name Certificate validity Certified URL Public key mercredi 23 novembre 2011
  • 68. Public key certificate anatomy - Extensions mercredi 23 novembre 2011
  • 69. Public key certificate anatomy - Extensions Not a CA certificate mercredi 23 novembre 2011
  • 70. Public key certificate anatomy - Extensions Not a CA certificate Revocation List mercredi 23 novembre 2011
  • 71. Public key certificate anatomy - Extensions Not a CA certificate Revocation List Certificate usage (TLS) mercredi 23 novembre 2011
  • 72. Public key certificate anatomy - Extensions Not a CA certificate Revocation List Certificate usage (TLS) Issuer CA certificate location mercredi 23 novembre 2011
  • 73. Public key certificate anatomy - Certificate signature mercredi 23 novembre 2011
  • 74. Public key certificate anatomy - Certificate signature The certificate SHA1 fingerprint is signed with Issuer private key mercredi 23 novembre 2011
  • 75. Certificate fingerprint signature • Self signed or signed by CA • Prevents certificate corruption • CA signing proves identity if the CA is trusted mercredi 23 novembre 2011
  • 76. Certification chain of trust (certification path) mercredi 23 novembre 2011
  • 82. Certificate management CR is signed with CA private key mercredi 23 novembre 2011
  • 83. Certificate management CR is signed with CA private key mercredi 23 novembre 2011
  • 84. Certificate management CR is signed with CA private key mercredi 23 novembre 2011
  • 85. Certificate management CR is signed with CA private key mercredi 23 novembre 2011
  • 86. Certificate management CR is signed with Manage CRL or OCSP CA private key mercredi 23 novembre 2011
  • 87. Certificate management CR is signed with Manage CRL or OCSP CA private key mercredi 23 novembre 2011
  • 88. Certificate management CR is signed with Manage CRL or OCSP CA private key Check Bob certificate with CA certificate mercredi 23 novembre 2011
  • 89. Certificate management CR is signed with Manage CRL or OCSP CA private key Check Bob certificate with CA certificate mercredi 23 novembre 2011
  • 90. Certificate management CR is signed with Manage CRL or OCSP CA private key Check Bob certificate validity Check Bob certificate with CA certificate mercredi 23 novembre 2011
  • 91. Private key storage • Password protected PKCS12 file • Cryptographic token : • password protected • key pair generation (not possible to take the private key out) • process asymmetric algorithms (RSA, DSA, Diffie-Hellman ...) mercredi 23 novembre 2011
  • 92. Private key storage • Password protected PKCS12 file • Cryptographic token : • password protected • key pair generation (not possible to take the private key out) • process asymmetric algorithms (RSA, DSA, Diffie-Hellman ...) Two Factors Authentication : protect with something you know and something you have mercredi 23 novembre 2011
  • 93. Certificate revocation • Two protocols : • Certificate Revocation List • Online Certificate Status Protocol • CRL provides a full certificates revocation list • OCSP is request/response protocol mercredi 23 novembre 2011
  • 94. One Time Password • Token and password (PIN) based authentication system • Token uses a clock and a secret algorithm to generate a OTP • OTP server use the same algorithm to validate the OTP mercredi 23 novembre 2011
  • 95. Conclusion • What’s going on if you loose your ciphering private key (or PKCS12 password) ? • Are the Registration Authority validation process safe ? mercredi 23 novembre 2011