1
Network Control
As usual, thanks to Vern Paxson and David Wagner
Network Control As usual, thanks to Vern Paxson and David Wagner 1 - - PowerPoint PPT Presentation
Network Control As usual, thanks to Vern Paxson and David Wagner 1 Focus of This Lecture Begin discussion of approaches for controlling network traffic: Firewalls: restricting allowed communication NATs: Network Address
1
As usual, thanks to Vern Paxson and David Wagner
2
3
– Key Observation:
– Due to larger attack surface
– But you have to know that it’s running them – And sometimes some trusted remote users still require access
– What happens when you have to secure 100s/1000s of systems? – Which may have different OSs, hardware & users – Which may in fact not all even be identified
4
5
– Who is allowed to talk to whom, accessing what service?
– Inbound: attempts by external users to connect to services on internal machines – Outbound: internal users to external services
– Permit inside users to connect to any service – External users restricted:
6
In general, use Default Deny
7
8
9
10
allow tcp 4.5.5.4:1025 -> 3.1.1.2:80
– from Internet address 4.5.5.4 and – using a source port of 1025 and – destined to port 80 of Internet address 3.1.1.2 deny tcp 4.5.5.4:* -> 3.1.1.2:80
regardless of source port deny tcp 4.5.5.4:* -> 3.1.1.2:80 allow tcp 4.5.5.4:1025 -> 3.1.1.2:80
allow tcp 4.5.5.4:1025 -> 3.1.1.2:80 deny tcp 4.5.5.4:* -> 3.1.1.2:80
3.1.1.2 if they come from source port 1025
11
12
– Inbound mail connections to our mail server (1.2.3.4:25) – All outbound connections from our network, 1.2.3.0/24
– Nothing else
allow tcp *:* -> 1.2.3.4:25 allow tcp 1.2.3.0/24:* -> *:* drop * *:* -> *:*
– TCP connections are bidirectional – 3-way handshake: send SYN, receive SYN+ACK, send ACK, send DATA w/ ACK bit set
13
1.allow tcp *:* -> 1.2.3.4:25 2.allow tcp 1.2.3.0/24:* -> *:* 3.drop * *:* -> *:*
– Initial SYN packet passed through by rule 2 – SYN+ACK packet coming back is dropped
– In general, we need to distinguish between 2 kinds of inbound pkts
– How do we tell them apart?
14
15
= Attempts to open an inbound TCP connection to internal SMB server
– Packet lacks ACK bit ⇒ no match to Rules 1-3, dropped by Rule 4
– Firewall permits the packet due to Rule 3 – But then dropped by server’s TCP stack (since ACK bit set, but isn’t part of existing connection)
16
17
18
10.0.0.1 10.0.0.2 10.0.0.3
S: 10.0.0.1, 3345 D: 128.119.40.186, 80
1
10.0.0.4 138.76.29.7
1: host 10.0.0.1 sends packet to 128.119.40.186, 80 NAT translation table Public side addr LAN side addr 138.76.29.7, 5001 10.0.0.1, 3345 …… ……
S: 128.119.40.186, 80 D: 10.0.0.1, 3345
4
S: 138.76.29.7, 5001 D: 128.119.40.186, 80
2 2: NAT router changes packet source addr from 10.0.0.1, 3345 to 138.76.29.7, 5001, updates table
S: 128.119.40.186, 80 D: 138.76.29.7, 5001
3 3: Reply arrives
138.76.29.7, 5001 4: NAT router changes packet dest addr from 138.76.29.7, 5001 to 10.0.0.1, 3345
19
20
21
22
23
24
25
26
27
Source port Destination port Sequence number Acknowledgment Advertised window HdrLen SYN Checksum Urgent pointer Options (variable)
28
Source port Destination port Sequence number Acknowledgment Advertised window
HdrLen
SYN Checksum Urgent pointer Options (variable)
29
Source port Destination port Sequence number Acknowledgment Advertised window
HdrLen
SYN Checksum Urgent pointer Options (variable)
30
31
32
33
34
35
36
– Success story: R&D to industry tech transfer
>$500M/yr revenue
– Central control – easy administration and update
– Easy to deploy – transparent to end users
– Addresses an important problem
37
38
39
40
41
application gateway
permit <port=22, host=1.3.5.7> deny <port=22> 1.3.5.7
42
43
44