CSCI 8260 – Spring 2016 Network Attacks and Defenses
Instructor: Prof. Roberto Perdisci perdisci@cs.uga.edu
source: computer-networks-webdesign.com
These slides are adapted from the textbook slides by J.F. Kurose and K.W. Ross
CSCI 8260 Spring 2016 Network Attacks and Defenses Instructor: - - PowerPoint PPT Presentation
source: computer-networks-webdesign.com CSCI 8260 Spring 2016 Network Attacks and Defenses Instructor: Prof. Roberto Perdisci perdisci@cs.uga.edu These slides are adapted from the textbook slides by J.F. Kurose and K.W. Ross Chapter 2:
Instructor: Prof. Roberto Perdisci perdisci@cs.uga.edu
source: computer-networks-webdesign.com
These slides are adapted from the textbook slides by J.F. Kurose and K.W. Ross
} transport-layer service
} client-server paradigm } peer-to-peer paradigm
} HTTP } FTP } SMTP / POP3 / IMAP } DNS
} socket API
Application 2-2
Application 2-3
} run on (different) end systems } communicate over network } e.g., web server software
} network-core devices do not run
} applications on end systems
application transport network data link physical application transport network data link physical application transport network data link physical
Application 2-4
Application 2-5
Application 2-6
} always-on host } permanent IP address } server farms for scaling
} communicate with server } may be intermittently connected } may have dynamic IP addresses } do not communicate directly
Application 2-7
Application 2-8
} voice-over-IP P2P application } centralized server: finding address of remote party: } client-client connection: direct (not through server)
} chatting between two users is P2P } centralized service: client presence detection/location
Application 2-9
Application 2-10
} sending process shoves message
} sending process relies on
process TCP with buffers, variables socket host or server process TCP with buffers, variables socket host or server Internet controlled by OS controlled by app developer
Application 2-11
Application 2-12
} HTTP server: 80 } Mail server: 25
} IP address: 128.119.245.12 } Port number: 80
} A: No, many processes can
Application 2-13
} connection-oriented: setup required
} reliable transport between sending
} flow control: sender won’t
} congestion control: throttle sender
} does not provide: timing, minimum
} unreliable data transfer
} does not provide: connection
Application 2-14
} app architectures } app requirements
} SMTP
Application 2-15
Application 2-16
} Web’s application layer protocol } client/server model } client: browser that requests,
} server: Web server sends
PC running Firefox Server running Apache Web server Mac running Chrome
Application 2-17
} client initiates TCP connection
} server accepts TCP connection
} HTTP messages (application-layer
} TCP connection closed
} server maintains no
v past history (state) must
v if server/client crashes,
Application 2-18
Application 2-19
Application 2-20
Application 2-21
time to transmit file initiate TCP connection RTT request file RTT file received time time
Application 2-22
} requires 2 RTTs per object } OS overhead for each TCP
} server leaves connection open
} subsequent HTTP messages
} client sends requests as soon as
} as little as one RTT for all the
Application 2-23
} browsers can open parallel TCP
} Has advantages and disadvantages
Application 2-24
} ASCII (human-readable format)
Application 2-25
carriage return character line-feed character
Application 2-26
2: Application Layer 27
} web page often includes form
Application 2-28
} asks server to leave requested
} uploads file in entity body to
} deletes file specified in the URL
Application 2-29
Application 2-30
} request succeeded, requested object later in this msg
} requested object moved, new location specified later in this msg
} request msg not understood by server
} requested document not found on this server
Application 2-31
Application 2-32
} unique ID } entry in backend database
Application 2-33
ebay 8734
ebay 8734 amazon 1678
ebay 8734 amazon 1678
Application 2-34
Application 2-35
2: Application Layer 36
} Session cookies } Permanent cookies (tracking cookies)
} You visit www.example.com, which contains a banner from ads.clicks-
} in simple terms ads.clicks-for-me.net is third-party because it does not
} third-party sites should be denied setting or reading cookies
} The browser allows ads.clicks-for-me.net to drop a third-party
} Then you visit www.another-example.com , which also loads ads from
} ads.clicks-for-me.net can track the fact that you visited both
2: Application Layer 37
} An attacker may be able to “sniff” your authentication cookies } The attacker will be able to login as you on a website (e.g.,
} See FireSheep for a concrete example!
} http://codebutler.com/firesheep
2: Application Layer 38
} Session IDs are commonly used by web applications
} http://example.com/index.php?user_id=0F4C26A1&topic=networking
} Session IDs are typically passed in the URL (added to web app
} Cookies are passed through HTTP req/resp headers } Cookies are stored in the browser’s cache and have an
} Session IDs are volatile: never stored, only used until end of
} object in cache: cache
} else cache requests object
client
client
server
server
Application 2-39
} Splits the TCP connection!
Application 2-40
2: Application Layer 41
} The client sends multiple HTTP request without waiting for
} The server sends the response one after the other
} HTTP allows downloading pieces of objects } Example:
} 10MB image to be downloaded } We can open 10 different TCP connection and send 10 HTTP requests
} Download 1MB of data from each connection and stitch them back
} SMTP
Application 2-42
} SSN, name, passport #
} IP address (32 bit) - used for
} “name”, e.g., ww.yahoo.com -
} distributed database implemented in
} application-layer protocol host,
} note: core Internet function,
} complexity at network’s “edge”
Application 2-43
} Canonical, alias names
} replicated Web servers: set of
Application 2-44
} client queries a root server to find com DNS server } client queries com DNS server to get amazon.com DNS server } client queries amazon.com DNS server to get IP address for
Application 2-45
} contacted by local name server that can not resolve name } root name server: } contacts authoritative name server if name mapping not known } gets mapping } returns mapping to local name server
b USC-ISI Marina del Rey, CA l ICANN Los Angeles, CA e NASA Mt View, CA f Internet Software C. Palo Alto,
CA (and 36 other locations)
i Autonomica, Stockholm (plus 28 other locations) k RIPE London (also 16 other locations) m WIDE Tokyo (also Seoul, Paris, SF) a Verisign, Dulles, VA c Cogent, Herndon, VA (also LA) d U Maryland College Park, MD g US DoD Vienna, VA h ARL Aberdeen, MD
j Verisign, ( 21 locations)
Application 2-46
} responsible for com, org, net, edu, aero, jobs, museums, and all
} Network Solutions maintains servers for com TLD } Educause for edu TLD
} organization’s DNS servers, providing authoritative hostname
} can be maintained by organization or service provider
Application 2-47
} also called “default name server”
} acts as proxy, forwards query into hierarchy
Application 2-48
gaia.cs.umass.edu
authoritative DNS server dns.cs.umass.edu
v contacted server
v “I don’t know this
Application 2-49
Query for gaia.cs.umass.edu
} cache entries timeout (disappear) after some time } TLD servers typically cached in local name servers
} Thus root name servers not often visited
Application 2-50
} name is domain (e.g. foo.com) } value is hostname of
Application 2-51
v identification: 16 bit #
v flags:
Application 2-52
Application 2-53
} provide names, IP addresses of authoritative name server (primary and
} registrar inserts two RRs into com TLD server:
Application 2-54
2: Application Layer 55
} Only check is on TXID
cis.poly.edu gaia.cs.umass.edu
dns.poly.edu authoritative DNS server dns.cs.umass.edu
2: Application Layer 56
} Port randomization } 0x20-Bit encoding
} Responses are digitally signed } They can be verified by following a chain of trust anchored at
} Not yet fully deployed
} SMTP
Application 2-57
} file distribution } searching for information } case Study: Skype
Application 2-58
trading chunks peer
Application 2-59
Application 2-60
} NAT prevents an outside peer
} using Alice’s and Bob’s SNs,
} each peer initiates session with
} peers can now communicate
Application 2-61