Berkeley Sockets

40
Berkeley Sockets The socket primitives for TCP.

description

Berkeley Sockets. The socket primitives for TCP. Some assigned ports. Port. Protocol. Use. 21. FTP. File transfer. 23. Remote login. Telnet. E-mail. 25. SMTP. 69. Trivial File Transfer Protocol. TFTP. Finger. Lookup info about a user. 79. 80. World Wide Web. HTTP. POP-3. - PowerPoint PPT Presentation

Transcript of Berkeley Sockets

Page 1: Berkeley Sockets

Berkeley Sockets

The socket primitives for TCP.

Page 2: Berkeley Sockets

Port Protocol Use21 FTP File transfer23 Telnet Remote login25 SMTP E-mail69 TFTP Trivial File Transfer Protocol79 Finger Lookup info about a user80 HTTP World Wide Web

110 POP-3 Remote e-mail access119 NNTP USENET news

Some assigned ports.

Page 3: Berkeley Sockets

Headers

(a) Four 512-byte segments sent as separate IP datagrams.(b) The 2048 bytes of data delivered to the application in a single

READ CALL.

Page 4: Berkeley Sockets

Electronic Mail• Architecture and Services• The User Agent• Message Formats• Message Transfer• Final Delivery

Page 5: Berkeley Sockets

Electronic Mail (2)

Some smileys. They will not be on the final exam :-).

Page 6: Berkeley Sockets

Architecture and ServicesBasic functions• Composition• Transfer• Reporting• Displaying• Disposition

Page 7: Berkeley Sockets

The User Agent

Envelopes and messages. (a) Paper mail. (b) Electronic mail.

Page 8: Berkeley Sockets

Reading E-mail

An example display of the contents of a mailbox.

Page 9: Berkeley Sockets

RFC 822 header fields related to message transport.

Page 10: Berkeley Sockets

Electronic Mail (2)

Some smileys. They will not be on the final exam :-).

Page 11: Berkeley Sockets

MIME – Multipurpose Internet Mail Extensions

Problems with international languages:• Languages with accents

(French, German).• Languages in non-Latin alphabets

(Hebrew, Russian).• Languages without alphabets

(Chinese, Japanese).• Messages not containing text at all

(audio or images).

Page 12: Berkeley Sockets

MIME (2)RFC 822 headers added by MIME.

Page 13: Berkeley Sockets

MIME types and subtypes (RFC 2045)

Page 14: Berkeley Sockets

A multipart message containing enriched and audio alternatives.

Page 15: Berkeley Sockets
Page 16: Berkeley Sockets
Page 17: Berkeley Sockets

Message Transfer

Transferring a message from [email protected] to [email protected].

Page 18: Berkeley Sockets

Message Transfer

Transferring a message from [email protected] to [email protected].

Page 19: Berkeley Sockets

Message Transfer

Transferring a message from [email protected] to [email protected].

Page 20: Berkeley Sockets

Final Delivery

(a) Sending and reading mail when the receiver has a permanent Internet connection and the user agent runs on the same machine as the message transfer agent. (b) Reading e-mail when the receiver has a dial-up connection to an ISP.

Page 21: Berkeley Sockets

POP3

Using POP3 to fetch three messages.

Page 22: Berkeley Sockets

IMAPA comparison of POP3 and IMAP.

Page 23: Berkeley Sockets

The World Wide Web• Architectural Overview• Static Web Documents• Dynamic Web Documents• HTTP – The HyperText Transfer

Protocol• Performance Ehnancements• The Wireless Web

Page 24: Berkeley Sockets

Architectural Overview (2)

The parts of the Web model.

Page 25: Berkeley Sockets

The Client Side

(a) A browser plug-in. (b) A helper application.

Page 26: Berkeley Sockets

The Server Side

A multithreaded Web server with a front end and processing modules.

Page 27: Berkeley Sockets

The Server Side (2)

A server farm.

Page 28: Berkeley Sockets

The Server Side (3)

(a) Normal request-reply message sequence.(b) Sequence when TCP handoff is used.

Page 29: Berkeley Sockets

Some common URLs.

Page 30: Berkeley Sockets

Statelessness and Cookies

Some examples of cookies.

Page 31: Berkeley Sockets

HTML – HyperText Markup Language

(a) The HTML for a sample Web page. (b) The formatted page.

(b)

Page 32: Berkeley Sockets

(b)

Page 33: Berkeley Sockets

(b)

Page 34: Berkeley Sockets
Page 35: Berkeley Sockets

XML and XSL

A simple Web page in XML.

Page 36: Berkeley Sockets
Page 37: Berkeley Sockets
Page 38: Berkeley Sockets
Page 39: Berkeley Sockets
Page 40: Berkeley Sockets