Attacking Cryptography
Flip coins • 64 coin flips • Some will be assigned to make it up. • Others will write a simple program to do it. • 010101 string • Turn into coin flip channel on Slack.
Measuring Randomness • One of the following I made up; the other one I randomly generated. • 001010101011001101 • 010101101010001001
Cryptography Model Plaintext Cyphertext CRYPTOGRAPHY
Random Oracle Model Plaintext RANDOM
Definitions • Hash function • Stream cipher • Block cipher • Symmetric key encryption • Public key encryption • Digital signature scheme • Pseudorandom
Hash Functions • Random function • Password storage • Checksums on files • sys files • user files • integrity of sys files • Message digests h(M) • Sign the digest • Timestamp the digest
Properties of Random Functions • One way function: • Given x , compute h(X) . Given h(x) hard to generate the preimage, x . • Output doesn’t leak information about input • Given a message x and a key k , compute one-way encryption h(x,k) . • Hard to find collisions • Hard to find messages x , y such that x ≠ y but h(x)=h(y) .
n n/2 • If |h(m)|=n , then 2 hash values. Attacker needs to guess 2 values before guessing m . • Birthday paradox • given 30 or more people, some pair will have the same birthday • given 23 or more, more 50% odds • Capture-recapture • k/K = n/N • N= Kn/k • where k=overlap individuals, K=recapture population, n=capture population, N=total population
Public key encryption • Trapdoor one way function • KR - public key • KR -1 - private key • Given KR, can’t compute KR -1 • C={M} KR • M = {C} KR-1
Attacks • Known plaintext • Chosen plaintext • Chosen ciphertext • Related key attack • Forgery attack • Key recovery attack
Recommend
More recommend