Transcript Session 5B
Internet and Intranet
Fundamentals
Class 5
Session B
Topics
• NNTP
• Mid-Term Review
NNTP
• NNTP = Network News Transfer Protocol
– Internet bulletin board system
• 1986
– RFC 977 (Kantor & Lapsley)
• “News” means bulletins, information, data,
messages from individuals
– not news agencies (although this is not
precluded)
NNTP
• Facilitates rapid dissemination of software
bug fixes, technical tips, product reviews,
discussions, rumors
–
–
–
–
distribution
inquiry
retrieval
posting
• USENET News System
NNTP
• Model: Centralized storage of postings or
news articles
– clients / server model
• USENET News
• TCP
– Port 119
NNTP
• Info Organized into Newsgroups
– hierarchical, like a file directory system
• rec.sports.football.nfl
• Master-Slave Relationship between News
Servers
– dependent news servers can request that only
certain postings (e.g., since a certain time) are
transmitted
– equivalent of caching
NNTP
Commands
• ARTICLE <message-id> or [nnn]
Responses:
220 n <a> article retrieved - head and body follow
(n = article number, <a> = message-id)
221 n <a> article retrieved - head follows
222 n <a> article retrieved - body follows
223 n <a> article retrieved - request text separately
412 no newsgroup has been selected
420 no current article has been selected
423 no such article number in this group
430 no such article found
NNTP
Commands
• LIST
– lists valid newsgroups
• GROUP ggg
– selects a valid newsgroup
– response returns first and last article numbers
• LAST
– current article pointer set to previous article
• NEXT
NNTP
Commands
• NEWSGROUPS date time
– list of newsgroups created since date and time
• NEWNEWS newsgroups date time
– returns list of articles posted to any one of the
newsgroups specified since date and time
• POST
– post article in format specified by RFC 850
NNTP
USENET News-Related Services
• http://www.dejanews.com
• http://www.intellinews.com
Mid-Term Review
• Covers Everything Up Through Class 5
• Selections from Previous Presentations
Open Systems Interconnection
Model
• Seven Layers
–
–
–
–
–
–
–
Application (S/W)
Presentation (S/W)
Session (S/W)
Transport (S/W)
Network (S/W and H/W)
Data Link (F/W and H/W)
Physical (H/W)
OSI Reference Model
Application
Application
Presentation
Presentation
Session
Session
Transport
Transport
Network
Network
Network
Data Link
Data Link
Data Link
Physical
Physical
Physical
OSI Application Layer
•
•
•
•
•
•
Application and User Interfaces
File Transfer
E-Mail
Database Access
Program to Program Communication
http, ftp, gopher, smtp, telnet
OSI Transport Layer
• Host-to-Host Layer
• Error Free End-to-End Connections
– virtual connections
– doesn’t know about intervening routers
• TCP in TCP/IP
• Often Implemented in Operating System
OSI Network Layer
•
•
•
•
•
•
•
Communications Subnet Layer
Network Routing
Packets
Congestion and Flow Control
Accounting
IP in TCP/IP
Typically Implemented as I/O Driver
OSI Data Link Layer
• Breaks Up Input Data from Network Layer
and Transmits as Data Frames
• Typically an Interface Card with Firmware
– Ethernet card
• Acknowledgement
• Error Handling
– Retransmission
• Flow Control
OSI Physical Layer
• Transmits Raw Bits
• Includes Communication Channel
– copper wire
– fiber
– microwave
• Signaling Levels
– voltages, timing
• Pin Configurations
• Client
Definitions
Client / Server
– makes request
– initiates communication
– may have a GUI and human
• but not always
• Server
– fulfills request
– passively waits for requests
– usually multitasking machine
Definitions
Client / Server
• Fat Clients
– full-featured, large applications
– use servers as data servers
– not much computational power on the server
side
• Thin Clients
– small applications
– downloaded from the network
– relies on computational power of server
Definitions
Client / Server
• Fat Client Example
– Web Browser
– Eudora
– Visio
• Thin Client
– Java Applets
– JavaScript Applications inside of HTML Pages
– Note dependence on Fat Client (i.e., the
browser)
Definitions
TCP / IP Berkeley Sockets
• Five Basic Attributes of a Socket
Connection
–
–
–
–
–
Local Port (chosen by OS on client side)
Local IP Address
Remote Port
Remote IP Address
Protocol (“tcp”, “udp”, etc.)
• Each Connection Has Own 5-tuple
Definitions
TCP / IP Berkeley Sockets
•
•
•
•
•
Server Listens on (Well-Known) Port
Clients Attempts Make a Connection
Server Accepts the Connection
Server Receives Request from Client
Server Interprets Request
– performs some action
• Sends Response to Client
• Shuts Down the Connection
Internet Protocls
TCP/IP Overview
• TCP / IP = Transmission Control Protocol /
Internet Protocol
• Early 1970s
– ARPANET
• Distributed with UC Berkeley UNIX in
Early 1980s
• Public Domain, Non-Proprietary, Open
Source
Internet Protocols
Layers
• Five Layer Model
– Application
– Transport (TCP / UDP)
• contains some Session features
– Network (IP)
• actually there are three sublayers
– internet (IP)
– convergence
– subnet
– Data Link and Physical
Internet Protocols
Layers
• Packet Switching
– datagrams
• Nodes
– hosts
• end-user machines
• clients or servers
– routers
• connecting different networks
• a router is also a host of sorts
Internet Protocols
Layers
• Connection-Oriented
– TCP
– reliable two-way, byte stream protocol
• Connectionless
– UDP = User Datagram Protocol
• also known as the “Unreliable Datagram Protocol”
Internet Protocols
TCP
• Reliable, Bidirectional Byte Stream
– like a UNIX pipe
• End-to-End Reliability
• Bandwidth Optimization (flow control)
• Ports
– source
– destination
Internet Protocols
UDP
• User Datagram Protocol
• Ports (like TCP)
• Length, Checksum, Data
– no sequencing or acknowledgment structure
– error handling left to applications protocol
• DNS uses UDP
Internet Protocols
DNS
• Domain Name System
• Distributed
– database scattered across thousands of
nameservers
• Top-Level Domains
– root domain: .
– net, edu, com, org, mil, and country codes (jp)
• FQDN: Fully Qualified Domain Name
TCP / IP
• ICMP = Internet Control Message Protocol
– routers generate most ICMP traffic
– most common types
• destination unreachable: can’t find routing table
entry
• routing redirect: better route exists
• time expired: ttl = 0; traceroute uses this
• echo request / echo reply: ping uses this
TCP / IP
Routing Architecture
• Autonomous Systems (AS)
– collection of routers under single administration
– use same routing protocol
• Interior Gateway Protocol (IGP)
• keeps routers informed of interior routes
– AS-to-AS connection uses a different protocol
• Exterior Gateway Protocol
• policy routing, transit traffic, local traffic
(originating within)
TCP / IP
Routing Architecture
• Routing Protocols
• Reachability Protocols
– whether path exists
• EGPs and BGPs (Border Gateway Protocol)
• Distance Vector Protocol
– distance metric to remote network
• RIP = Routing Information Protocol
– broadcast exchange of routing information
– uses UDP
• OSPF = Open Shortest Path First
Internet Architecture
Overview
• A Network of Networks
– internetworking
• The Big Picture
– http://navigators.com/internet_architecture.html
ISPs
• Points of Presence (POPs)
• Dial-Up and Dedicated Network
Connections
– variety of underlying technologies
– PPP (Point-to-Point Protocol)
• modems
– ISDN (Integrated Services Digital Network)
– Frame Relay, Dedicated T-1
– ADSL and Cable Modems
Regional Networks
•
•
•
•
•
•
•
BARRNet: Northern Central California (CA)
CERFnet: Western US and International
CICnet: Midwest US (MN, WI, IA, IN, IL, MI, OH)
MIDnet: Mid-US (NE, OK, AR, MO, IA, KS, SD)
NEARNET: Northeastern US (ME, NH, VT, CT, RI, MA)
NYSERNet: Northeastern US (NY...)
SURAnet: Southeastern US (WV, VA, SC, NC, TN, KY,
LA, MS, AL, GA, FL, Washington, D.C., MD, DE)
• Westnet: Western US (AZ, CO, ID, NM, UT, WY)
NAPs and MAEs
• NAP = Network Access Point
– originally NFS
• MAE = Metropolitan Area Exchange
– MCI Worldcom has a service mark on this
– Tier-1
• MAE-East (D.C.) and MAE-West (San Jose)
– Tier-2
• LA, Chicago, Dallas, Houston, New York
– Giant LAN switch (FDDI)
DNS
• Function of DNS?
• Function of central registry and what does it
hold.
• Why aren’t we drowning in DNS requests?
• What is a “root domain”, a “fully qualified
domain name”.
Topics
Regulation
• Documentation
– RFCs and STD
• Organizations
–
–
–
–
ISOC (IAB, IESG)
IETF
W3C
InterNic
• IAB Standards Process
Documentation
RFCs
• RFC = Request for Comments
–
–
–
–
series of notes
ARPANET 1969
anyone can write an RFC
two paths
• as Internet Draft
• through IETF
• through RFC Editor
– http://www.rfc-editor.org/
Organizational Hierarchy
ISOC
IAB
IESG
IETF
Working Group
Working Group
Areas
Working Group
Organizations
IETF
• IETF = Internet Engineering Task Force
– technical worker bees
•
•
•
•
•
•
•
•
Applications Area
General Area
Internet Area
Operations and Management Area
Routing Area
Security Area
Transport Area
User Services Area
IAB Standards Process
•
•
•
•
•
Informational
Experimental
Proposed Standard
Draft Standard
Internet Standard
HTTP
Overview
• HyperText Transfer Protocol
• Applications Layer Protocol
– Generic Protocol
• gateway to SMTP, NNTP, FTP, Gopher, WAIS
• Uses TCP Port 80 (by default)
– presumes reliable transport
HTTP
Overview
• Language of the World Wide Web
• Provides Open-Ended Set of Methods
– indicating purpose of request
• Builds on URI, URL, URN disciplines
HTTP
Overview
• URI = Uniform Resource Identifier
–
–
–
–
–
identifies points of content
mechanism used to access resource
specific computer housing the resource
specific name of resource on computer
formatted strings which indicate characteristics
of a resource
HTTP
Overview
• URL = Uniform Resource Locator
– a particular form of URI
– Web page address
• URN = Uniform Resource Name
– institutional persistence
– identifies agency responsible for a definition,
for example, but not the location
HTTP/1.0
• Shortcomings of HTTP/1.0
– weak on proxies, caching, persistent
connections, and virtual hosts
– proliferation of imposters:
• incompletely implemented applications
– stateless
• new connection for each request/response exchange
How HTTP Works
Request/Response Protocol
• Response from server contains …
– status line
• message protocol version
• success or error code
– MIME-like message
• server info
• entity meta-information
• possible entity body content
How HTTP Works
Request/Response Protocol
• More Sophisticated Interactions
– proxies
• forwarding agent
– gateways
• receiving agent
– tunnels
• relay point between two connections
• firewalls
• non-caching
How HTTP Works
Media Types
• Type / Subtype
– followed by 0 or more optional parameters
delimited on the left by “;”
• parameter are of form attribute=value
– Content-type: text/html
– Content-type: text/plain (default)
– Content-Type: multipart/mixed;
boundary=gc0p4Jq0M2Yt08jU534c0p
• Assigned by IANA
HTTP
• Authentication
– .htaccess files
• Secure Sockets Layer (SSL)
– https
– RSA Encryption
• public key / private key
– not really part of HTTP
HTML
• Main Tags
– <html> </html> starts HTML stream
– <head> </head> delimits HEAD of document
– <title> </title> title that appears at top of
browser frame
– <body> </body> delimits document BODY
– <a href=“…URL…”>Text</a> creates a
hyperlink
– <img src=“…”> inserts an image into a file
Misc.
• What is an application server, when would
you use it, when would you not use one?
• What are html “cookies”, what problem do
they solve?
• What is the difference between a Get and a
Post request?
• How is an https page secured?