Jeff Ehme Spelman College [email protected] Chris Christensen Northern Kentucky University...

63
Jeff Ehme Spelman College [email protected] Chris Christensen Northern Kentucky University [email protected] Public- and Private-Key Cryptography

Transcript of Jeff Ehme Spelman College [email protected] Chris Christensen Northern Kentucky University...

Jeff Ehme

Spelman College

[email protected]

Chris Christensen

Northern Kentucky University

[email protected]

Public- and Private-Key Cryptography

Cryptography

Encipher(plaintext, key)

plaintext CIPHERTEXT

Decipher(CIPHERTEXT, key)

Cryptography

function

patterned "random"

inverse

Skytale

Cryptography

Caesar cipher

Hand Ciphers

Vigenere Cipher16th century

Playfair Cipher19th century

Transposition Cipher

World War I

Rotor Machines

Cipher Machines

KL47

KW-7

ATM

Modern Cryptography

IFF

Data Encryption Standard 1977

Modern Cryptography“New Directions in Cryptography” 1976

Symmetric key block ciphers

Public key ciphers

Stream ciphers

Post-quantum ciphers

Ciphers

Substitution

Classical Ciphers

Transposition

Substitution Ciphers

Simple Substitution Cipher

DROSX DOBOC DSXQW KDROW KDSMK VKCZO MDCYP ZELVS FUOIM SZROB CRKFO CZKBU ONSXD OBOCD LIWKD ROWKD SMCPK MEVDI SXDRO COMSZ ROBCK CKZZV SMKDS YXCYP WKDRO WKDSM CDRKD MKXLO ZBOCO XDONS XEXNO BQBKN EKDOM YEBCO CYPDO XSQXY BONRY GOFOB KBODR OWYNO BXZBS FKDOU OIMSZ ROBCD ROGYB URYBC OCYPM BIZDY QBKZR IWYNO BXZBS FKDOS OIMSZ ROBCK BOOAE KVVIW KDROW KDSMK VVISX DOBOC

DSXQ

Simple Substitution Cipher

Frequency Analysis

Block Ciphers 1929Lester Hill (1891 – 1961)

Hill Cipher

Linear is Bad

Private Key vs Public KeySymmetric Key vs Asymmetric key

Symmetric Key

To Exchange or Not to Exchange

Asymmetric Key

If the solution to a problem can be quickly verified by a computer, can the computer also

solve that problem quickly?

P vs NP

Data Encryption Standard 1977Horst Feistel (1915 – 1990)

Simplified DES: Wade Trapp and Lawrence Washington

Data Encryption Standard 1976

DES

64-bit block56-bit key (8 parity bits)8 S-boxes 6 x 416 roundsFeistel cipher

12-bit block9-bit key2 S-boxes 4 x 34 roundsFeistel cipher

DES

Simplified DES

Simplified DES – Feistel Cipher

Key and Message

9 bits of key 111 010 110

Use the 8 bits on the left for k1 1110 1011 Rotate to the left one bit 110 101 101Use the 8 bits on the left for k12 1101 0110 Rotate to the left 1 bit 101 011 011Use the 8 bits on the left for k3 1010 1101 Rotate to the left 1 bit 010 110 111Use the 8 bits on the left for k4 0101 1011

Key Schedule

Expansion Function and XOR

S-Box1 0 1 2 3 4 5 6 7

0 101 010 001 110 011 100 111 000

1 001 100 110 010 000 111 101 011

S 2 0 1 2 3 4 5 6 7

0 100 000 110 101 111 001 011 010

1 101 011 000 111 110 010 001 100

S

DES Encryption

1 1,

i i

i i i ii i

L R

L R R L f R K

DES Decryption

1 1

1 1

,

,

i i i ii i

i i i ii i

L R R L f R K

L R f R K R L

1 1,

i i

i i i ii i

L R

L R R L f R K Encryption

Decryption

Encryption

DES Decryption

Decryption

Backdoor?

Secrecy of Algorithm

3DES 112-bit security

3 2 1plaintext

K K KE D E

Perfect SecurityRandom key, as long as the message, and used only

once.

Computational Security

Today112

Security Level

Symmetric Key RSA and DH ECC80 1024 160

112 2048 224128 3072 256192 7680 384256 15360 521

Block Cipher Modes

Block Cipher Modes

Skipjack/Clipper ChipSkipjack declassified 1998

Clipper Chip 1993 -1996

64-bit block80-bit key32 roundsUnbalanced Feistel cipher

Substitution-Permutation Networks Claude Shannon (1916 – 2001)

“A Mathematical Theory of Communication” 1948

“The Theory of Secrecy Systems” 1949

Claude Shannon

Diffusion: “… the statistical structure of [the message] which leads to its redundancy is dissipated into long range statistics.”

Wire crossing, S-box

Confusion: “… make the relation between the simple statistics of [the ciphertext] and the simple description of [the key] a very complex and involved one.”

Permutation, P-box

“The Theory of Secrecy Systems 1949

SPN

PRESENT 2007Many

64-bit block80- or 128-bit key1 S-box 4 x 431 RoundsSubstitution-Permutation Network

PRESENT

Substitution Layer

Permutation Layer

Substitution and Permutation

Key Schedule

How do they know it’s secure?

Do Cryptographers Sleep Well?

Advanced Encryption Standard 2001Joan Daemen and Vincent Rijmen

Simplified AES: Mohammad Musa, Edward Schaefer, and

Stephen Wedig

AES

128-bit block128-bit, 192-bit, or 256-bit key10, 12, or 14 roundsSPN

16-bit block16-bit key

2 roundsSPN

AES (Rijandael)

Simplified AES

S-Box

S-Box

1y x

1xy

Add Key

5 70 1 2 3 4 6 8 9 10 11 12 13 14 15

W[0] W[1]

k k k k k k k k k k k k k k k k

SN, SR, MC

S-AES0

1

2

K

K

K

pt

A

NS

SR

MC

A

NS

SR

A

CT

SerpentTwofishRC6MARS

Simplify the Other AES Finalists

Simplified IDEAHoffman, N. 2007.“A Simplified IDEA Algorithm,”Cryptologia 31(2), 143 – 151.

TEAHolden, J. 2013.“Demitasse: A ‘Small’ Version of the Tiny Encryption Algorithm and Its Use in a

classroom Setting.”Cryptologia 37(1), 74 – 83.

Simplified Symmetric Key Block Ciphers

Stream ciphers

Oh, yeah …

Simplified DESTrappe, W. and Washington, L.Introduction to Cryptography with Coding Theory

Simplified IDEAHoffman, N. 2007.“A Simplified IDEA Algorithm,”Cryptologia 31(2), 143 – 151.

References

PRESENTBoganov, A. and others. 2007.“PRESENT: An Ultra-Lightweight Block

Cipher.”(Search the net.)

Simplified AESMusa, A., Schaefer, E., and Wedig, S.

2010.“A Simplified AES Algorithm and Its

Linear and Differential Cryptanalysis,”Cryptologia 27(12), 148 – 177.

References

TEAHolden, J. 2013.“Demitasse: A ‘Small’ Version of the Tiny Encryption Algorithm and Its Use in a

classroom Setting.”Cryptologia 37(1), 74 – 83.

Cryptology course notes and student-produced softwarehttp://www.nku.edu/~christensen/1301cscmat483.htm

References