Lect 1
Lect 1
CO3099/7099
Part I: Cryptography (Stanley Fung, weeks 1-5)
Cryptography and Internet
http://java.sun.com/products/jce/
Assessment:
40% coursework (4)
60% final exam
Stanley Fung
University of Leicester
Module Part I
Objectives:
Chapter 1
Concepts: goals of cryptography (confidentiality,
authentication, integrity) and the mechanisms to achieve
them Basic Concepts
Practice: writing real Java programs for cryptography
Topics:
Basic concepts in cryptography
Secret and public key systems
Classical ciphers
Message digests and MAC
Digital signatures and certificates
Modern encryption and decryption Once upon a time, there were
Applications of Cryptography two people, Alice and Bob…
3
Security vs. Cryptography Three Main Security Issues
What is security? Confidentiality: keeping information secret
Protect systems against inappropriate use. Examples: Example: prevent people reading data on your disk, or
intercept messages transmitted over the network
Withdraw money from someone else’s account
5 6
9 10
11 12
A Puzzle A Possible Solution
Bob wants to send a diamond ring to Alice Bob puts the diamond ring inside the box, locks and
Only way of communication is postal mail sends it
However, postal mail is not secure: anything in the mail will Bob
be stolen, if not locked
They each have some locks (and matching keys), but do not Alice receives the box, puts another lock on it and
have keys that match the other person’s locks sends the double-locked box back to Bob
Solutions? Alice
Bob locks the ring inside a box and sends it. But Alice does
not have the key… Bob removes his lock and sends the (still locked) box
Bob sends the key. But it will be stolen… to Alice
Bob sends the key inside another locked box. But Alice does Bob
not have the key to this other box…
Is there even a solution? Alice opens her lock and gets the ring
Alice
13 14
15 16
Properties of Public and Private Keys Hybrid Systems
We need the following mathematical properties: Combines symmetric and asymmetric ciphers
Easy to generate a pair of public/private keys
First, the two parties use an asymmetric cipher to
Easy to encrypt knowing the public key
negotiate a session key (a secret key for this
17 18
19 20
Types of Cryptanalysis Attacks Summary
Ciphertext-only: only have (a large amount of) Confidentiality, integrity, authentication
encrypted data Two types of cryptography:
Example: Sgd pthbj aqnvm enw itlor nudq sgd kzyx cnf =?
Secret key cryptography Public key cryptography
Known plaintext: in addition, some plaintext-ciphertext Keys One per pair of user Two per user (public and
pairs are known (secret key) private)
Example: Sgd = The, cnf = dog, pthbj aqnvm enw = ? En/decryption Use same key Use different keys
Email headers, guessed keywords in message, etc Advantages Fast Avoid secret information
distribution
Chosen plaintext: attacker can choose to encrypt a
few plaintext
Example: Encrypt “Example”? => Dwzlokd