unixdev.net


Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (FreeBSD-5.4-RELEASE)
Page:
Section:
Apropos / Subsearch:
optional field

SLIPLOGIN(8)              BSD System Manager's Manual             SLIPLOGIN(8)

NAME
     sliplogin -- attach a serial line network interface

SYNOPSIS
     sliplogin [loginname [device]]

DESCRIPTION
     The sliplogin utility is used to turn the terminal line on standard input
     (or device) into a Serial Line IP (SLIP) link to a remote host.  To do
     this, the program searches the file /etc/sliphome/slip.hosts for an entry
     matching loginname (which defaults to the current login name if omitted).
     If a matching entry is found, the line is configured appropriately for
     slip (8-bit transparent i/o) and converted to SLIP line discipline using
     the optional line discipline parameters.

     The optional line discipline parameters consist of one or more of the
     following; 'normal', 'compress', 'noicmp', or 'autocomp' which correspond
     respectively to 'use normal line discipline' (no header compression),
     'enable VJ header compression', 'throw away ICMP packets', and 'auto
     enable VJ header compression' (only if the remote end of the link also
     supports it).

     Then a shell script is invoked to initialize the slip interface with the
     appropriate local and remote IP address, netmask, etc.

     The usual initialization script is /etc/sliphome/slip.login but, if par-
     ticular hosts need special initialization, the file
     /etc/sliphome/slip.login.loginname will be executed instead if it exists.
     The script is invoked with the parameters

     slipunit  The unit number of the slip interface assigned to this line.
               E.g., 0 for sl0.

     speed     The speed of the line.

     args      The arguments from the /etc/sliphome/slip.hosts entry, in order
               starting with loginname.

     Only the super-user may attach a network interface.  The interface is
     automatically detached when the other end hangs up or the sliplogin
     process dies.  If the kernel slip module has been configured for it, all
     routes through that interface will also disappear at the same time.  If
     there is other processing a site would like done on hangup, the file
     /etc/sliphome/slip.logout or /etc/sliphome/slip.logout.loginname is exe-
     cuted if it exists.  It is given the same arguments as the login script.

   Format of /etc/sliphome/slip.hosts
     Comments (lines starting with a `#') and blank lines (or started with
     space) are ignored.  Other lines must start with a loginname but the
     remaining arguments can be whatever is appropriate for the slip.login
     file that will be executed for that name.  Arguments are separated by
     white space and follow normal sh(1) quoting conventions (however,
     loginname cannot be quoted).  Usually, lines have the form

           loginname local-address remote-address netmask opt-args

     where local-address and remote-address are the IP host names or addresses
     of the local and remote ends of the slip line and netmask is the appro-
     priate IP netmask.  These arguments are passed directly to ifconfig(8).
     Opt-args are optional arguments used to configure the line.

FreeBSD Additions
     An additional SLIP configuration file (if present) is
     /etc/sliphome/slip.slparms.  If particular hosts need different configu-
     rations, the file /etc/sliphome/slip.slparms.loginname will be parsed
     instead if it exists.

   Format of /etc/sliphome/slip.slparms*
     Comments (lines starting with a `#') and blank lines (or started with
     space) are ignored.  This file contains from one to three numeric parame-
     ters separated with spaces, in order: keepalive, outfill and slunit.

     keepalive  Set SLIP "keep alive" timeout in seconds.  If FRAME_END is not
                received in this amount of time, sliplogin closes the line and
                exits.  The default value is no timeout (zero).

     outfill    Set SLIP "out fill" timeout in seconds.  It forces at least
                one FRAME_END to be sent during this time period, which is
                necessary for the "keep alive" timeout on the remote side.
                The default value is no timeout (zero).

     slunit     Set the SLIP unit number directly.  Use with caution, because
                no check is made for two interfaces with same number.  By
                default sliplogin dynamically assigns the unit number.

     If latter two parameters are omitted, they will not affect the corre-
     sponding SLIP configuration.  If any of first two parameters is equal to
     zero, it will not affect the corresponding SLIP configuration.

EXAMPLES
     The normal use of sliplogin is to create a /etc/passwd entry for each
     legal, remote slip site with sliplogin as the shell for that entry.
     E.g.,

     Sfoo:ikhuy6:2010:1:slip line to foo:/tmp:/usr/sbin/sliplogin

     (Our convention is to name the account used by remote host hostname as
     Shostname.)  Then an entry is added to slip.hosts that looks like:

           Sfoo    `hostname`      foo     netmask

     where `hostname` will be evaluated by sh(1) to the local host name and
     netmask is the local host IP netmask.

     Note that sliplogin must be setuid to root and, while not a security
     hole, moral defectives can use it to place terminal lines in an unusable
     state and/or deny access to legitimate users of a remote slip line.  To
     prevent this, sliplogin is installed as user root, group network and mode
     4550 so that only members of group network may run sliplogin.  The system
     administrator should make sure that all legitimate users are a member of
     the correct group.

DIAGNOSTICS
     The sliplogin utility logs various information to the system log daemon,
     syslogd(8), with a facility code of daemon.  The messages are listed
     here, grouped by severity level.

     Error Severity
     ioctl (TCGETS): reason
             A TCGETS ioctl() to get the line parameters failed.

     ioctl (TCSETS): reason
             A TCSETS ioctl() to set the line parameters failed.

     /etc/sliphome/slip.hosts: reason
             The /etc/sliphome/slip.hosts file could not be opened.

     access denied for user
             No entry for user was found in /etc/sliphome/slip.hosts.

     Notice Severity
     attaching slip unit unit for loginname
             SLIP unit unit was successfully attached.

FILES
     /etc/sliphome/slip.hosts
             list of host login names and parameters.

     /etc/sliphome/slip.login
             script executed when a connection is made.

     /etc/sliphome/slip.login.loginname
             script executed when a connection is made by loginname.

     /etc/sliphome/slip.logout
             script executed when a connection is lost.

     /etc/sliphome/slip.logout.loginname
             script executed when a connection is lost by loginname.

     /etc/sliphome/slip.slparms
             extra parameters file.

     /etc/sliphome/slip.slparms.loginname
             extra parameters file for loginname.

     /var/run/ttyXn.if
             contains the name of the network interface used by the sliplogin
             process on ttyXn.

     /var/run/slX.pid
             contains the PID of the sliplogin process which is using inter-
             face slX.

SEE ALSO
     slattach(8), syslogd(8)

     /usr/share/examples/sliplogin

HISTORY
     The sliplogin utility appeared in 4.3BSD-Reno.

BSD                             January 5, 1994                            BSD