Top Banner
Internet Infrastructure
44

L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

May 01, 2018

Download

Documents

vothuan
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Internet Infrastructure

Page 2: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Internet Infrastructure

Local and inter-domain routing

TCP/IP for routing and messaging

BGP for routing announcements

Domain Name System

Find IP address from symbolic name (www.cc.gatech.edu)

Page 3: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Match the level to its description

Tier One

Tier Two

Tier Three

1. A network that purchases all transit fromother networks.

2. A network that peers some of its networkaccess and purchases some of it.

3. A network can reach every other networkthrough peering.

Level: Descriptions:

Infrastructure Quiz

3

2

1

Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in exchange for free access to other networks

Page 4: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Infrastructure Quiz

NAMEAT&T Cogent Communications

CenturyLink Deutsche Telekom AG

KPN International Level 3 Communications

NTT Communications (America) Orange

Sprint Tata Communications (America)

Telecom Italia Sparkle Telefonica Global Solutions

Telia Carrier Verizon Enterprise Solutions

Zayo Group -----

Page 5: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

TCP Protocol Stack

Application

Transport

Network

Link

Application

Transport

Network

Link

IP

Network Access

Application Protocol

TCP Protocol

IP Protocol

IP Protocol

DataLink

DataLink

Page 6: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

TCP Protocol Stack: Data Formats

Application

Transport (TCP,UDP)

Network(IP)

Link Layer

Message

Segment

Packet

Frame

TCP Header

TCP data TCP data

IP TCP data

EIT IP TCP data ETF

IP HeaderLink (Ethernet)

HeaderLink (Ethernet)

Trailer

Application message - data

TCP data

Page 7: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Connectionless

Unreliable

Best effort

Version Header Length

Type of Service

Total Length

Identification

Flags Fragment Offset

Time to Live

Protocol

Header Checksum

Source Address of Originating Host

Destination Address of Target Host

Options

Padding

IP Data

Notes: src and destports not parts of IP hdr

Internet Protocol: IP Routing

Page 8: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Internet Protocol: IP Routing

PACKET

Source 121.42.33.12

Destination 132.14.11.51

121.42.33.12

Alice

132.14.11.51

Bob

121.42.33.1

ISP

132.14.11.1

Office gateway

Typical route uses several hops

IP: no ordering or delivery guarantees

Page 9: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

IP Protocol Functions (Summary)

IP gateway must know route to other networks

Routing

IP host knows location of router (gateway)

Fragmentation and reassembly

If max-packet-size less than the user-data-size

Page 10: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

IP Protocol Functions (Summary)

Prevents infinite loops.

Error reporting

ICMP packet to source if packet is dropped

TTL field: decremented after every hop

Packet dropped if TTL=0.

Page 11: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Select all the true statements about Internet Protocol (IP).

IP provides only best effort delivery, it is not guaranteed.

Due the connectionless nature of IP, datacorruption, packet loss, duplication, and out-of-order delivery can occur.

IP Quiz

IP is a connectionless and reliable protocol.

Page 12: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

IP Authentication

Client is trusted to embed correct source IP

Easy to override using raw socketsLibnet: a library for formatting raw packets with arbitrary IP headers

The problem: No Source IP authentication

Anyone who owns their machine can send packets with arbitrary source IP, and a response will be sent back to forged source IP

Page 13: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

IP Authentication

Client is trusted to embed correct source IP

Easy to override using raw socketsLibnet: a library for formatting raw packets with arbitrary IP headers

The problem: No Source IP authentication

Anonymous infection/malware attacks

Implications:

Anonymous DoS attacks;

Page 14: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Transmission Control Protocol

Connection-oriented, preserves order

Book

Page 15: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Transmission Control Protocol

Sender :

Break data into packets

Attach packet numbers

Book Mail each page

Page 16: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Transmission Control Protocol

Book Mail each page

Receiver:

Acknowledge receipt; lost packets are resent

Reassemble packets in correct order

Reassembled Book

Page 17: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Transmission Control Protocol

TCP Header

ver hlen TOS Pkt len

Identification flgfragment

offset

TTL protocol header checksum

Source IP address

Destination IP address

IP H

eade

r

Source port Dest port

SEQ Number

ACK Number

URG

ACK

PSH

PSR

SYN

FIN

Other Stuff

TC

P H

eade

r

Page 18: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Review TCP Handshake

SNCrandCANC0

SYN:

SNSrandSANSSNC+1

SYN/ACK:

SNCSNC+1

ANC SNS +1ACK:

Listening

Store SNC, SNS

Wait

Established

C S

Received packets with SN too far out of window are dropped

Page 19: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

TCP Basic Security Problems

Especially easy when attacker controls a machine close to victim (e.g. WiFi routers)

Network packets pass by untrusted hosts

Eavesdropping, packet sniffing

1

TCP state easily obtained by eavesdropping

Enables spoofing and session hijacking

2

Denial of Service (DoS) vulnerabilities

See DDoS lesson

3

Page 20: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Select all the true statements:

IP information cannot be protected by transport layer controls.

TCP IP Security Issues Quiz

Application layer controls can protect application data, and IP addresses.

Network layer controls can protect the data within the packets as well as the IP information for each packet.

Data link layer controls can protect connections comprised of multiple links

Page 21: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Random Initial Sequence Numbers

Suppose initial seq. numbers (SNC , SNS ) are predictable:

Attacker can create TCP session on behalf of forged source IP

Breaks IP-based authentication (e.g. SPF, /etc/hosts )

Random seq. num. do not prevent attack, but make it harder

Page 22: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Random Initial Sequence Numbers

TCP SYNsrcIP=victim

ACKsrcIP=victim

AN=predicted SNS+1

Command

SYN/ACKdstIP=victim

SN=server SNS

Server thinks command is from victim IP addr

Victim

Attacker

Page 23: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Example DoS Vulnerability: Reset

If correct SNS then connection will close DoS

Naively, success prob. is 1/232 (32-bit seq. #’s).… but, many systems allow for a large window of acceptable seq. #‘s. Much higher success probability.

Attacker can flood with RST packets until one works

Attacker sends a Reset packet on an open socket

Page 24: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Match the protocol with its description:

Address Resolution Protocol (ARP)

Open Shortest Path First (OSPF)

Border Gateway Protocol (BGP)

A. protocol designed to exchange routingand reachability information amongautonomous systems (AS)

B. protocol designed to map IP networkaddresses to the hardware addressesused by a data link protocol

C. protocol uses a link state routingalgorithm and falls into the group ofinterior routing protocols

Protocol: Descriptions:

Protocols Quiz

B

C

A

Page 25: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

ARP request message sent out

IP: 192.168.1.110

IP: 192.168.1.120

IP: 192.168.1.130Router or Host

Protocols Quiz

Page 26: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

ARP reply

IP: 192.168.1.110

IP: 192.168.1.120

IP: 192.168.1.130Router or Host

Protocols Quiz

Page 27: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Protocols Quiz

R1 R2

R3 R5R4

Page 28: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Protocols Quiz

AS 200 AS 100

AS 300

Router A Router B

Router C

Page 29: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Routing Security: Interdomain Routing

Gatech.edu

OSPFAutonomous System

Connected group of one or more Internet Protocol prefixes under a single

routing policy (aka domain)

Earthlnk.net

BGP

Page 30: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Routing Protocols

By proxying traffic, node A can read/inject packets into B’s session (e.g. WiFi networks)

Security issues: (local network attacks)

Node A can confuse gateway into sending it traffic for Node B

ARP (addr resolution protocol): IP addr eth addr

Page 31: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Routing Protocols

Example: Youtube-Pakistan mishap

Security issues: unauthenticated route updates

Anyone can cause entire Internet to send traffic for a victim IP to attacker’s address

BGP: routing between Autonomous Systems

Anyone can hijack route to victim

Page 32: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

[D. Wetherall]

7

2 7

2 7

2 7

6 2 7

3 2 7

7

BGP

5

43

67

8

1

2

Page 33: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

BGP: Security Issues

Advertisement will propagate everywhere

BGP path attestations are un-authenticated

Anyone can inject advertisements for arbitrary routes

Used for DoS, spam, and eavesdropping (details in DDoSlecture)

Page 34: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

BGP: Example path hijackNormally: Alestra (Mexico) PCCW (Texas) Qwest (DC)

Feb 2013: Guadalajara Washington DC via BelarusPerson browsing the Web in DC cannot tell by traceroute that HTTP

Responses are routed through Moscow

Page 35: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

Match the attack to its characteristic:

Denial of Service

Sniffing

Routing to Endpoints in Malicious Networks

Creating Route Instabilities

Revelation of Network Topologies

A. Unmasking the AS relationships by hackingthe routing table.

B. Not yet used by hackers because damagecannot be contained. It can blowback to theattacker.

C. The first step is to hijack traffic from alegitimate host.

D. Create a false route or kill a legitimate one.

E. The attacker must control a device alongthe victim’s communication path.

Attack: Characteristic:

BGP Attacks Quiz

D

E

C

B

A

Page 36: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

BGP: Security Issues

Defends against a malicious AS (but not a network attacker)

RPKI: AS obtains a certificate (ROA) from regional authority (RIR) and attaches ROA to path advertisement.

Advertisements without a valid ROA are ignored.

SBGP: sign every hop of a path advertisement

Solutions:

Page 37: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

S-BGP Design Overview

Attestations: digitally-signed authorizations

Address: authorization to advertise specified address blocks

IPsec: secure point-to-point router communication

Public Key Infrastructure: authorization for all S-BGP entities

Route: Validation of UPDATEs based on a new path attribute, using PKI certificates and attestations

Page 38: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

S-BGP Design Overview

Repositories for distribution of certificates, CRLs, and address attestations

Tools for ISPs to manage address attestations, process certificates & CRLs, etc.

Page 39: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

43

67

8

1

2

S-BGP Design Overview

5Host1Host2…

HostnAddress blocks

7 7

AS

2 7

2 7

2 7

Page 40: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

S-BGP Overview: Address Attestation

Includes identification of:

owner’s certificate

Indicates that the final AS listed in the UPDATE is authorized by the owner of those address blocks

AS to be advertising the address blocks

address blocks

expiration date

Page 41: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

S-BGP Overview: Address Attestation

Digitally signed by owner of the address blocks

Used to protect BGP from erroneous UPDATEs (authenticated but misbehaving or misconfigured BGP speakers)

Page 42: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

S-BGP Overview: Route Attestation

Includes identification of:

AS’s or BGP speaker’s certificate issued by owner of the AS

the address blocks and the list of ASes in the UPDATE

the neighbor

expiration date

Indicates that the speaker or its AS authorizes the listener’s AS to use the route in the UPDATE

Page 43: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

S-BGP Overview: Route Attestation

Digitally signed by owner of the AS (or BGP speaker) distributing the UPDATE, traceable to the IANA …

Used to protect BGP from erroneous UPDATEs (authenticated but misbehaving or misconfigured BGP speakers)

Page 44: L4 Security Internet Protocols Final - Amazon S3 · Infrastructure Quiz 3 2 1 Peering: ISPs connect their networks together. Traffic is allowed to flow across a network in ... L4_Security

S-BGP Overview: Route Attestation

To validate a route from ASn, ASn+1 needs:

address attestation from each organization owning an address block(s) in the NLRIaddress allocation certificate from each organization owning address blocks in the NLRIroute attestation from every AS along the path (AS1 to ASn), where the route attestation for ASk specifies the NLRI and the path up to that point (AS1 through Ask-1)

certificate for each AS or router along path (AS1 to ASn) to check signatures on the route attestations

all the relevant CRLs must have been checked