Network Names – netent
The routines to map network names to numbers and the reverse
return a netent
structure:
/* * Assumes that a network number fits in 32 bits. */ struct netent { char *n_name; /* official name of net */ char **n_aliases; /* alias list */ int n_addrtype; /* net address type */ int n_net; /* net number, host byte order */ };
getnetbyname
(3C),
getnetbyaddr_r
(3C), and
getnetent
(3C) are the network counterparts to the host routines
previously described.