100 likes | 188 Views
Encryption / Security. Victor Norman IS333 / CS332 Spring 2014. Problem. Need to be able to do secure transactions across a public network. The data in the message needs to be encrypted so that no “man-in-the-middle” can intercept it.
E N D
Encryption / Security Victor Norman IS333 / CS332 Spring 2014
Problem • Need to be able to do secure transactions across a public network. • The data in the message needs to be encrypted so that no “man-in-the-middle” can intercept it. • Each endpoint needs to be able to authenticate that the other endpoint is who it says it is.
Terminology • Plaintext • Cyphertext • Encryption key • Decryption key • Asymmetric encryption
Public Key Encryption • Each network “entity” generates a pair of keys – a private key and public key. • The private key is never shared. The public key is shared. • The private key can decrypt a message encrypted with the public key, and vice versa.
PKE and Security • Can use public and private keys to get security problem: • sender gets the receiver’s public key. • sender encrypts the message with it, and sends to receiver (as cyphertext). • receiver decrypts with own private key. • Anyone can encrypt, but only the receiver can decrypt. • First problem solved.
Digital Signatures • Ensure some message is from who they say it is from. • Use own private key to encrypt message. • Only your public key can be used to decrypt • So, message must be from you.
Combine them both • To ensure privacy and authentication, combine both techniques: • 1. encrypt plaintext with sender private key. • 2. encrypt result with receiver public key. • 3. send message. • All problems solved! • Not!
One more problem… • Before all this, each endpoint has to get the other endpoint’s public key. • What if someone in the middle intercepts the request and sends its public key as if it were the other endpoint’s public key. • Need a way to know that an endpoint’s public key really belongs to that endpoint. • Need a CA – Certificate Authority.
Certificate Authority • A state-certified repository for network entities’ public keys. • Has its own public key, too. • Its location is built into web browsers • Sender sends message to CA encrypted with CA’s public key, asking for other endpoint’s public key. • Only the endpoints can decrypt, so message is secure. • Receiver’s public key is guaranteed to be authentic, if the CA can be trusted.