Computer and Network Security - Message Digests, Kerberos, PKI –

17
Computer and Network Computer and Network Security Security - Message Digests, - Message Digests, Kerberos, PKI – Kerberos, PKI –

Transcript of Computer and Network Security - Message Digests, Kerberos, PKI –

Page 1: Computer and Network Security - Message Digests, Kerberos, PKI –

Computer and Network SecurityComputer and Network Security- Message Digests, Kerberos, PKI - Message Digests, Kerberos, PKI

––

Computer and Network SecurityComputer and Network Security- Message Digests, Kerberos, PKI - Message Digests, Kerberos, PKI

––

Page 2: Computer and Network Security - Message Digests, Kerberos, PKI –

Course textbookReferences:

Kaufman, C., Perlman, R. and Speciner, M., Network Security (Private Communication in a Public World), 2nd edition, Prentice Hall 2002.

William Stalling, Cryptography and Network Security, 2nd edition, Prentice Hall 1999.

Class notes: Computer Security, Pennsylvania State University http://www.cse.psu.edu/~cg543/

Page 3: Computer and Network Security - Message Digests, Kerberos, PKI –

Message Digests

Computationally expensive to public-key-encrypt long messages

Goal: fixed-length,easy to compute digital signature, “fingerprint”

• apply hash function H to m, get fixed size message digest, H(m).

Hash function properties:• Many-to-1• Produces fixed-size msg

digest (fingerprint)• Given message digest x,

computationally infeasible to find m such that x = H(m)

• computationally infeasible to find any two messages m and m’ such that H(m) = H(m’).

Page 4: Computer and Network Security - Message Digests, Kerberos, PKI –

Digital signature = Signed message digest

Bob sends digitally signed message:

Alice verifies signature and integrity of digitally signed message:

Page 5: Computer and Network Security - Message Digests, Kerberos, PKI –

Hash Function Algorithms

• Internet checksum would make a poor message digest.– Too easy to find

two messages with same checksum.

• MD5 hash function widely used. – Computes 128-bit

message digest in 4-step process.

– arbitrary 128-bit string x, appears difficult to construct msg m whose MD5 hash is equal to x.

• SHA-1 is also used.– US standard– 160-bit message digest

Page 6: Computer and Network Security - Message Digests, Kerberos, PKI –

Trusted Intermediaries

Problem:– How do two entities

establish shared secret key over network?

Solution:– trusted key

distribution center (KDC) acting as intermediary between entities

Problem:– When Alice obtains

Bob’s public key (from web site, e-mail, diskette), how does she know it is Bob’s public key, not Trudy’s?

Solution:– trusted certification

authority (CA)

Page 7: Computer and Network Security - Message Digests, Kerberos, PKI –

Trusted Key Distribution Center (KDC)

• Keberos– Key Distribution Center– Ticket Granting Server

Page 8: Computer and Network Security - Message Digests, Kerberos, PKI –

Keberos• Kerberos authenticates users.

– Authentication: Assessing identity of users

• Most widely used centralized password system

• Now: part of Windows 2K, XP network authentication

Page 9: Computer and Network Security - Message Digests, Kerberos, PKI –

The setup of Kerberos• The players

– Principal - person being authenticated– Service - entity performing authentication– Key Distribution Center (KDC)

• Trusted third party for key distribution• Each principal and service has a Kerberos password

known to KDC– Ticket granting server

• Server granting transient authentication

• The objectives– Authenticate Alice (Principal) to Bob (Service)– Negotiate a symmetric (secret) session key kAB

Page 10: Computer and Network Security - Message Digests, Kerberos, PKI –

Key Distribution Center (KDC)

• Alice,Bob need shared symmetric key.

• KDC: server shares different secret key with each registered user.

• Alice, Bob know own symmetric keys, KA-

KDC KB-KDC , for communicating with KDC.

• Alice communicates with KDC, gets session key R1, and KB-KDC(A,R1)

• Alice sends Bob KB-KDC(A,R1), Bob extracts R1

• Alice, Bob now share the symmetric key R1.

Page 11: Computer and Network Security - Message Digests, Kerberos, PKI –

Kerberos Ticket• Bob’s Ticket KA-KDC(R1, KB-KDC(A,R1))

contains– Alice’s identity– The session key (R1)

– Only Alice and KDC can open KA-KDC(R1, KB-KDC(A,R1))

– Only Bob and KDC can open KB-KDC(A,R1).

Page 12: Computer and Network Security - Message Digests, Kerberos, PKI –

Trusted Certificate Authorities (CA)

• Public Key Infrastructure– Public Key Cryptography– CA (Certificate Authorities)

Page 13: Computer and Network Security - Message Digests, Kerberos, PKI –

What is Certificate?• A certificate …

– … makes an association between a user

• identity/job/attribute and a private key– … contains public key information {e,n}– … has a validity period– … is signed by some certificate authority (CA)

• Issued by CA for some purpose– Verisign is in the business of issuing certificates– People trust Verisign to vet identity

Page 14: Computer and Network Security - Message Digests, Kerberos, PKI –

Certification Authorities• Certification authority

(CA) binds public key to particular entity.

• Entity (person, router, etc.) can register its public key with CA.– Entity provides “proof

of identity” to CA. – CA creates certificate

binding entity to public key.

– Certificate digitally signed by CA.

• When Alice wants Bob’s public key:

• gets Bob’s certificate (Bob or elsewhere).

• Apply CA’s public key to Bob’s certificate, get Bob’s public key

Page 15: Computer and Network Security - Message Digests, Kerberos, PKI –

Diffie-Hellman Key Exchange

• Given– p: Prime number– g: g < p, prime root of p

{g1 mod p, g2 mod p, g3 mod p,…, gp-1 mod p}= {1, 2, 3, 4, …, p-1}

Page 16: Computer and Network Security - Message Digests, Kerberos, PKI –

Diffie-HellmanAlice Bob

S1.1 choose random RA choose random RB

---------------------------------------------------------------------------------------------------------------------

S1.2 compute compute

-----------------------------------------------------------------------------------------------------------------

S1.3 A B : QA B A : QB

---------------------------------------------------------------------------------------------------------------------

S1.4 compute compute

pgQ ARA mod

pQK ARB mod pQK BR

A mod

pgQ BRB mod

Page 17: Computer and Network Security - Message Digests, Kerberos, PKI –

So far, we talked about Basic Techniques of Security…

• Those are used in many different security scenarios– secure email– secure transport (SSL)– IPsec