Chapter 2 Flashcards
Peer-peer architecture
No always-on server.
Arbitrary end systems directly communite.
Peers request service from other peers, provide service in return to other peers.
Sockets
process ends/receives messages to/from its socket.
Does an IP address of host of which process runs suffice for identifying the process?
No. Many processes can be running on the same host.
Indetifier
Includes both IP addresses and port numbers associated with process on host.
An application-layer protocol defines:
Types of messages exchanged
Message syntax
Message semantics
Rules
Open protocols
Proprietary protocols.
What transport service does an app need?
Data Intergrity
Timing
Throughput
Security
TCP Service
Reliable transport.
Flow control
Congestion Control
Connection-Oriented
Does not provided timing, minimum throughput guarantee, security .
UDP Service
Unreliable data transfer
Does not provide TCP services.
Vanilla TCP and UDP sockets
No encryption
Cleartext passwords sent into socket traverse Internet in cleartext!
TLS
Transport Layer Security
Provides encrypted TCP connections
Data integrity
End-Point authentication
HTTP
Hypertext transfer protocol
Web’s application-layer protocol.
Use TCP
HTTP is “stateless” meaning:
Server maintains no info about past client requests.
Non-presistent HTTP
At most one object sent over TCP connection
Downloading multiple objects requires multiple connections.
Persistent HTTP
Multiple objects can be sent over single TCP connection between client and server.
RTT
Time for a small packet to travel from client to server and back.
HTTP Request Message Types
POST
GET
HEAD
PUT
HTTP Response Status Codes
200 OK
301 Moved Permanently
400 Bad Request
404 Not Found
505 HTTP Version Not Supported
Cookies
used to maintain some states between transactions.
tracking may be invisible to user.
Cookie Components
Cookie Header line of HTTP response message
Cookie Header line in next HTTP request messsage
Cookie file kept on user’s host, managed by user’s browser
Back-end database at Web site.
First Party Cookies
Track user behavior on a given website
Third Party Cookies
Track user behavior across mutliple websites (without user ever choosing to visit tracker site)
Web Caches
Satisfy client requests without involving orgin server.
Why Web Caching?
Reduce response time for client request.
Reduce traffice
Browser Caching
Don’t send object if broswer has up to date cached version.