2001-12-11 02:57:48 +03:00
|
|
|
.\" $NetBSD: pppoectl.8,v 1.2 2001/12/10 23:57:48 wiz Exp $
|
2001-01-06 16:00:10 +03:00
|
|
|
.\" Copyright (C) 1997 by Joerg Wunsch, Dresden
|
|
|
|
.\" All rights reserved.
|
|
|
|
.\"
|
|
|
|
.\" Redistribution and use in source and binary forms, with or without
|
|
|
|
.\" modification, are permitted provided that the following conditions
|
|
|
|
.\" are met:
|
|
|
|
.\" 1. Redistributions of source code must retain the above copyright
|
|
|
|
.\" notice, this list of conditions and the following disclaimer.
|
|
|
|
.\" 2. Redistributions in binary form must reproduce the above copyright
|
|
|
|
.\" notice, this list of conditions and the following disclaimer in the
|
|
|
|
.\" documentation and/or other materials provided with the distribution.
|
|
|
|
.\"
|
|
|
|
.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS
|
|
|
|
.\" OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
|
|
|
.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
|
|
.\" DISCLAIMED. IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT,
|
|
|
|
.\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
|
|
|
|
.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
|
|
.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|
|
|
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
|
|
|
|
.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
|
|
|
.\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
|
|
|
.\" POSSIBILITY OF SUCH DAMAGE.
|
|
|
|
.\"
|
|
|
|
.\" From: spppcontrol.1,v 1.1.1.1 1997/10/11 11:30:30 joerg Exp
|
|
|
|
.\"
|
2001-12-11 02:57:48 +03:00
|
|
|
.\" $Id: pppoectl.8,v 1.2 2001/12/10 23:57:48 wiz Exp $
|
2001-01-06 16:00:10 +03:00
|
|
|
.\"
|
|
|
|
.\" last edit-date: [Thu Aug 31 10:47:33 2000]
|
|
|
|
.\"
|
2001-12-11 02:57:48 +03:00
|
|
|
.Dd December 11, 2001
|
2001-01-06 16:00:10 +03:00
|
|
|
.Os
|
2001-12-10 20:22:09 +03:00
|
|
|
.Dt PPPOECTL 8
|
2001-01-06 16:00:10 +03:00
|
|
|
.Sh NAME
|
2001-12-10 20:22:09 +03:00
|
|
|
.Nm pppoectl ,
|
|
|
|
.Nm ispppcontrol
|
2001-12-11 02:57:48 +03:00
|
|
|
.Nd "display or set parameters for an pppoe or isdn ppp (isp) interface"
|
2001-01-06 16:00:10 +03:00
|
|
|
.Sh SYNOPSIS
|
|
|
|
.Nm
|
|
|
|
.Op Fl v
|
|
|
|
.Ar ifname
|
|
|
|
.Op Ar parameter Ns Op \&= Ns Ar value
|
|
|
|
.Op Ar ...
|
2001-04-29 14:30:41 +04:00
|
|
|
.Pp
|
|
|
|
.Nm pppoectl
|
|
|
|
.Fl e Ar ethernet-ifname
|
|
|
|
.Op Fl s Ar service-name
|
|
|
|
.Op Fl a Ar access-concentrator-name
|
|
|
|
.Ar ifname
|
2001-01-06 16:00:10 +03:00
|
|
|
.Sh DESCRIPTION
|
2001-04-29 14:30:41 +04:00
|
|
|
There are two basic modes of operation: configuring security related
|
|
|
|
parameters and attaching a PPPoE interface to its ethernet interface,
|
2001-04-29 14:46:02 +04:00
|
|
|
optionally passing in additional parameters for the PPPoE encapsulation.
|
2001-04-29 14:30:41 +04:00
|
|
|
.Pp
|
2001-04-29 14:46:02 +04:00
|
|
|
The later usage is indicated by the presence of the
|
2001-04-29 14:30:41 +04:00
|
|
|
.Fl e
|
|
|
|
option, which takes the name of the ethernet interface as its argument.
|
|
|
|
.Pp
|
|
|
|
.Bl -tag -width indent
|
|
|
|
.It Fl e
|
|
|
|
specifies the ethernet interface used to communicate with the
|
2001-12-11 02:57:48 +03:00
|
|
|
access concentrator (typically via a DSL modem).
|
2001-04-29 14:30:41 +04:00
|
|
|
.It Fl a
|
|
|
|
specifies the name of the access concentrator.
|
|
|
|
.It Fl s
|
|
|
|
specifies the name of the service connected to.
|
|
|
|
.El
|
|
|
|
.Pp
|
2001-12-11 02:57:48 +03:00
|
|
|
Typically, not both the access concentrator name and the service name are
|
|
|
|
specified.
|
2001-04-29 14:30:41 +04:00
|
|
|
.Pp
|
2001-01-06 16:00:10 +03:00
|
|
|
The
|
2001-04-29 14:46:02 +04:00
|
|
|
.Xr i4bisppp 4
|
2001-01-06 16:00:10 +03:00
|
|
|
driver might require a number of additional arguments or optional
|
|
|
|
parameters besides the settings that can be adjusted with
|
|
|
|
.Xr ifconfig 8 .
|
|
|
|
These are things like authentication protocol parameters, but also
|
|
|
|
other tunable configuration variables. The
|
|
|
|
.Nm
|
|
|
|
utility can be used to display the current settings, or adjust these
|
|
|
|
parameters as required.
|
|
|
|
.Pp
|
|
|
|
For whatever intent
|
|
|
|
.Nm
|
|
|
|
is being called, at least the parameter
|
|
|
|
.Ar ifname
|
|
|
|
needs to be specified, naming the interface for which the settings
|
|
|
|
are to be performed or displayed. Use
|
2001-12-11 02:57:48 +03:00
|
|
|
.Xr ifconfig 8
|
2001-01-06 16:00:10 +03:00
|
|
|
or
|
|
|
|
.Xr netstat 1
|
|
|
|
to see which interfaces are available.
|
|
|
|
.Pp
|
|
|
|
If no other parameter is given,
|
|
|
|
.Nm
|
|
|
|
will just list the current settings for
|
|
|
|
.Ar ifname
|
|
|
|
and exit. The reported settings include the current PPP phase the
|
|
|
|
interface is in, which can be one of the names
|
|
|
|
.Em dead ,
|
|
|
|
.Em establish ,
|
|
|
|
.Em authenticate ,
|
|
|
|
.Em network ,
|
|
|
|
or
|
|
|
|
.Em terminate .
|
|
|
|
If an authentication protocol is configured for the interface, the
|
|
|
|
name of the protocol to be used, as well as the system name to be used
|
|
|
|
or expected will be displayed, plus any possible options to the
|
|
|
|
authentication protocol if applicable. Note that the authentication
|
|
|
|
secrets (sometimes also called
|
|
|
|
.Em keys )
|
|
|
|
are not being returned by the underlying system call, and are thus not
|
|
|
|
displayed.
|
|
|
|
.Pp
|
|
|
|
If any additional parameter is supplied, superuser privileges are
|
|
|
|
required, and the command works in
|
|
|
|
.Ql set
|
|
|
|
mode. This is normally done quietly, unless the option
|
|
|
|
.Fl v
|
|
|
|
is also enabled, which will cause a final printout of the settings as
|
|
|
|
described above once all other actions have been taken. Use of this
|
|
|
|
mode will be rejected if the interface is currently in any other phase
|
|
|
|
than
|
|
|
|
.Em dead .
|
|
|
|
Note that you can force an interface into
|
|
|
|
.Em dead
|
|
|
|
phase by calling
|
|
|
|
.Xr ifconfig 8
|
|
|
|
with the parameter
|
|
|
|
.Ql down .
|
|
|
|
.Pp
|
|
|
|
The currently supported parameters include:
|
2001-12-11 02:57:48 +03:00
|
|
|
.Bl -tag -width xxxxxxxxxxxxxxxxxxxxxxxxx
|
2001-01-06 16:00:10 +03:00
|
|
|
.It Ar authproto Ns \&= Ns Em protoname
|
2001-12-11 02:57:48 +03:00
|
|
|
Set both his and my authentication protocol to
|
2001-01-06 16:00:10 +03:00
|
|
|
.Em protoname .
|
|
|
|
The protocol name can be one of
|
|
|
|
.Ql chap ,
|
|
|
|
.Ql pap ,
|
|
|
|
or
|
|
|
|
.Ql none .
|
|
|
|
In the latter case, the use of an authentication protocol will be
|
|
|
|
turned off for the named interface. This has the side-effect of
|
|
|
|
clearing the other authentication-related parameters for this
|
|
|
|
interface as well (i. e., system name and authentication secret will
|
|
|
|
be forgotten).
|
|
|
|
.It Ar myauthproto Ns \&= Ns Em protoname
|
|
|
|
Same as above, but only for my end of the link. I. e., this is the
|
|
|
|
protocol when remote is authenticator, and I am the peer required to
|
|
|
|
authenticate.
|
|
|
|
.It Ar hisauthproto Ns \&= Ns Em protoname
|
|
|
|
Same as above, but only for his end of the link.
|
|
|
|
.It Ar myauthname Ns \&= Ns Em name
|
|
|
|
Set my system name for the authentication protocol.
|
|
|
|
.It Ar hisauthname Ns \&= Ns Em name
|
|
|
|
Set his system name for the authentication protocol. For CHAP, this
|
|
|
|
will only be used as a hint, causing a warning message if remote did
|
|
|
|
supply a different name. For PAP, it's the name remote must use to
|
|
|
|
authenticate himself (in connection with his secret).
|
|
|
|
.It Ar myauthsecret Ns \&= Ns Em secret
|
|
|
|
Set my secret (key, password) for use in the authentication phase.
|
|
|
|
For CHAP, this will be used to compute the response hash value, based
|
|
|
|
on remote's challenge. For PAP, it will be transmitted as plaintext
|
|
|
|
together with the system name. Don't forget to quote the secrets from
|
|
|
|
the shell if they contain shell metacharacters (or white space).
|
|
|
|
.It Ar myauthkey Ns \&= Ns Em secret
|
|
|
|
Same as above.
|
|
|
|
.It Ar hisauthsecret Ns \&= Ns Em secret
|
|
|
|
Same as above, to be used if we are authenticator and the remote peer
|
|
|
|
needs to authenticate.
|
|
|
|
.It Ar hisauthkey Ns \&= Ns Em secret
|
|
|
|
Same as above.
|
|
|
|
.It Ar callin
|
|
|
|
Require remote to authenticate himself only when he's calling in, but
|
|
|
|
not when we are caller. This is required for some peers that do not
|
|
|
|
implement the authentication protocols symmetrically (like Ascend
|
|
|
|
routers, for example).
|
|
|
|
.It Ar always
|
|
|
|
The opposite of
|
|
|
|
.Ar callin .
|
|
|
|
Require remote to always authenticate, regardless of which side is
|
|
|
|
placing the call. This is the default, and will not be explicitly
|
|
|
|
displayed in
|
|
|
|
.Ql list
|
|
|
|
mode.
|
|
|
|
.It Ar norechallenge
|
|
|
|
Only meaningful with CHAP. Do not re-challenge peer once the initial
|
|
|
|
CHAP handshake was successful. Used to work around broken peer
|
|
|
|
implementations that can't grok being re-challenged once the
|
|
|
|
connection is up.
|
|
|
|
.It Ar rechallenge
|
|
|
|
With CHAP, send re-challenges at random intervals while the connection
|
|
|
|
is in network phase. (The intervals are currently in the range of 300
|
|
|
|
through approximately 800 seconds.) This is the default, and will not
|
|
|
|
be explicitly displayed in
|
|
|
|
.Ql list
|
|
|
|
mode.
|
|
|
|
.It Ar lcp-timeout Ns \&= Ns Em timeout-value
|
|
|
|
Allows to change the value of the LCP timeout. The default value of the
|
|
|
|
LCP timeout is currently set to 3 seconds which is too high for some
|
2001-12-11 02:57:48 +03:00
|
|
|
remote PPP implementations. The timeout-value must be specified in
|
|
|
|
milliseconds.
|
2001-01-06 16:00:10 +03:00
|
|
|
.It Ar enable-vj
|
|
|
|
Enable negotiation of Van Jacobsen header compression.
|
|
|
|
.It Ar disable-vj
|
|
|
|
Disable negotiation of Van Jacobsen header compression.
|
|
|
|
.El
|
|
|
|
.Sh EXAMPLES
|
|
|
|
.Bd -literal
|
|
|
|
# ispppcontrol isp0
|
|
|
|
isp0: phase=dead
|
|
|
|
myauthproto=chap myauthname="uriah"
|
|
|
|
hisauthproto=chap hisauthname="ifb-gw" norechallenge
|
|
|
|
lcp timeout: 3.000 s
|
|
|
|
enable_vj: on
|
|
|
|
.Ed
|
|
|
|
.Pp
|
2001-04-29 14:46:02 +04:00
|
|
|
Display the settings for isp0. The interface is currently in
|
2001-01-06 16:00:10 +03:00
|
|
|
.Em dead
|
|
|
|
phase, i. e. the LCP layer is down, and no traffic is possible. Both
|
|
|
|
ends of the connection use the CHAP protocol, my end tells remote the
|
|
|
|
system name
|
|
|
|
.Ql uriah ,
|
|
|
|
and remote is expected to authenticate by the name
|
|
|
|
.Ql ifb-gw .
|
|
|
|
Once the initial CHAP handshake was successful, no further CHAP
|
|
|
|
challenges will be transmitted. There are supposedly some known CHAP
|
|
|
|
secrets for both ends of the link which are not being shown.
|
|
|
|
.Pp
|
|
|
|
.Bd -literal
|
|
|
|
# ispppcontrol isp0 \e
|
|
|
|
authproto=chap \e
|
|
|
|
myauthname=uriah myauthsecret='some secret' \e
|
|
|
|
hisauthname=ifb-gw hisauthsecret='another' \e
|
|
|
|
norechallenge
|
|
|
|
.Ed
|
|
|
|
.Pp
|
|
|
|
A possible call to
|
|
|
|
.Nm
|
|
|
|
that could have been used to bring the interface into the state shown
|
|
|
|
by the previous example.
|
2001-04-29 15:41:02 +04:00
|
|
|
.Pp
|
|
|
|
The following example is the complete sequence of commands to bring
|
2001-12-11 02:57:48 +03:00
|
|
|
a PPPoE connection up:
|
2001-04-29 15:41:02 +04:00
|
|
|
.Bd -literal
|
|
|
|
# Need ethernet interface UP (or it won't send any packets)
|
|
|
|
ifconfig ne0 up
|
|
|
|
|
2001-12-11 02:57:48 +03:00
|
|
|
# Let pppoe0 use ne0 as its ethernet interface
|
2001-04-29 15:41:02 +04:00
|
|
|
pppoectl -e ne0 pppoe0
|
|
|
|
|
|
|
|
# Configure authentication
|
|
|
|
pppoectl pppoe0 \\
|
|
|
|
myauthproto=pap \\
|
|
|
|
myauthname=XXXXX \\
|
|
|
|
myauthsecret=YYYYY \\
|
|
|
|
hisauthproto=none
|
|
|
|
|
2001-12-11 02:57:48 +03:00
|
|
|
# Configure the pppoe0 interface itself. These addresses are magic,
|
2001-04-29 15:41:02 +04:00
|
|
|
# meaning we don't care about either address and let the remote
|
|
|
|
# ppp choose them.
|
|
|
|
ifconfig pppoe0 0.0.0.0 0.0.0.1 up
|
|
|
|
.Ed
|
2001-01-06 16:00:10 +03:00
|
|
|
.Sh SEE ALSO
|
|
|
|
.Xr netstat 1 ,
|
|
|
|
.Xr i4bisppp 4 ,
|
|
|
|
.Xr ifconfig 8
|
|
|
|
.Rs
|
2001-04-29 14:46:02 +04:00
|
|
|
.%A B. Lloyd
|
|
|
|
.%A W. Simpson
|
2001-01-06 16:00:10 +03:00
|
|
|
.%T "PPP Authentication Protocols"
|
|
|
|
.%O RFC 1334
|
|
|
|
.Re
|
|
|
|
.Rs
|
|
|
|
.%A W. Simpson, Editor
|
|
|
|
.%T "The Point-to-Point Protocol (PPP)"
|
|
|
|
.%O RFC 1661
|
|
|
|
.Re
|
|
|
|
.Rs
|
|
|
|
.%A W. Simpson
|
|
|
|
.%T "PPP Challenge Handshake Authentication Protocol (CHAP)"
|
|
|
|
.%O RFC 1994
|
|
|
|
.Re
|
2001-04-29 14:30:41 +04:00
|
|
|
.Rs
|
2001-04-29 14:46:02 +04:00
|
|
|
.%A L. Mamakos
|
|
|
|
.%A K. Lidl
|
|
|
|
.%A J. Evarts
|
|
|
|
.%A D. Carrel
|
|
|
|
.%A D. Simone
|
|
|
|
.%A R. Wheeler
|
2001-04-29 14:30:41 +04:00
|
|
|
.%T "A Method for Transmitting PPP Over Ethernet (PPPoE)"
|
|
|
|
.%O RFC 2516
|
|
|
|
.Re
|
2001-01-06 16:00:10 +03:00
|
|
|
.Sh HISTORY
|
|
|
|
The
|
|
|
|
.Nm
|
2001-04-29 14:46:02 +04:00
|
|
|
utility is based on the
|
2001-04-04 15:18:07 +04:00
|
|
|
.Ic spppcontrol
|
2001-01-06 16:00:10 +03:00
|
|
|
utility which appeared in
|
|
|
|
.Fx 3.0 .
|
2001-04-29 14:46:02 +04:00
|
|
|
.Sh AUTHORS
|
2001-01-06 16:00:10 +03:00
|
|
|
The program was written by
|
|
|
|
.ie t J\(:org Wunsch,
|
|
|
|
.el Joerg Wunsch,
|
2001-12-11 02:57:48 +03:00
|
|
|
Dresden, and modified for PPPoE support by Martin Husemann.
|