[Next] [Previous] [Up] [Top] [Contents]

19.3 Services

19.3.2 /etc/inetd

The internet services daemon, inetd, is started in the RC scripts. Inetd responds to requests for services on your machine. It monitors the services specified in /etc/inetd.conf and uses the corresponding ports and protocol specified in /etc/services. For each service specified in the services database there is a corresponding entry in the inetd.conf file. So for the above example with the telnet service there will be a corresponding entry in inetd.conf to start the telnet service when a request is received on the network port 23. This entry will be:

telnet stream tcp nowait root /usr/etc/in.telnetd in.telnetd

Inetd starts up the required daemon to respond to the request for the specified port. After the connection is made (e.g. at port 23 for telnetd) the transaction is moved to some higher port number. Port numbers 0->1023 are considered "trusted ports" and can only be monitored by root. Each connection is identified by a set of 2-32-bit numbers and 2-16-bit numbers:

Host number of connection's origination

Port number of connection's origination

Host number of connection's target

Port number of connection's target

Unix System Administration - 8 AUG 1996
[Next] [Previous] [Up] [Top] [Contents]