View my presentation slides

Encryption
and
Cryptography
Overview
• What are cryptography, encryption, and
decryption & how do they relate to each
other?
• Why the need for cryptography emerged
• Cryptography in history
• Some basic types of encryption methods
• Why do we need cryptography TODAY?
• How does computer science play into all
of this?
•
Problems encountered in the fields of
encryption and cryptography
What are cryptography, encryption and
decryption?
• Cryptography
“Practice and study of hiding information.” (Wikipedia)
o “Science of using mathematics to encrypt & decrypt
data.” (Introduction to Cryptography)
o
Why did the need for
cryptography arise?
To protect messages getting into the
wrong hands:
Head of state
Military leaders
/generals
(sends message to)
(message gets intercepted!)
Enemy/spies
WAR
!
Cryptography in history
• Julius Caesar
• Mary, Queen of Scots (16th Century
England)
• Zimmermann telegram
• Enigma & Bombe
• Lorenz & Colossus
Some basic examples of cryptography
• Transposition cipher
ETH TKIECHN OFLOR
THE KITCHEN FLOOR
• Book cipher(pg 60, MacKay)
WE NEED EXTRA POWER
12,2,18,11,21,6,21,7
• Mono-alphabetic substitution cipher (+1)
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
Z A B C D E F G H I J K L M N O P Q R S T U V W X Y
1 2 3 4 5 6 7 8 9 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6
SGD LHSBGDM EKNNQ
20,8,5; 11,9,20,3,8,5,14;
6,12,16,16,19
Complexity in substitution ciphers
• Caesar shift (+3): QEB HFQZBK CILLO
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
X
Y
Z
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
Shift(A) + Shift(B) = Shift(A + B)
SGD LHSBGDM EKNNQ (+1)
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
Y
Z
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
QEB HFQZBK CILLO (+2)
Complexity in substitution ciphers
• Vigenère cipher(polyalphabetic):
ATTACKATDAWN (TEXT)
LEMON (KEY)
LXFOPVEFRNHR
Governments
still send
sensitive
information
today
E-Commerce
So why do we need
cryptography today?
Internet
Television
ATMs/banking
So where does CS come into all of this?
Symmetric cryptosystem*
Symmetric cryptosystems (single key)
Encrypting key is same as decrypting key
y = Fe (x)
x = Fe (y)
*cryptosystem = cryptographic algorithm/cipher
Symmetric encryption
BLOCK CIPHER – plaintext into blocks of fixed size (64
/ 128 bits). Encryption algorithm takes (x) plaintext
and outputs as ciphertext (y). The key k also consists
of a block of bits
y = Ek(x)
•Block encryption algorithms must possess
avalanche effect
• They must be non-linear
STREAM CIPHER – plaintext is not partitioned into
blocks, but just is a very long sequence of bits
Asymmetric cryptosystem
Asymmetric cryptosystems (single key)
Encrypting key is same as decrypting key
(Digital
sig)
y = Fe (x)
x = Fd (y)
(d cannot be calculated from e)
Anyone can encrypt information that only you can read
but private key is ever transmitted or shared
Session keys
Public key cryptography
• Number theory
• Modular maths - y = ax
y = ax mod m
Y is to be calculated by multiplying a by x and
then we divide the product ax by m and set y equal
to the remainder.
e.g. 9 = 5×7 mod 13
because
5×7 = 35 = 2×13 + 9.
• Very large prime numbers
Secure hash algorithm
Digital signatures in public key encryptions:
o
Slow
o
Produces enormous volume of data
One way secure hash algorithm:
o
Variable length input (thousands or millions
of bits)
o
Fixed-length output say, 160-bits.
o
1 bit = big change
o
SHA-256 and SHA-512
Secure hash algorithm
Elliptic curve cryptography (ECC)
Weierstrass equation
y2
= x3
+ ax + b mod p
RSA deals with large prime integers.
Elliptic curves deal with points, where the point P
means the pair of integers (x, y), satisfying
y2
= x3
+ ax + b mod p
“Elliptic curve Diffie–
Hellman (ECDH) is a key
agreement protocol that
allows two parties, each
having an elliptic curve
public-private key pair, to
establish a shared secret
over an insecure channel” –
http://en.wikipedia.org/wiki/Elliptic_cur
ve_Diffie%E2%80%93Hellman
Problems faced
•
Hackers
•
Legal issues
o
o
o
Digital rights management
NSA (Skipjack, Clipper chip, key
escrow)
Prohibitions (secrect
communications: criminal/treasonous)
Summary
• What are cryptography, encryption, and
decryption & how do they relate to each
other?
• Why the need for cryptography emerged
• Cryptography in history
• Some basic types of encryption methods
• Why do we need cryptography TODAY?
• How does computer science play into all
of this?
•
Problems encountered in the fields of
encryption and cryptography
Sources and further information
• Sources
Introduction to Cryptography (John
Gordon)
o An Introduction to Cryptography (PGP)
o
o
http://www.pgp.com/
• Further information
o
http://www.nsa.gov/kids/
o
http://www.iacr.org/index.php
Questions?
vxfemtf pk eqt xpg
1st clue:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
Z
Y
X
W
V
U
T
S
R
Q
P
O
N
M
L
K
J
I
H
G
F
E
D
C
B
A
2nd clue:
- 2
castles in the air