1
play

1 Mail access protocols DNS: Domain Name System SMTP SMTP access - PDF document

FTP: separate control, data connections TCP control connection FTP client contacts FTP port 21 server at port 21, specifying TCP as transport protocol TCP data connection FTP, SMTP and DNS Client obtains authorization FTP FTP port


  1. FTP: separate control, data connections TCP control connection ❒ FTP client contacts FTP port 21 server at port 21, specifying TCP as transport protocol TCP data connection FTP, SMTP and DNS ❒ Client obtains authorization FTP FTP port 20 over control connection client server ❒ Client browses remote ❒ Server opens a second TCP directory by sending data connection to transfer commands over control connection. another file. ❒ When server receives a ❒ Control connection: “out of command for a file transfer, band” the server opens a TCP data ❒ FTP server maintains connection to client “state”: current directory, ❒ After transferring one file, earlier authentication server closes connection. 2: Application Layer 2: Application Layer 1 2 Electronic Mail Electronic Mail: mail servers outgoing message queue user mailbox Three major components: user user Mail Servers agent agent ❒ user agents mail ❒ mailbox contains incoming mail user ❒ mail servers user server agent messages for user server agent ❒ simple mail transfer SMTP SMTP ❒ message queue of outgoing mail protocol: SMTP mail server user (to be sent) mail messages server user SMTP agent SMTP agent User Agent ❒ SMTP protocol between SMTP mail servers to send email ❒ a.k.a. “mail reader” SMTP user user mail messages mail ❒ composing, editing, reading agent server agent server mail messages ❍ client: sending mail user ❒ e.g., Eudora, Outlook, elm, server user agent Netscape Messenger agent ❍ “server”: receiving mail user user ❒ outgoing, incoming messages agent server agent stored on server 2: Application Layer 2: Application Layer 3 4 Scenario: Alice sends message to Bob Electronic Mail: SMTP [RFC 2821] 1) Alice uses UA to compose 4) SMTP client sends Alice’s message and “to” message over the TCP ❒ uses TCP to reliably transfer email message from client connection bob@someschool.edu to server, port 25 2) Alice’s UA sends message 5) Bob’s mail server places ❒ direct transfer: sending server to receiving server to her mail server; the message in Bob’s ❒ three phases of transfer message placed in message mailbox ❍ handshaking (greeting) queue 6) Bob invokes his user agent ❍ transfer of messages 3) Client side of SMTP opens to read message ❍ closure TCP connection with Bob’s mail server ❒ command/response interaction 1 mail ❍ commands: ASCII text mail user user server server ❍ response: status code and phrase 2 agent agent 3 6 4 5 ❒ messages must be in 7-bit ASCII 2: Application Layer 5 2: Application Layer 6 1

  2. Mail access protocols DNS: Domain Name System SMTP SMTP access Domain Name System: People: many identifiers: user user protocol agent ❒ distributed database agent ❍ SSN, name, passport # implemented in hierarchy of Internet hosts, routers: receiver’s mail many name servers sender’s mail server server ❒ application-layer protocol ❍ IP address (32 bit) - ❒ SMTP: delivery/storage to receiver’s server host, routers, name servers used for addressing to communicate to resolve ❒ Mail access protocol: retrieval from server datagrams names (address/name ❍ POP: Post Office Protocol [RFC 1939] ❍ “name”, e.g., translation) • authorization (agent <-->server) and download ww.yahoo.com - used by ❍ note: core Internet humans ❍ IMAP: Internet Mail Access Protocol [RFC 1730] function, implemented as application-layer protocol Q: map between IP • more features (more complex) ❍ complexity at network’s addresses and name ? • manipulation of stored msgs on server “edge” ❍ HTTP: Hotmail , Yahoo! Mail, etc. 2: Application Layer 2: Application Layer 7 8 DNS and Applications DNS ❒ Which applications use DNS? Why not centralize DNS? ❒ single point of failure ❒ HTTP ❒ traffic volume ❍ Browser extracts hostname ❒ distant centralized database ❍ Sends hostname to DNS ❒ maintenance ❍ DNS does lookup and returns IP address ❍ Browser sends HTTP GET to IP address doesn’t scale! 2: Application Layer 2: Application Layer 9 10 Distributed, Hierarchical Database DNS: Root name servers Root DNS Servers ❒ contacted by local name server that can not resolve name ❒ root name server: org DNS servers edu DNS servers com DNS servers ❍ contacts authoritative name server if name mapping not known ❍ gets mapping poly.edu umass.edu pbs.org yahoo.com amazon.com DNS servers DNS servers DNS servers ❍ returns mapping to local name server DNS servers DNS servers a Verisign, Dulles, VA c Cogent, Herndon, VA (also Los Client wants IP for www.amazon.com; 1 st approx: Angeles) k RIPE London (also Amsterdam, d U Maryland College Park, MD Frankfurt) i Autonomica, Stockholm g US DoD Vienna, VA ❒ Client queries a root server to find com DNS (plus 3 other locations) h ARL Aberdeen, MD j Verisign, ( 11 locations) m WIDE Tokyo server e NASA Mt View, CA f Internet Software C. Palo Alto, CA (and 17 other locations) ❒ Client queries com DNS server to get amazon.com 13 root name DNS server servers worldwide b USC-ISI Marina del Rey, CA ❒ Client queries amazon.com DNS server to get IP l ICANN Los Angeles, CA address for www.amazon.com 2: Application Layer 11 2: Application Layer 12 2

  3. TLD and Authoritative Servers Local Name Server ❒ Top-level domain (TLD) servers: responsible ❒ Does not strictly belong to hierarchy for com, org, net, edu, etc, and all top-level ❒ Each ISP (residential ISP, company, country domains uk, fr, ca, jp. university) has one. ❍ Network solutions maintains servers for com TLD ❍ Also called “default name server” ❍ Educause for edu TLD ❒ When a host makes a DNS query, query is ❒ Authoritative DNS servers: organization’s sent to its local DNS server DNS servers, providing authoritative hostname to IP mappings for organization’s ❍ Acts as a proxy, forwards query into hierarchy. servers (e.g., Web and mail). ❍ Can be maintained by organization or service provider 2: Application Layer 2: Application Layer 13 14 Example Recursive queries root DNS server root DNS server 2 recursive query: ❒ Host at cis.poly.edu 3 2 3 TLD DNS server ❒ puts burden of name wants IP address 4 6 resolution on 7 for gaia.cs.umass.edu 5 TLD DNS server contacted name server local DNS server local DNS server dns.poly.edu ❒ heavy load? 4 6 5 7 dns.poly.edu 1 8 iterated query: 1 8 authoritative DNS server ❒ contacted server dns.cs.umass.edu authoritative DNS server replies with name of requesting host dns.cs.umass.edu server to contact requesting host cis.poly.edu cis.poly.edu ❒ “I don’t know this gaia.cs.umass.edu name, but ask this gaia.cs.umass.edu server” 2: Application Layer 2: Application Layer 15 16 DNS: caching and updating records DNS records DNS: distributed db storing resource records (RR) ❒ once (any) name server learns mapping, it caches mapping RR format: (name, value, type, ttl) ❍ cache entries timeout (disappear) after some ❒ Type=A ❒ Type=CNAME time ❍ name is hostname ❍ name is alias name for some ❍ TLD servers typically cached in local name “cannonical” (the real) name ❍ value is IP address servers ❒ Type=NS www.ibm.com is really • Thus root name servers not often visited ❍ name is domain (e.g. servereast.backup2.ibm.com ❒ update/notify mechanisms under design by IETF ❍ value is cannonical name foo.com) ❒ Type=MX ❍ RFC 2136 ❍ value is IP address of authoritative name ❍ value is name of mailserver ❍ http://www.ietf.org/html.charters/dnsind-charter.html server for this domain associated with name 2: Application Layer 17 2: Application Layer 18 3

Recommend


More recommend