1 .\" $NetBSD: sliplogin.8,v 1.8 2002/02/02 01:51:20 wiz Exp $
3 .\" Copyright (c) 1990, 1991, 1993
4 .\" The Regents of the University of California. All rights reserved.
6 .\" Redistribution and use in source and binary forms, with or without
7 .\" modification, are permitted provided that the following conditions
9 .\" 1. Redistributions of source code must retain the above copyright
10 .\" notice, this list of conditions and the following disclaimer.
11 .\" 2. Redistributions in binary form must reproduce the above copyright
12 .\" notice, this list of conditions and the following disclaimer in the
13 .\" documentation and/or other materials provided with the distribution.
14 .\" 3. Neither the name of the University nor the names of its contributors
15 .\" may be used to endorse or promote products derived from this software
16 .\" without specific prior written permission.
18 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
19 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
22 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
24 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
27 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 .\" from: @(#)sliplogin.8 8.2 (Berkeley) 1/5/94
37 .Nd attach a serial line network interface
43 is used to turn the terminal line on standard input into
46 link to a remote host. To do this, the program
48 .Pa /etc/sliphome/slip.hosts
51 (which defaults to the current login name if omitted).
52 If a matching entry is found, the line is configured appropriately
53 for slip (8-bit transparent i/o) and converted to
56 discipline. Then a shell script is invoked to initialize the slip
57 interface with the appropriate local and remote
62 The usual initialization script is
63 .Pa /etc/sliphome/slip.login
64 but, if particular hosts need special initialization, the file
65 .Pa /etc/sliphome/slip.login. Ns Ar loginname
66 will be executed instead if it exists.
67 The script is invoked with the parameters
68 .Bl -tag -width slipunit
70 The unit number of the slip interface assigned to this line. E.g.,
75 The speed of the line.
77 The arguments from the
78 .Pa /etc/sliphome/slip.hosts
79 entry, in order starting with
83 Only the super-user may attach a network interface. The interface is
84 automatically detached when the other end hangs up or the
86 process dies. If the kernel slip
87 module has been configured for it, all routes through that interface will
88 also disappear at the same time. If there is other processing a site
89 would like done on hangup, the file
90 .Pa /etc/sliphome/slip.logout
92 .Pa /etc/sliphome/slip.logout. Ns Ar loginname
93 is executed if it exists. It is given the same arguments as the login script.
94 .Ss Format of /etc/sliphome/slip.hosts
95 Comments (lines starting with a `#') and blank lines are ignored.
96 Other lines must start with a
98 but the remaining arguments can be whatever is appropriate for the
100 file that will be executed for that name.
101 Arguments are separated by white space and follow normal
103 quoting conventions (however,
106 Usually, lines have the form
107 .Bd -literal -offset indent
108 loginname local-address remote-address netmask opt-args
115 are the IP host names or addresses of the local and remote ends of the
118 is the appropriate IP netmask. These arguments are passed
122 are optional arguments used to configure the line.
128 entry for each legal, remote slip site with
130 as the shell for that entry. E.g.,
132 Sfoo:ikhuy6:2010:1:slip line to foo:/tmp:/usr/sbin/sliplogin
135 (Our convention is to name the account used by remote host
139 Then an entry is added to
143 .Bd -literal -offset indent -compact
144 Sfoo `hostname` foo netmask
151 to the local host name and
153 is the local host IP netmask.
157 must be setuid to root and, while not a security hole, moral defectives
158 can use it to place terminal lines in an unusable state and/or deny
159 access to legitimate users of a remote slip line. To prevent this,
160 a site can create a group, say
162 that only the slip login accounts are put in then make sure that
163 .Pa /usr/sbin/sliplogin
166 and mode 4550 (setuid root, only group
171 logs various information to the system log daemon,
173 with a facility code of
175 The messages are listed here, grouped by severity level.
178 .Bl -tag -width Ds -compact
179 .It Sy ioctl (TCGETS): Em reason
183 to get the line parameters failed.
185 .It Sy ioctl (TCSETS): Em reason
189 to set the line parameters failed.
191 .It Sy /etc/sliphome/slip.hosts: Em reason
193 .Pa /etc/sliphome/slip.hosts
194 file could not be opened.
196 .It Sy access denied for Em user
200 .Pa /etc/sliphome/slip.hosts .
204 .Bl -tag -width Ds -compact
205 .It Sy "attaching slip unit" Em unit Sy for Ar loginname
209 was successfully attached.