/etc/services
is a plain ASCII file providing a
mapping between friendly textual names for internet services, and their
underlying assigned port numbers and protocol types. Every networking
program should look into this file to get the port number (and protocol)
for its service. Port numbers are assigned by the IANA (Internet Assigned
Numbers Authority), and their current policy is to assign both TCP and UDP
protocols when assigning a port number. Therefore, most entries will have
two entries, even for TCP only services. Port numbers below 1024
(so-called 'low numbered' ports) can only be bound to by root (see
bind(2), tcp(7), and udp(7).) This is so that clients connecting to low
numbered ports can trust that the service running on the port is the
standard implementation, and not a rogue service run by a user of the
machine. Well-known port numbers specified by the IANA are normally
located in this root only space. The presence of an entry for a service in
the services file does not necessarily mean that the service is currently
running on the machine. See inetd.conf(5) for the configuration of
Internet services offered. Note that not all networking services are
started by inetd(8), and so won't appear in inetd.conf(5). In
particular, news (NNTP) and mail (SMTP) servers are often initialised from
the system boot scripts.