1999-12-08 18:55:39 +00:00
|
|
|
.\" Copyright (c) 1996-1999 Whistle Communications, Inc.
|
|
|
|
.\" All rights reserved.
|
2001-07-14 19:41:16 +00:00
|
|
|
.\"
|
1999-12-08 18:55:39 +00:00
|
|
|
.\" Subject to the following obligations and disclaimer of warranty, use and
|
|
|
|
.\" redistribution of this software, in source or object code forms, with or
|
|
|
|
.\" without modifications are expressly permitted by Whistle Communications;
|
|
|
|
.\" provided, however, that:
|
|
|
|
.\" 1. Any and all reproductions of the source or object code must include the
|
|
|
|
.\" copyright notice above and the following disclaimer of warranties; and
|
|
|
|
.\" 2. No rights are granted, in any manner or form, to use Whistle
|
|
|
|
.\" Communications, Inc. trademarks, including the mark "WHISTLE
|
|
|
|
.\" COMMUNICATIONS" on advertising, endorsements, or otherwise except as
|
|
|
|
.\" such appears in the above copyright notice or in the software.
|
2001-07-14 19:41:16 +00:00
|
|
|
.\"
|
1999-12-08 18:55:39 +00:00
|
|
|
.\" THIS SOFTWARE IS BEING PROVIDED BY WHISTLE COMMUNICATIONS "AS IS", AND
|
|
|
|
.\" TO THE MAXIMUM EXTENT PERMITTED BY LAW, WHISTLE COMMUNICATIONS MAKES NO
|
|
|
|
.\" REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, REGARDING THIS SOFTWARE,
|
|
|
|
.\" INCLUDING WITHOUT LIMITATION, ANY AND ALL IMPLIED WARRANTIES OF
|
|
|
|
.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT.
|
|
|
|
.\" WHISTLE COMMUNICATIONS DOES NOT WARRANT, GUARANTEE, OR MAKE ANY
|
|
|
|
.\" REPRESENTATIONS REGARDING THE USE OF, OR THE RESULTS OF THE USE OF THIS
|
|
|
|
.\" SOFTWARE IN TERMS OF ITS CORRECTNESS, ACCURACY, RELIABILITY OR OTHERWISE.
|
|
|
|
.\" IN NO EVENT SHALL WHISTLE COMMUNICATIONS BE LIABLE FOR ANY DAMAGES
|
|
|
|
.\" RESULTING FROM OR ARISING OUT OF ANY USE OF THIS SOFTWARE, INCLUDING
|
|
|
|
.\" WITHOUT LIMITATION, ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
|
|
|
|
.\" PUNITIVE, OR CONSEQUENTIAL DAMAGES, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
|
|
.\" SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER 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 WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY
|
|
|
|
.\" OF SUCH DAMAGE.
|
2001-07-14 19:41:16 +00:00
|
|
|
.\"
|
2000-10-26 15:30:44 +00:00
|
|
|
.\" Author: Archie Cobbs <archie@FreeBSD.org>
|
1999-12-08 18:55:39 +00:00
|
|
|
.\"
|
|
|
|
.\" $FreeBSD$
|
|
|
|
.\" $Whistle: ng_pptpgre.8,v 1.2 1999/12/08 00:20:53 archie Exp $
|
|
|
|
.\"
|
2001-12-08 16:40:19 +00:00
|
|
|
.Dd December 7, 2001
|
2000-05-04 17:54:37 +00:00
|
|
|
.Dt NG_PPTPGRE 4
|
2001-07-10 15:31:11 +00:00
|
|
|
.Os
|
1999-12-08 18:55:39 +00:00
|
|
|
.Sh NAME
|
|
|
|
.Nm ng_pptpgre
|
2000-03-10 20:38:24 +00:00
|
|
|
.Nd PPTP GRE protocol netgraph node type
|
1999-12-08 18:55:39 +00:00
|
|
|
.Sh SYNOPSIS
|
2001-10-01 16:09:29 +00:00
|
|
|
.In netgraph/ng_pptpgre.h
|
1999-12-08 18:55:39 +00:00
|
|
|
.Sh DESCRIPTION
|
|
|
|
The
|
|
|
|
.Nm pptpgre
|
|
|
|
node type performs Generic Routing Encapsulation (GRE) over IP
|
2001-12-08 16:40:19 +00:00
|
|
|
for the PPTP protocol as specified by RFC 2637.
|
|
|
|
This involves packet
|
2002-03-16 17:56:40 +00:00
|
|
|
encapsulation, sequencing, acknowledgement, and an adaptive timeout
|
2001-12-08 16:40:19 +00:00
|
|
|
sliding window mechanism.
|
|
|
|
This node type does not handle any of
|
1999-12-08 18:55:39 +00:00
|
|
|
the TCP control protocol or call negotiation defined by PPTP.
|
|
|
|
.Pp
|
2000-05-05 01:20:28 +00:00
|
|
|
This node type expects to receive complete IP packets,
|
|
|
|
including the IP header, on the
|
2001-12-08 16:40:19 +00:00
|
|
|
.Dq Li lower
|
2000-05-05 01:20:28 +00:00
|
|
|
hook, but it transmits outgoing frames without any IP header.
|
1999-12-08 18:55:39 +00:00
|
|
|
The typical use for this node type would be to connect the
|
2001-12-08 16:40:19 +00:00
|
|
|
.Dq Li upper
|
1999-12-08 18:55:39 +00:00
|
|
|
hook to one of the link hooks of a
|
2000-05-04 17:54:37 +00:00
|
|
|
.Xr ng_ppp 4
|
1999-12-08 18:55:39 +00:00
|
|
|
node, and the
|
2001-12-08 16:40:19 +00:00
|
|
|
.Dq Li lower
|
1999-12-08 18:55:39 +00:00
|
|
|
hook to the
|
2001-12-08 16:40:19 +00:00
|
|
|
.Dq Li "inet/raw/gre"
|
1999-12-08 18:55:39 +00:00
|
|
|
hook of a
|
2000-05-04 17:54:37 +00:00
|
|
|
.Xr ng_ksocket 4
|
1999-12-08 18:55:39 +00:00
|
|
|
node.
|
|
|
|
.Sh HOOKS
|
|
|
|
This node type supports the following hooks:
|
|
|
|
.Pp
|
2001-12-08 16:40:19 +00:00
|
|
|
.Bl -tag -compact -width ".Li upper"
|
|
|
|
.It Li upper
|
1999-12-08 18:55:39 +00:00
|
|
|
Connection to the upper protocol layers
|
2001-12-08 16:40:19 +00:00
|
|
|
.It Li lower
|
1999-12-08 18:55:39 +00:00
|
|
|
Connection to the lower protocol layers
|
|
|
|
.El
|
|
|
|
.Sh CONTROL MESSAGES
|
|
|
|
This node type supports the generic control messages, plus the following:
|
2001-12-08 16:40:19 +00:00
|
|
|
.Bl -tag -width indent
|
1999-12-08 18:55:39 +00:00
|
|
|
.It Dv NGM_PPTPGRE_SET_CONFIG
|
|
|
|
This command resets and configures the node for a session.
|
|
|
|
This command takes a
|
2001-12-08 16:40:19 +00:00
|
|
|
.Vt "struct ng_pptpgre_conf"
|
1999-12-08 18:55:39 +00:00
|
|
|
as an argument:
|
2001-12-08 16:40:19 +00:00
|
|
|
.Bd -literal
|
1999-12-08 18:55:39 +00:00
|
|
|
/* Configuration for a session */
|
|
|
|
struct ng_pptpgre_conf {
|
|
|
|
u_char enabled; /* enables traffic flow */
|
|
|
|
u_char enableDelayedAck; /* enables delayed acks */
|
2001-12-07 02:50:39 +00:00
|
|
|
u_char enableAlwaysAck; /* always send ack with data */
|
1999-12-08 18:55:39 +00:00
|
|
|
u_int16_t cid; /* my call id */
|
|
|
|
u_int16_t peerCid; /* peer call id */
|
|
|
|
u_int16_t recvWin; /* peer recv window size */
|
|
|
|
u_int16_t peerPpd; /* peer packet processing delay
|
|
|
|
(in 1/10 of a second) */
|
|
|
|
};
|
|
|
|
.Ed
|
2001-12-08 16:40:19 +00:00
|
|
|
.Pp
|
|
|
|
The
|
|
|
|
.Va enabled
|
|
|
|
field enables traffic flow through the node.
|
1999-12-08 18:55:39 +00:00
|
|
|
The
|
2001-12-08 16:40:19 +00:00
|
|
|
.Va enableDelayedAck
|
2002-01-21 12:09:13 +00:00
|
|
|
field enables delayed acknowledgement (maximum 250 milliseconds), which
|
1999-12-08 18:55:39 +00:00
|
|
|
is a useful optimization and should generally be turned on.
|
2001-12-08 16:40:19 +00:00
|
|
|
.Va enableAlwaysAck
|
2001-12-07 02:50:39 +00:00
|
|
|
field enables sending acknowledgements with every data packet, which
|
|
|
|
is probably helpful as well.
|
1999-12-08 18:55:39 +00:00
|
|
|
The remaining fields are as supplied by the PPTP virtual call setup process.
|
|
|
|
.It Dv NGM_PPTPGRE_GET_CONFIG
|
|
|
|
Returns the current configuration as a
|
2001-12-08 16:40:19 +00:00
|
|
|
.Vt "struct ng_pptpgre_conf" .
|
2000-05-05 01:20:28 +00:00
|
|
|
.It Dv NGM_PPTPGRE_GET_STATS
|
|
|
|
This command returns a
|
2001-12-08 16:40:19 +00:00
|
|
|
.Vt "struct ng_pptpgre_stats"
|
2000-05-05 01:20:28 +00:00
|
|
|
containing various node statistics.
|
|
|
|
.It Dv NGM_PPTPGRE_CLR_STATS
|
|
|
|
This command resets the node statistics.
|
|
|
|
.It Dv NGM_PPTPGRE_GETCLR_STATS
|
|
|
|
This command atomically gets and resets the node statistics, returning a
|
2001-12-08 16:40:19 +00:00
|
|
|
.Vt "struct ng_pptpgre_stats" .
|
1999-12-08 18:55:39 +00:00
|
|
|
.El
|
|
|
|
.Sh SHUTDOWN
|
|
|
|
This node shuts down upon receipt of a
|
|
|
|
.Dv NGM_SHUTDOWN
|
|
|
|
control message, or when both hooks have been disconnected.
|
|
|
|
.Sh SEE ALSO
|
|
|
|
.Xr netgraph 4 ,
|
2000-05-04 17:54:37 +00:00
|
|
|
.Xr ng_ksocket 4 ,
|
|
|
|
.Xr ng_ppp 4 ,
|
|
|
|
.Xr ngctl 8
|
1999-12-08 18:55:39 +00:00
|
|
|
.Rs
|
|
|
|
.%A K. Hamzeh
|
|
|
|
.%A G. Pall
|
|
|
|
.%A W. Verthein
|
|
|
|
.%A J. Taarud
|
|
|
|
.%A W. Little
|
|
|
|
.%A G. Zorn
|
|
|
|
.%T "Point-to-Point Tunneling Protocol (PPTP)"
|
|
|
|
.%O RFC 2637
|
|
|
|
.Re
|
1999-12-10 19:29:43 +00:00
|
|
|
.Rs
|
|
|
|
.%A S. Hanks
|
|
|
|
.%A T. \&Li
|
|
|
|
.%A D. Farinacci
|
|
|
|
.%A P. Traina
|
|
|
|
.%T "Generic Routing Encapsulation over IPv4 networks"
|
|
|
|
.%O RFC 1702
|
|
|
|
.Re
|
2000-05-05 01:20:28 +00:00
|
|
|
.Sh BUGS
|
|
|
|
The node should not expect incoming GRE packets to have an IP header.
|
|
|
|
This behavior is inherited from the (converse) behavior of raw IP sockets.
|
|
|
|
An intermediate node that strips IP headers in one direction
|
|
|
|
should be used instead.
|
1999-12-21 01:25:21 +00:00
|
|
|
.Sh HISTORY
|
|
|
|
The
|
|
|
|
.Nm
|
|
|
|
node type was implemented in
|
|
|
|
.Fx 4.0 .
|
2000-05-05 17:08:55 +00:00
|
|
|
.Sh AUTHORS
|
2000-10-26 15:30:44 +00:00
|
|
|
.An Archie Cobbs Aq archie@FreeBSD.org
|