1 / 33

Petros KAVASSALIS

Computer Networks and Communications [Δίκτυα Υπολογιστών και Επικοινωνίες] Lectures 10-13: Back to applications… The e-mail app. Univ. of the Aegean Financial and Management Engineering Dpt. Petros KAVASSALIS. What you will learn in this course.

jayme
Télécharger la présentation

Petros KAVASSALIS

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Computer Networks and Communications[Δίκτυα Υπολογιστών και Επικοινωνίες]Lectures 10-13: Back to applications… The e-mail app.Univ. of the Aegean Financial and Management Engineering Dpt Petros KAVASSALIS

  2. What you will learn in this course • A set of fundamental concepts for understanding Data Networks and the Internet • What is the Internet? • Internet architecture and layers • Internet applications and services • New concepts in the evolution of the Internet • The Internet goes Wireless… • Familiarization with the structure and organization of Digital Networks • Business and Social Networks • Electronic Markets and Online Feedback Mechanisms

  3. Who am I? • PhDinEconomicsandManagement (Univ. ParisDauphine & Ecolepolytechnique) • Research experience • Ecolepolytechnique, Paris • MIT CenterofTechnologyPolicyandIndustrialDevelopment, MIT CTPID (MIT Internet TelecommunicationsConvergenceConsortium) • Current positions • Univ. of the Aegean (FME): Assoc. Professor • RACTI: Director of ATLANTIS Group

  4. Communication tools • e-mail: pkavassalis [at] atlantis-group.gr • Course web site: see fme website

  5. Course Textbook[http://books.google.gr/books?id=Pd-z64SJRBAC&dq=tanenbaum+networks&printsec=frontcover&source=bn&hl=el&ei=ml-dSfH9L4S2jAeJ5L3ZBQ&sa=X&oi=book_result&resnum=4&ct=result]

  6. Supplementary Texts & References William Stallings, Computer Networking with Internet Protocols, Prentice Hall, 2004 James F. Kurose and Keith W. Ross, Computer Networking: A Top-Down Approach, Addison-Wesley, 2008

  7. Students evaluation • Class Participation (20%) + • Assignments (20%) + • Final Exam (60%)

  8. Reminder (1): Overview of the Internet The structure of the Internet is roughly hierarchical

  9. Reminder (2): A network architecture

  10. Reminder (3): TCP/IP in practice

  11. application transport network data link physical application transport network data link physical application transport network data link physical Create a network app Write programs that • Run on (different) end systems • Communicate over network • Think about that: Server software communicates with browser software No need to write software for network-core devices • Network-core devices do not run user applications • Applications on end systems allows for rapid app development, propagation 11

  12. Application architectures Client-server Peer-to-peer (P2P) Hybrid of client-server and P2P

  13. client/server Client-server Server: • Always-on host • Permanent IP address • Server farms for scaling Clients: • Communicate with server • May be intermittently connected • May have dynamic IP addresses • Do not communicate directly with each other

  14. peer-peer P2P • No always-on server • Arbitrary end systems directly communicate • peers are intermittently connected and change IP addresse • **** Highly scalable but difficult to manage

  15. Hybrid Skype • voice-over-IP P2P application • centralized server: finding address of remote party: • client-client connection: direct (not through server) Instant messaging • chatting between two users is P2P • centralized service: client presence detection/location • user registers its IP address with central server when it comes online • user contacts central server to find IP addresses of buddies

  16. An Internet application example: e-mail • Most heavily used application on any network • Protocols • Simple Mail Transfer Protocol (SMTP) • TCP/IP • Delivery of simple text messages • Multi-purpose Internet Mail Extension (MIME) • Delivery of other types of data • Voice, images, video clips

  17. SMTP • RFC 821 (please locate the document!) • Not concerned with format of messages or data • Covered in RFC 822 (see later) • SMTP uses info written on envelope of mail • Message header • Does not look at contents • Message body • Mail created by user agent program (mail client): Message consists of: • Header containing recipient’s address and other info • Body containing user data • Messages queued and sent as input to SMTP sender program • Typically a server process (daemon on UNIX)

  18. Mail message content • Each queued message has: • Message text • RFC 822 header with message envelope and list of recipients • Message body, composed by user • A list of mail destinations • Derived by user agent from header • May be listed in header • May require expansion of mailing lists • May need replacement of mnemonic names with mailbox names

  19. Mail example Date: Tue 19 May 2008 10:37:17 (EST) From: “PetrosKavassalis” <petros@cfp.mit.edu> Subject: XroniaPolla To: el……@gmail.com Cc: petros@cfp.mit.edu Follows the main text, delimited from the header by a blank line • Message viewed as having envelope and contents • Envelope contains information required to transmit and deliver message • Message is sequence of lines of text

  20. Mail structure SMTP: protocol for exchanging email msgs RFC 821+822: standard for text message format: • header lines, e.g., • To: • From: • Subject: • body • the “message”, ASCII characters only header blank line body

  21. SMTP operation architecture

  22. SMTP Sender • Takes message from queue • Transmits to proper destination host • Via SMTP transaction • Over one or more TCP connections to port 25 • Host may have multiple senders active • Host should be able to create receivers on demand • When delivery complete, sender deletes destination from list for that message • When all destinations processed, message is deleted

  23. Room for optimization • If message destined for multiple users on a given host • It is sent only once • = Delivery to users handled at destination host • If multiple messages ready for given host • a single TCP connection can be used • = Saves overhead of setting up and dropping connection

  24. SMTP reliability Used to transfer messages from sender to receiver over TCP connection Attempts to provide reliable service No guarantee to recover lost messages No end to end acknowledgement to originator Error indication delivery not guaranteed Generally considered reliable

  25. SMTP Receiver • Accepts arriving message • Places in user mailbox or copies to outgoing queue for forwarding • Receiver must: • Verify local mail destinations • Deal with errors • Transmission • Lack of disk space • Sender responsible for message until receiver confirm complete transfer • Indicates mail has arrived at host, not user

  26. SMTP Forwarding and Conversation • Mostly direct transfer from sender host to receiver host • May go through intermediate machine via forwarding capability • Sender can specify route • Target user may have moved • SMTP limited to conversation between sender and receiver • Main function is to transfer messages • Rest of mail handling beyond scope of SMTP • May differ between systems

  27. Main operations (1) • Connection setup • Exchange of command-response pairs • Connection termination • Connection setup • Sender opens TCP connection with receiver • Once connected, receiver identifies itself • Sender identifies itself • Receiver accepts sender’s identification • (If mail service not available, step 2 above becomes: service not available)

  28. Main operations (2) • Connection setup • Exchange of command-response pairs • Connection termination • Exchange of command-response pairs • Sender may send one or more messages to receiver • MAIL command identifies originator • Gives reverse path to used for error reporting • Receiver returns 250 OK or appropriate fail/error message • One or more RCPT commands identifies recipients for the message • Separate reply for each recipient • DATA command transfers message text • End of message indicated by line containing just period (.)

  29. Main operations (3) • Connection setup • Exchange of command-response pairs • Connection termination • Connection termination • Sender sends QUIT and waits for reply • Then initiate TCP close operation • Receiver initiates TCP close after sending reply to QUIT

  30. user agent user agent sender’s mail server SMTP Mail access protocols SMTP access protocol receiver’s mail server • SMTP: delivery/storage to receiver’s server • Mail access protocol: retrieval from server • POP: Post Office Protocol [RFC 1939] • authorization (agent <-->server) and download • IMAP: Internet Mail Access Protocol [RFC 1730] • more features (more complex) • manipulation of stored msgs on server • HTTP: gmail, Hotmail, Yahoo! Mail, etc.

  31. MIME • Extension to RFC822 • SMTP can not transmit executables • Uuencode and other schemes are available • Not standardized • Can not transmit text including international characters (e.g. â, å, ä, è, é, ê, ë) • Need 8 bit ASCII • Servers may reject mail over certain size • Translation between ASCII and EBCDIC not standard • Some SMTP implementations do not adhere to standard • CRLF, truncate or wrap long lines, removal of white space, etc.

  32. MIME in a nutshell From: alice@crepes.fr To: bob@hamburger.edu Subject: Picture of yummy crepe. MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Type: image/jpeg base64 encoded data ..... ......................... ......base64 encoded data • Five new message header fields • MIME version • Content type • Content transfer encoding • Content Id • Content Description • Number of content formats defines • Transfer encoding defined

  33. Content types • Text body • Multipart • Mixed, Parallel, Alternative, Digest • Message • RFC 822, Partial, External-body • Image • jpeg, gif • Video • mpeg • Audio • Basic • Application • Postscript • octet stream

More Related