22 Security
22 Security
Security
Rodrigo Fonseca
Based
on
lecture
notes
by
Sco1
Shenker
and
Mike
Freedman
Today’s Lecture
• Classes of attacks
• Basic security requirements
• Simple cryptographic methods
• Cryptographic toolkit (Hash, Digital Signature, …)
• DNSSec
• Certificate Authorities
• SSL / HTTPS
Basic Requirements for Secure Communication
• Availability: Will the network deliver data?
– Infrastructure compromise, DDoS
• Authentication: Who is this actor?
– Spoofing, phishing
• Integrity: Do messages arrive in original form?
• Confidentiality: Can adversary read the data?
– Sniffing, man-in-the-middle
• Provenance: Who is responsible for this data?
– Forging responses, denying responsibility
– Not who sent the data, but who created it
Other Desirable Security Properties
• Authorization: is actor allowed to do this action?
– Access controls
• Accountability/Attribution: who did this activity?
• Audit/Forensics: what occurred in the past?
– A broader notion of accountability/attribution
• Appropriate use: is action consistent with policy?
– E.g., no spam; no games during business hours; etc.
• Freedom from traffic analysis: can someone tell
when I am sending and to whom?
• Anonymity: can someone tell I sent this packet?
Internet’s Design: Insecure
A B
Eavesdropper
Eavesdropping Attack: Example
A B
Perpetrator
Authenticity Attack - Fabrication
A B
Masquerader: from A
Attack on Availability
• Destroy hardware (cutting fiber) or software
• Modify software in a subtle way
• Corrupt packets in transit
A B
Encrypt with
Internet Decrypt with
secret key secret key
Ciphertext
Asymmetric Encryption (Public Key)
Plaintext Plaintext
Internet
Encrypt with Decrypt with
public key private key
Ciphertext
Works in Reverse Direction Too!
• Sender uses his own private key
• Receiver uses complementary public key
• Allows sender to prove he knows private key
Plaintext Plaintext
Internet
Decrypt with Encrypt with
public key private key
Ciphertext
Realizing Public Key Cryptography
• Invented in the 1970s
– Revolutionized cryptography
– (Was actually invented earlier by British intelligence)
• How can we construct an encryption/decryption
algorithm with public/private properties?
– Answer: Number Theory
• Most fully developed approach: RSA
– Rivest / Shamir / Adleman, 1977; RFC 3447
– Based on modular multiplication of very large integers
– Very widely used (e.g., SSL/TLS for https)
• RSA:
– assumes it is difficult to factor a large integer with two large
prime factors
• Elliptic Curve:
– discrete logarithm of a random elliptic curve in a finite field
• Confidentiality: Encryption
• Integrity: ?
• Authentication: ?
• Provenance: ?
Integrity: Cryptographic Hashes
• Hard to invert
– Given hash, adversary can’t find input that produces it
– Can refer obliquely to private objects (e.g., passwords)
• Send hash of object rather than object itself
Effects of Cryptographic Hashing
Cryptographic Toolkit
• Confidentiality: Encryption
• Integrity: Cryptographic Hash
• Authentication: ?
• Provenance: ?
Public Key Authentication
• Confidentiality: Encryption
• Integrity: Cryptographic Hash
• Authentication: Decrypting nonce
• Provenance: ?
Digital Signatures
33
Public Key Infrastructure (PKI)
• Public key crypto is very powerful …
• … but the realities of tying public keys to real
world identities turn out to be quite hard
CA-1 CA-2
Registration Authority
45
Validating Amazon’s Identity
• Feb. 6, 2007:
– Botnet attack on the 13 Internet DNS root servers
– Lasted 2.5 hours
– None crashed, but two performed badly:
• g-root (DoD), l-root (ICANN)
• Most other root servers use anycast
Do you trust the TLD operators?
source:
wikipedia
DNS Amplification Attack
DNS
Amplifica[on
a1ack:
(
×40
amplifica[on
)
DNS
Query
SrcIP:
DoS
Target
EDNS
Reponse
(60
bytes)
(3000
bytes)
DoS
DNS
DoS
Source
Server
Target
ip
spoofed
packets
open
a1acker
amplifier
prevent
disable
ip
spoofing
open
amplifiers
vic[m
But should we believe it?
Enter DNSSEC
dns.cs.brown.edu
.(root)
Src.cs.brown.edu
ask
.com
server
www.cnn.com
A
?
SIG
(ip
addr
and
PK
of
.com
server)
stub
resolver
xxx.xxx.xxx.xxx
resolver
www.cnn.com
A
?
transac[on
.com
ask
cnn.com
server
signatures
SIG
(ip
addr
and
PK
of
cnn.com
server)
add
to
cache
slave
servers
transac[on
signatures
cnn.com
Next Class