xref: /freebsd/share/man/man4/ng_cisco.4 (revision 1e413cf93298b5b97441a21d9a50fdcd0ee9945e)
1.\" Copyright (c) 1996-1999 Whistle Communications, Inc.
2.\" All rights reserved.
3.\"
4.\" Subject to the following obligations and disclaimer of warranty, use and
5.\" redistribution of this software, in source or object code forms, with or
6.\" without modifications are expressly permitted by Whistle Communications;
7.\" provided, however, that:
8.\" 1. Any and all reproductions of the source or object code must include the
9.\"    copyright notice above and the following disclaimer of warranties; and
10.\" 2. No rights are granted, in any manner or form, to use Whistle
11.\"    Communications, Inc. trademarks, including the mark "WHISTLE
12.\"    COMMUNICATIONS" on advertising, endorsements, or otherwise except as
13.\"    such appears in the above copyright notice or in the software.
14.\"
15.\" THIS SOFTWARE IS BEING PROVIDED BY WHISTLE COMMUNICATIONS "AS IS", AND
16.\" TO THE MAXIMUM EXTENT PERMITTED BY LAW, WHISTLE COMMUNICATIONS MAKES NO
17.\" REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, REGARDING THIS SOFTWARE,
18.\" INCLUDING WITHOUT LIMITATION, ANY AND ALL IMPLIED WARRANTIES OF
19.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT.
20.\" WHISTLE COMMUNICATIONS DOES NOT WARRANT, GUARANTEE, OR MAKE ANY
21.\" REPRESENTATIONS REGARDING THE USE OF, OR THE RESULTS OF THE USE OF THIS
22.\" SOFTWARE IN TERMS OF ITS CORRECTNESS, ACCURACY, RELIABILITY OR OTHERWISE.
23.\" IN NO EVENT SHALL WHISTLE COMMUNICATIONS BE LIABLE FOR ANY DAMAGES
24.\" RESULTING FROM OR ARISING OUT OF ANY USE OF THIS SOFTWARE, INCLUDING
25.\" WITHOUT LIMITATION, ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
26.\" PUNITIVE, OR CONSEQUENTIAL DAMAGES, PROCUREMENT OF SUBSTITUTE GOODS OR
27.\" SERVICES, LOSS OF USE, DATA OR PROFITS, HOWEVER CAUSED AND UNDER ANY
28.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30.\" THIS SOFTWARE, EVEN IF WHISTLE COMMUNICATIONS IS ADVISED OF THE POSSIBILITY
31.\" OF SUCH DAMAGE.
32.\"
33.\" Author: Archie Cobbs <archie@FreeBSD.org>
34.\"
35.\" $FreeBSD$
36.\" $Whistle: ng_cisco.8,v 1.5 1999/01/25 23:46:26 archie Exp $
37.\"
38.Dd January 19, 1999
39.Dt NG_CISCO 4
40.Os
41.Sh NAME
42.Nm ng_cisco
43.Nd Cisco HDLC protocol netgraph node type
44.Sh SYNOPSIS
45.In sys/types.h
46.In netinet/in.h
47.In netgraph/ng_cisco.h
48.Sh DESCRIPTION
49The
50.Nm cisco
51node type performs encapsulation and de-encapsulation of packets
52using the Cisco HDLC protocol.
53This is a fairly simple
54protocol for the transmission of packets across
55high speed synchronous lines.
56Each packet is prepended with
57an Ethertype, indicating the protocol.
58There is also a
59.Dq keep alive
60and an
61.Dq inquire
62capability.
63.Pp
64The
65.Dv downstream
66hook should connect to the synchronous line.
67On the other side
68of the node are the
69.Dv inet ,
70.Dv inet6 ,
71.Dv atalk ,
72and
73.Dv ipx
74hooks, which transmit and receive raw IP, IPv6, AppleTalk, and IPX packets,
75respectively.
76Typically these hooks would connect to the corresponding
77hooks on an
78.Xr ng_iface 4
79type node.
80.Sh IP Configuration
81In order to function properly for IP traffic, the node must be informed
82of the local IP address and netmask setting.
83This is because the protocol
84includes an
85.Dq inquire
86packet which we must be prepared to answer.
87There are two ways to accomplish this, manually and automatically.
88.Pp
89Whenever such an inquire packet is received, the node sends a
90.Dv NGM_CISCO_GET_IPADDR
91control message to the peer node connected to the
92.Dv inet
93hook (if any).
94If the peer responds, then that response is used.
95This is the automatic method.
96.Pp
97If the peer does not respond, the node falls back on its cached value
98for the IP address and netmask.
99This cached value can be set at any time
100with a
101.Dv NGM_CISCO_SET_IPADDR
102message, and this is the manual method.
103.Pp
104If the
105.Dv inet
106hook is connected to the
107.Dv inet
108hook of an
109.Xr ng_iface 4
110node, as is usually the case, then configuration is automatic as the
111.Xr ng_iface 4
112understands the
113.Dv NGM_CISCO_GET_IPADDR
114message.
115.Sh HOOKS
116This node type supports the following hooks:
117.Pp
118.Bl -tag -width foobarbazio
119.It Dv downstream
120The connection to the synchronous line.
121.It Dv inet
122IP hook.
123.It Dv inet6
124IPv6 hook.
125.It Dv atalk
126AppleTalk hook.
127.It Dv ipx
128IPX hook
129.El
130.Sh CONTROL MESSAGES
131This node type supports the generic control messages, plus the following:
132.Bl -tag -width foo
133.It Dv NGM_CISCO_SET_IPADDR
134This command takes an array of two
135.Dv "struct in_addr"
136arguments.
137The first is the IP address of the corresponding interface
138and the second is the netmask.
139.It Dv NGM_CISCO_GET_IPADDR
140This command returns the IP configuration in the same format used by
141.Dv NGM_CISCO_SET_IPADDR .
142This command is also
143.Em sent
144by this node type to the
145.Dv inet
146peer whenever an IP address inquiry packet is received.
147.It Dv NGM_CISCO_GET_STATUS
148Returns a
149.Dv "struct ngciscostat" :
150.Bd -literal -offset 4n
151struct ngciscostat {
152  u_int32_t   seq_retries;       /* # unack'd retries */
153  u_int32_t   keepalive_period;  /* in seconds */
154};
155.Ed
156.El
157.Sh SHUTDOWN
158This node shuts down upon receipt of a
159.Dv NGM_SHUTDOWN
160control message, or when all hooks have been disconnected.
161.Sh SEE ALSO
162.Xr netgraph 4 ,
163.Xr ng_iface 4 ,
164.Xr ngctl 8
165.Rs
166.%A D. Perkins
167.%T "Requirements for an Internet Standard Point-to-Point Protocol"
168.%O RFC 1547
169.Re
170.Sh LEGAL
171.Tn Cisco
172is a trademark of Cisco Systems, Inc.
173.Sh HISTORY
174The
175.Nm
176node type was implemented in
177.Fx 4.0 .
178.Sh AUTHORS
179.An Julian Elischer Aq julian@FreeBSD.org ,
180.An Archie Cobbs Aq archie@FreeBSD.org
181.Sh BUGS
182Not all of the functionality has been implemented.
183For example,
184the node does not support querying the remote end for its IP address
185and netmask.
186