CSE 80 -- Lecture 14 -- Feb 20

I talked about the International Standards Organization's Open System Internetworking Reference Model (ISO OSI RM) and how TCP/IP (roughly) fits in.

I mentioned the files /etc/services as a list of service name to well-known port number mappings. You should look at it. Also, the file /etc/inetd.conf is the configuration file for inetd, the master daemon, which spawns lesser daemons only when clients connect. The goal is to save resources such as virtual memory and process table slots that would otherwise be taken up by the lesser daemons if they were long lived and waited around to accept client requests. By materializing the lesser daemons on demand (when client connections arrive), the inetd designers traded off start-up time (the lesser daemons must go through whatever initialization is needed every time they materialize) for system resources.

The finger protocol is probably one of the simplest. To see how it works, run the command $ telnet work.ucsd.edu finger and type in bsy on a line by itself. The finger daemon, in.fingerd, is spawned by inetd when the telnet program connects to the finger port (79), and the socket is connected to the standard input and output of the finger daemon. When you type in a line of text, the telnet program sends that over the network connection, and the finger daemon reads it in and passes it on to the finger program after generating some system log entries. The output of the finger program is first filtered so that lines end with CR-LF (the network line termination convention is different from the Unix LF-only convention), and then written out in.fingerd's standard output, the socket.

Assignment 5: Use the command $ telnet work.ucsd.edu smtp to talk to the SMTP (Simple Mail Transfer Protocol) daemon on my workstation. Use the HELP command, the MAIL, and RCPT commands to forge email to me so that by inspecting the email headers, the email would appear to be from your favorite cartoon character. You should identify yourself in the body of the email so you can properly receive credit.

[ CSE 80 | ACS home | CSE home | CSE calendar | bsy's home page ]
picture of bsy

bsy@cse.ucsd.edu, last updated Tue Mar 18 15:49:39 PST 1997.

email bsy