An application usually uses the default transport search path set by the system administrator to locate an available transport. However, when a user wants to influence the choices made by an application, the application can modify the interface by using the environment variable
NETPATH and the routines described in the section, "NETPATH Access to netconfig(4) Data". These routines access only the transports specified in the
NETPATH is similar to the
PATH variable. It is a colon-separated list of transport IDs. Each transport ID in the
NETPATH variable corresponds to the network ID field
of a record in the netconfig(4) file.
NETPATH is described in the environ(4) man page.
The default transport set is different for the routines that access netconfig(4) through the NETPATH environment variable (described in the next section) and the routines that access netconfig(4) directly. The default transport set for routines that access netconfig(4) via NETPATH consists of the visible transports in the netconfig(4) file. For routines that access netconfig(4) directly, the default transport set is the entire netconfig(4) file. A transport is visible if the system administrator has included a v flag in the flags field of that transport's netconfig(4) entry.