Key Management and Identity CS461/ECE422 Spring 2012.

Slides:



Advertisements
Similar presentations
Chapter 14 – Authentication Applications
Advertisements

Authentication Applications. will consider authentication functions will consider authentication functions developed to support application-level authentication.
Key Management. Shared Key Exchange Problem How do Alice and Bob exchange a shared secret? Offline – Doesnt scale Using public key cryptography (possible)
Cryptography and Network Security Third Edition by William Stallings Lecture slides by Lawrie Brown.
CIS 725 Key Exchange Protocols. Alice ( PB Bob (M, PR Alice (hash(M))) PB Alice Confidentiality, Integrity and Authenication PR Bob M, hash(M) M, PR Alice.
Csci5233 Computer Security1 Bishop: Chapter 10 (Cont.) Key Management: Certificates.
Cryptography and Network Security Third Edition by William Stallings Lecture slides by Lawrie Brown.
Public Key Management and X.509 Certificates
Chapter 14 From Cryptography and Network Security Fourth Edition written by William Stallings, and Lecture slides by Lawrie Brown, the Australian Defence.
Authentication Cristian Solano. Cryptography is the science of using mathematics to encrypt and decrypt data. Public Key Cryptography –Problems with key.
Computer Security Key Management. Introduction We distinguish between a session key and a interchange key ( long term key ). The session key is associated.
Computer Security Key Management
CSCI283 Fall 2005 GWU All slides from Bishop’s slide set Public Key Infrastructure (PKI)
 Authorization via symmetric crypto  Key exchange o Using asymmetric crypto o Using symmetric crypto with KDC  KDC shares a key with every participant.
 Public key (asymmetric) cryptography o Modular exponentiation for encryption/decryption  Efficient algorithms for this o Attacker needs to factor large.
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 6 Wenbing Zhao Department of Electrical and Computer Engineering.
November 1, 2004Introduction to Computer Security ©2004 Matt Bishop Slide #9-1 Chapter 9: Key Management Session and Interchange Keys Key Exchange Cryptographic.
1 Digital Signatures CSSE 490 Computer Security Mark Ardis, Rose-Hulman Institute April 12, 2004.
Chapter 9: Key Management
1 Key Management CSSE 490 Computer Security Mark Ardis, Rose-Hulman Institute April 1, 2004.
More on AuthenticationCS-4513 D-term More on Authentication CS-4513 Distributed Computing Systems (Slides include materials from Operating System.
Computer Security1 Bishop: Chapter 9 Key Management.
Topic 11: Key Distribution and Agreement 1 Information Security CS 526 Topic 11: Key Distribution & Agreement, Secure Communication.
Slide #9-1 Chapter 9: Key Management Session and Interchange Keys Key Exchange Cryptographic Key Infrastructure Storing and Revoking Keys Digital Signatures.
Alexander Potapov.  Authentication definition  Protocol architectures  Cryptographic properties  Freshness  Types of attack on protocols  Two-way.
Computer Science Public Key Management Lecture 5.
Chapter 31 Network Security
Part Two Network Security Applications Chapter 4 Key Distribution and User Authentication.
Secure r How do you do it? m Need to worry about sniffing, modifying, end- user masquerading, replaying. m If sender and receiver have shared secret.
Cryptography and Network Security Chapter 14 Fifth Edition by William Stallings Lecture slides by Lawrie Brown.
Csci5233 Computer Security1 Bishop: Chapter 10 (Cont.) Key Management: Storage & Revoking.
Digital Signatures. Public Key Cryptography Public Key Cryptography Requirements 1.It must be computationally easy to encipher or decipher a message.
Certificate-Based Operations. Module Objectives By the end of this module participants will be able to: Define how cryptography is used to secure information.
1 Chapter 9: Key Management All algorithms we have introduced are based on one assumption: keys have been distributed. But how to do that? Key generation,
1 IS 2150 / TEL 2810 Introduction to Security James Joshi Assistant Professor, SIS Lecture 10 Nov 8, 2007 Hash Functions Key Management.
23-1 Last time □ P2P □ Security ♦ Intro ♦ Principles of cryptography.
1 Key Management CS461/ECE422 Fall Reading Handbook of Applied Cryptography
Network Security7-1 CIS3360: Chapter 8: Cryptography Application of Public Cryptography Cliff Zou Spring 2012 TexPoint fonts used in EMF. Read the TexPoint.
15.1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Key Management.
Authentication 3: On The Internet. 2 Readings URL attacks
Fall 2010/Lecture 321 CS 426 (Fall 2010) Key Distribution & Agreement.
Chapter 3 (B) – Key Management; Other Public Key Cryptosystems.
Courtesy of Professors Chris Clifton & Matt Bishop INFSCI 2935: Introduction of Computer Security1 Nov 4, 2003 Introduction to Computer Security Lecture.
Lecture 16: Security CDK4: Chapter 7 CDK5: Chapter 11 TvS: Chapter 9.
X.509 Topics PGP S/MIME Kerberos. Directory Authentication Framework X.509 is part of the ISO X.500 directory standard. used by S/MIME, SSL, IPSec, and.
31.1 Chapter 31 Network Security Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Topic 14: Secure Communication1 Information Security CS 526 Topic 14: Key Distribution & Agreement, Secure Communication.
Cryptography and Network Security Chapter 14 Fourth Edition by William Stallings Lecture slides by Lawrie Brown.
1 Chapter 10: Key Management in Public key cryptosystems Fourth Edition by William Stallings Lecture slides by Lawrie Brown (Modified by Prof. M. Singhal,
Security fundamentals Topic 5 Using a Public Key Infrastructure.
Network Security Continued. Digital Signature You want to sign a document. Three conditions. – 1. The receiver can verify the identity of the sender.
Computer and Network Security - Message Digests, Kerberos, PKI –
Csci5233 Computer Security1 Bishop: Chapter 10 Key Management.
Slide #9-1 Chapter 9: Key Management Session and Interchange Keys Key Exchange Cryptographic Key Infrastructure Storing and Revoking Keys Digital Signatures.
Lecture 9 Overview. Digital Signature Properties CS 450/650 Lecture 9: Digital Signatures 2 Unforgeable: Only the signer can produce his/her signature.
1IS2150/TEL2810: Introduction to Computer Security Nov 1, 2005 Introduction to Computer Security Lecture 8 Key Management.
Pertemuan #8 Key Management Kuliah Pengaman Jaringan.
Prof. Reuven Aviv, Nov 2013 Public Key Infrastructure1 Prof. Reuven Aviv Tel Hai Academic College Department of Computer Science Public Key Infrastructure.
Cryptography and Network Security Chapter 14 Fifth Edition by William Stallings Lecture slides by Lawrie Brown.
1 Key Management CS461/ECE422 Fall Reading Handbook of Applied Cryptography
Key management issues in PGP
Chapter 9. Key management
CS480 Cryptography and Information Security
Chapter 15 Key Management
Public Key Infrastructure
Public Key Infrastructure (PKI)
CDK4: Chapter 7 CDK5: Chapter 11 TvS: Chapter 9
Overview Key exchange Cryptographic key infrastructure Key storage
CDK: Chapter 7 TvS: Chapter 9
Chapter 9: Key Management
Presentation transcript:

Key Management and Identity CS461/ECE422 Spring 2012

Reading Material Chapters 2 and 23 from text Handbook of Applied Cryptography – – Chapter 5 for information on Pseudorandom sequences – Chapter 12 for Needham-Schroeder protocol The Gnu Privacy Handbook –

Overview Digital Signatures Key Exchange Key/Identity Management – Kerberos – PKI Hierarchical – X.509 Web of Trust

Digital Signatures Alice wants Bob to know that she sent message, m – Sends digital signature along with message – m || {h(m)}e A How would Bob verify signature? Could Eve intercept and change message? How does Bob know that Alice is the sender?

5 Session and Interchange Keys Long lived Interchange Keys only exist to boot strap Short lived session keys used for bulk encryption K b,K a K a,K b {K a,b }K a {m1}K a,b K a,b

6 Picking Good Session Keys Goal: generate keys that are difficult to guess Problem statement: given a set of K potential keys, choose one randomly – Equivalent to selecting a random number between 0 and K– 1 inclusive – Uniform distribution – Use entire space – Independence – Should not be able to predict next selection Why is this hard: generating random numbers – Actually, numbers are usually pseudo-random, that is, generated by an algorithm

7 What is “Random”? Sequence of cryptographically random numbers: a sequence of numbers n 1, n 2, … such that for any integer k > 0, an observer cannot predict n k even if all of n 1, …, n k–1 are known – Best: physical source of randomness Random pulses Electromagnetic phenomena Characteristics of computing environment such as disk latency Ambient background noise

8 What is “Pseudorandom”? Sequence of cryptographically pseudorandom numbers: sequence of numbers intended to simulate a sequence of cryptographically random numbers but generated by an algorithm – Very difficult to do this well Linear congruential generators [n k = (an k–1 + b) mod n] broken Polynomial congruential generators [n k = (a j n k–1 j + … + a 1 n k–1 a 0 ) mod n] broken too Here, “broken” means next number in sequence can be determined

9 Best Pseudorandom Numbers Strong mixing function: function of 2 or more inputs with each bit of output depending on some nonlinear function of all input bits – Examples: DES, MD5, SHA-1, avalanche effect – Use on UNIX-based systems: (date; ps gaux) | md5 where “ps gaux” lists all information about all processes on system

10 Separate Channel Ideally you have separate secure channel for exchanging Interchange keys – Direct secret sharing grows at N 2 Telephone, separate data network, ESP, sneaker net Regular data network

11 Shared Channel: Trusted Third Party Generally separate channel is not practical – No trustworthy separate channel – Want to scale linearly with additional users Regular data network Key Exchange K A,K B, … K Z KAKA KBKB

12 Classical Key Exchange Bootstrap problem: how do Alice, Bob begin? – Alice can’t send it to Bob in the clear! Assume trusted third party, Cathy – Alice and Cathy share secret key k A – Bob and Cathy share secret key k B Use this to exchange shared key k s

13 Simple Protocol Alice Cathy { request for session key to Bob } k A Alice Cathy { k s } k A || { k s } k B Alice Bob { k s } k B Eve Bob { k s } k B

14 Problems How does Bob know he is talking to Alice? – Replay attack: Eve records message from Alice to Bob, later replays it; Bob may think he’s talking to Alice, but he isn’t – Session key reuse: Eve replays message from Alice to Bob, so Bob re-uses session key Protocols must provide authentication and defense against replay

Needham-Schroeder Alice Cathy Alice||Bob||R1 Alice Cathy {Alice||Bob||r1||k s {Alice|| k s } k B } k A Alice Bob {Alice|| k s } k B BobAlice {r2}k s BobAlice {r2-1}k s

16 Argument: Alice talking to Bob Second message – Encrypted using key only she, Cathy knows So Cathy encrypted it – Response to first message As r 1 in it matches r 1 in first message Third message – Alice knows only Bob can read it As only Bob can derive session key from message – Any messages encrypted with that key are from Bob

17 Argument: Bob talking to Alice Third message – Encrypted using key only he, Cathy know So Cathy encrypted it – Names Alice, session key Cathy provided session key, says Alice is other party Fourth message – Uses session key to determine if it is replay from Eve If not, Alice will respond correctly in fifth message If so, Eve can’t decrypt r 2 and so can’t respond, or responds incorrectly

Kerberos

19 Kerberos Authentication system – Based on Needham-Schroeder with Denning-Sacco modification – Central server plays role of trusted third party (“Cathy”) Ticket – Issuer vouches for identity of requester of service Authenticator – Identifies sender Two Competing Versions: 4 and 5 – Version 4 discussed here

20 Idea User u authenticates to Kerberos AS – Obtains ticket (TGT) T u,TGS for ticket granting service (TGS) User u wants to use service s: – User sends authenticator A u, ticket T u,TGS to TGS asking for ticket for service – TGS sends ticket T u,s to user – User sends A u, T u,s to server as request to use s Details follow

21 Ticket Credential saying issuer has identified ticket requester Example ticket issued to user u for TGS T u,TGS = TGS || { u || u’s address || valid time || k u,TGS } k AS,TGS where: – k u,TGS is session key for user and TGS – k AS,TGS is long-term key shared between AS and TGS – Valid time is interval for which ticket valid; e.g., a day – u’s address may be IP address or something else Note: more fields, but not relevant here

22 Ticket Example ticket issued to user u for service s T u,s = s || { u || u’s address || valid time || k u,s } k s where: – k u,s is session key for user and service – k s is long-term key shared between TGS and S – Valid time is interval for which ticket valid; e.g., hours/days – u’s address may be IP address or something else Note: more fields, but not relevant here

23 Authenticator Credential containing identity of sender of ticket – Used to confirm sender is entity to which ticket was issued Example: authenticator user u generates for service s A u,s = { u || generation time} k u,s where: – Generation time is when authenticator generated Note: more fields, not relevant here

24 Protocol M1: user/ws AS [AS_REQ]: user || TGS M2: user/wsAS [AS_REP]: { k u,TGS } k u || T u,TGS * Initially, user u registers with KDC and establishes a password - used to derive long-term key k u * User U logs into workstation (WS) using password * WS decrypts session key k u,TGS using supplied password

25 Protocol M3: user/wsTGS [TGS_REQ]: service || A u,TGS || T u,TGS M4: user/wsTGS [TGS_REP]: user || { k u,s } k u,TGS || T u,s M5: user/wsservice [AP_REQ]: A u,s || T u,s M6: user/wsservice [AP_REP]: { t + 1 } k u,s * TGS decrypts ticket using long-term key k AS,TGS * Service decrypts ticket using long-term key k TGS,s

26 Summary of Messages First two messages get user ticket to use TGS – User u can obtain session key only if u knows key shared with AS Next four messages show how u gets and uses ticket for service s – Service s validates request by checking sender (using A u,s ) is same as entity ticket issued to – Step 6 optional; used when u requests confirmation

Public Key: key exchange Bob picks session key, k session Encrypts it with Alice’s public key e A Sends to Alice Problems? {k session }e A

28 Problem and Solution Vulnerable to forgery or replay – Because e A known to anyone, Alice has no assurance that Bob sent message Simple fix uses Bob’s private key – k s is desired session key – Are we ok now? {{k session }d B }e A {{k session } e A }d B

29 Notes Can include message enciphered with k s Assumes Alice has Bob’s public key, and vice versa – If not, each must get it from public server – If keys not bound to identity of owner, attacker Eve can launch a man-in-the-middle attack (next slide; Cathy is public server providing public keys) Solution to this (binding identity to keys) discussed later as public key infrastructure (PKI)

30 Man-in-the-Middle Attack AliceCathy Send Bob’s public key Eve Cathy send Bob’s public key Eve Cathy eBeB Alice eEeE Eve Alice Bob { k s } e E Eve Bob { k s } e B Eve intercepts request Eve intercepts message

31 Cryptographic Key Infrastructure Goal: bind identity to key Classical: not possible as all keys are shared – Use protocols to agree on a shared key (see earlier) Public key: bind identity to public key – Crucial as people will use key to communicate with principal whose identity is bound to key – Erroneous binding means no secrecy between principals – Assume principal identified by an acceptable name

32 Certificates Create token (message) containing – Identity of principal (here, Alice) – Corresponding public key – Timestamp (when issued) – Other information (perhaps identity of signer) – Compute hash (message digest) of token Hash encrypted by trusted authority (here, Cathy) using private key: called a “signature” C A = e A || Alice || T || {h(e A || Alice || T )} d C

33 X.509 Certificates Some certificate components in X.509v3: – Version – Serial number – Signature algorithm identifier: hash algorithm – Issuer’s name; uniquely identifies issuer – Interval of validity – Subject’s name; uniquely identifies subject – Subject’s public key – Signature: encrypted hash

34 Use Bob gets Alice’s certificate – If he knows Cathy’s public key, he can validate the certificate Decrypt encrypted hash using Cathy’s public key Re-compute hash from certificate and compare Check validity Is the principal Alice? – Now Bob has Alice’s public key Problem: Bob needs Cathy’s public key to validate certificate – That is, secure distribution of public keys – Solution: Public Key Infrastructure (PKI) using trust anchors called Certificate Authorities (CAs) that issue certificates

PKI Trust Models Single Global CA – Unmanageable – Who is the universally trusted root? Hierarchical CA – Tree of CA’s – But still need to be rooted somewhere

36 PKI Trust Models Hierarchical CAs with cross-certification – Multiple root CAs that are cross-certified – Cross-certification at lower levels for efficiency Web Model – Browsers come pre-configured with multiple trust anchor certificates – New certificates can be added Distributed (e.g., PGP) – No CA; instead, users certify each other to build a “web of trust”

37 Validation and Cross-Certifying Alice’s CA is Cathy; Bob’s CA is Don; how can Alice validate Bob’s certificate? – Have Cathy and Don cross-certify – Each issues certificate for the other Certificates: – Cathy > – Dan – Cathy > – Dan > Alice validates Bob’s certificate – Alice obtains Cathy > – Alice uses (known) public key of Cathy to validate Cathy > – Alice uses Cathy > to validate Dan >

38 PGP Chains OpenPGP certificates structured into packets – One public key packet – Zero or more signature packets Public key packet: – Version (3 or 4; 3 compatible with all versions of PGP, 4 not compatible with older versions of PGP) – Creation time – Validity period (not present in version 3) – Public key algorithm, associated parameters – Public key

39 OpenPGP Signature Packet Version 3 signature packet – Version (3) – Signature type (level of trust) – Creation time (when next fields hashed) – Signer’s key identifier (identifies key to encrypt hash) – Public key algorithm (used to encrypt hash) – Hash algorithm – Part of signed hash (used for quick check) – Signature (encrypted hash) Version 4 packet more complex

40 Signing Single certificate may have multiple signatures Notion of “trust” embedded in each signature – Range from “untrusted” to “ultimate trust” – Signer defines meaning of trust level (no standards!) – Few implementations support this All version 4 keys signed by subject – Called “self-signing”

41 Trust in GPG Owner Trust GPG enables assignment of trust in entity Unknown, Not Trusted, Marginal, Full How much do you trusted signatures by that entity Key Validity How much do you trust that the key corresponds to the owner? Unknown, Not trusted, Marginal Full Configurable X full paths or Y marginal paths

42 Web of Trust Example From GPG manual, arrows show key signatures

43 Web of Trust Scenarios In all cases the key is valid given 1 full or 2 marginal paths. Always fully trust directly signed keys Fully Trust Dharma Marginally Trust Dharma and Blake Marginally Trust Dharma and Chloe Marginally Trust Dharma, Blake, and Chloe Fully Trust Blake, Chloe, and Elena

44 Key Revocation Certificates invalidated before expiration – Usually due to compromised key – May be due to change in circumstance (e.g., someone leaving company) Problems – Verify that entity revoking certificate authorized to do so – Revocation information circulates to everyone fast enough Network delays, infrastructure problems may delay information

45 GPG: Revocation Certificate Use the –gen-revoke option to create a revocation certification. When you suspect that your certificate has been compromised Send revocation certificate to all your friends Or send the revocation certificate to a GPG key server

46 CRLs Certificate revocation list lists certificates that are revoked X.509: only certificate issuer can revoke certificate – Added to CRL

Recent Root Certificate Issues Vast numbers of Root certifiers in web browsers How strenuous is the background check of the certificate providers? How strong is the internal security of the certificate providers? What goes wrong with bad root certificates appear?

Network Perspectives Ask several notifiers throughout the network what they get for the target server’s certificate.

Summary Tracking identity is important – Key negotiation – Digital signatures Managing the root of trust is a very hard practical problem