Encryption

W
Shared by: huanglianjiang1
Categories
Tags
-
Stats
views:
10
posted:
11/20/2011
language:
English
pages:
18
Document Sample
scope of work template
							Encryption

An Overview
         Fundamental problems
• Internet traffic goes through many networks and
  routers
• Many of those networks are broadcast media
• Sniffing allows for many to
  – see transmissions
  – Tamper/alter transmission
  – Spoof identities
             Security Issues
• Eavesdropping
• Tampering
• Impersonation
  – Spoofing
  – misrepresentation
               General Areas
•   Encryption/Decryption
•   Indentification/Authentication
•   Authorization
•   Tamper Detection
•   Nonrepudiation
•   Example using SSL
•   Example using SSH
          Private Key Encryption


          Encryption     Encrypted      Decryption
Message                                 Algorithm     Message
          Algorithm      Message



          PrivateKey                     PrivateKey

          Key distribution/Protection is Critical!
             Public Key Encryption


             Encryption     Encrypted      Decryption
Message                                    Algorithm      Message
             Algorithm      Message



             PublicKey                     PrivateKey

          Public Key distribution/Protection is NOT Critical!
             Only the Private Key will enable decryption
    Public Key Encryption - reverse
     Process is symmetric in the sense that private-encrypted
         can also ONLY be decoded with the public key




              Encryption      Encrypted     Decryption
Message                                     Algorithm       Message
              Algorithm       Message




             PrivateKey                     PublicKey
                    Use you own private key to encrypt
          Let others have your public key.. No one can spoof you
         Encryption/Decryption
              Algorithm
• Private or public key
• Size of key
   – Harder to break/decipher
   – Key strength also related to algorthm
   – 128bit private stronger than 128bit public
• Time Life of the key
   – Crackable in a month, change every day
• Time to calculate
   – Impact on communication delays
   – Private-key faster than public key techniques
      Lots of Algorithms in use
•   DES
•   DSA
•   MD5
•   RC2 and RC4
•   RSA
•   SHA
•   SKIPJACK
   Identification/Authentication
• Certificate from Certificate Authorities
• Key is to trust the CA agency.
• If two parties trust different CA agencies but
  the two trust each other, a hierarchical trust
  relationship can exist.
• Problem scenario
  – Bill publishes his public key for others (Mary)
  – Bob publishes a public key posing as Bill
  – Only a trusted CA can verify that Bill’s public
    key is really from Bill
  – Bill includes a digitally signed certificate from a
    CA attesting to the public key
             Public Key Certificate
               (Bill <--> Mary)
                                                  CA Agency
                                                  Private Key
  User Public key

   Identity (Bill)          Signing Process


                                                MARY
        CA Agency                               MUST
        Public Key                              TRUST
                                                 CA
                      Mary
Accept or reject     Decrypts     Digital Signature
               Digital Signature
               Tamper Detection
 Message                 Hash Algorithm
 (maybe big)                 (MD5)



 Encrypted                Hash Value
 Hash Value                                    Encrypt Hash
                                                  (RSA)
                           Private key




Send to receiver… checks by decrypting the hash with public key..
Small data to encrypt .. Detects tampering w/o encoding whole mesg.
             Authorization
• Often overlooked
• Not encryption but related
• Once authenticated, is this person actually
  authorized, have the rights and permissions,
  to do what this user is asking.
             Nonrepudiation
• When using an electronic signature
• Can the person deny it actually came from
  them
• Digital signatures are legal
• For public/private key encryption, the only
  way that the signature could be invalid is if
  the private key was made public.
                      SSL
• Rides over the transport layer
• Uses certificates for authentication
  – Server authentication
  – Optionally client authentication
  – BROWSER must tust CA
• Sets up the communication using public-
  private keys to negotiate and establish
  symmetric private keys
• Send rest of communication encrypted
           SSL handshake from docs.sun.com
1.    The client sends the server the client's SSL version number, cipher settings, randomly generated data, and other
      information the server needs to communicate with the client using SSL.
2.    The server sends the client the server's SSL version number, cipher settings, randomly generated data, and other
      information the client needs to communicate with the server over SSL. The server also sends its own certificate and, if the
      client is requesting a server resource that requires client authentication, requests the client's certificate.
3.    The client uses some of the information sent by the server to authenticate the server (see Server Authentication for
      details). If the server cannot be authenticated, the user is warned of the problem and informed that an encrypted and
      authenticated connection cannot be established. If the server can be successfully authenticated, the client goes on to
      Step 4.
4.    Using all data generated in the handshake so far, the client (with the cooperation of the server, depending on the cipher
      being used) creates the premaster secret for the session, encrypts it with the server's public key (obtained from the
      server's certificate, sent in Step 2), and sends the encrypted premaster secret to the server.
5.    If the server has requested client authentication (an optional step in the handshake), the client also signs another piece of
      data that is unique to this handshake and known by both the client and server. In this case the client sends both the
      signed data and the client's own certificate to the server along with the encrypted premaster secret.
6.    If the server has requested client authentication, the server attempts to authenticate the client (see Client Authentication
      for details). If the client cannot be authenticated, the session is terminated. If the client can be successfully authenticated,
      the server uses its private key to decrypt the premaster secret, then performs a series of steps (which the client also
      performs, starting from the same premaster secret) to generate the master secret.
7.    Both the client and the server use the master secret to generate the session keys, which are symmetric keys used to
      encrypt and decrypt information exchanged during the SSL session and to verify its integrity--that is, to detect any
      changes in the data between the time it was sent and the time it is received over the SSL connection.
8.    The client sends a message to the server informing it that future messages from the client will be encrypted with the
      session key. It then sends a separate (encrypted) message indicating that the client portion of the handshake is finished.
9.    The server sends a message to the client informing it that future messages from the server will be encrypted with the
      session key. It then sends a separate (encrypted) message indicating that the server portion of the handshake is finished.
10.   The SSL handshake is now complete, and the SSL session has begun. The client and the server use the session keys to
      encrypt and decrypt the data they send to each other and to validate its integrity.
Typical Client check of SERVER CA
                        (from docs.sun.com)




Client CA check is similar
                           SSH
• Much simpler
• Server contacts the client and asks if the client will
  accept the public key as authentic
   – Only server can decrypt
• Client says yes.
• All is done.
• Client can authenticate different ways
   – Typically just with password.
• Negotiate a symmetric private key for the session

						
Related docs
Other docs by huanglianjiang1
9999
Views: 577  |  Downloads: 0
99977_1_Assignment-title
Views: 349  |  Downloads: 0
97600
Views: 228  |  Downloads: 0
9711 QUIZ
Views: 573  |  Downloads: 0
91712
Views: 196  |  Downloads: 0
96132.100.01.1_8500 to 8600 Upgrade Manual
Views: 329  |  Downloads: 0
9425f2a1-8439-4e5a-98f7-8d6d853f0158
Views: 258  |  Downloads: 0
92612-SAC-Summary
Views: 183  |  Downloads: 0
9121 - Bid Tabulations
Views: 836  |  Downloads: 0
91006
Views: 165  |  Downloads: 0