xref: /freebsd/sbin/nos-tun/nos-tun.8 (revision 7f3dea244c40159a41ab22da77a434d7c5b5e85a)
1.\"
2.\" ----------------------------------------------------------------------------
3.\" "THE BEER-WARE LICENSE" (Revision 42):
4.\" <phk@FreeBSD.org> wrote this file.  As long as you retain this notice you
5.\" can do whatever you want with this stuff. If we meet some day, and you think
6.\" this stuff is worth it, you can buy me a beer in return.   Poul-Henning Kamp
7.\" ----------------------------------------------------------------------------
8.\"
9.\" $FreeBSD$
10.\"
11.Dd April 11, 1998
12.Dt NOS-TUN 8
13.Os FreeBSD 3.0
14.Sh NAME
15.Nm nos-tun
16.Nd implement ``nos'' or ``ka9q'' style IP over IP tunnel
17.Sh SYNOPSIS
18.Nm nos-tun
19.Fl t
20.Ar tunnel
21.Fl s
22.Ar source
23.Fl d
24.Ar destination
25.Fl p
26.Ar protocol_number
27.Ar target
28.Sh DESCRIPTION
29.Nm Nos-tun
30is used to establish an
31.Em nos
32style tunnel, (also known as
33.Em ka9q
34or
35.Em IP-IP
36tunnel) using a
37.Xr tun 4
38kernel interface.
39.Pp
40.Ar Tunnel
41is the name of the tunnel device
42.Pa /dev/tun0
43for example.
44.Pp
45.Ar Source
46and
47.Ar destination
48are the addresses used on the tunnel device.
49If you configure the tunnel against a cisco router, use a netmask of
50.Dq 255.255.255.252
51on the cisco.  This is because the tunnel is a point-to-point interface
52in the
53.Bx Free
54end, a concept cisco doesn't really implement.
55.Pp
56.Ar Protocol number
57sets tunnel mode. Original KA9Q NOS uses 94 but many peoples use 4
58in worldwide backbone of ampr.org.
59.Pp
60.Ar Target
61is the address of the remote tunnel device, this must match the source
62address set on the remote end.
63.Sh EXAMPLES
64This end, a
65.Bx Free
66box on address 192.168.59.34:
67.Bd -literal -offset indent 4m
68nos-tun -t /dev/tun0 -s 192.168.61.1 -d 192.168.61.2 192.168.56.45
69.Ed
70.Pp
71Remote cisco on address 192.168.56.45:
72.Bd -literal -offset indent 4m
73interface tunnel 0
74ip address 192.168.61.2 255.255.255.252
75tunnel mode nos
76tunnel destination 192.168.59.34
77tunnel source 192.168.56.45
78.Ed
79.Sh BUGS
80We don't allow for setting our source address for multihomed machines.
81.Sh AUTHORS
82.An Nickolay N. Dudorov Aq nnd@itfs.nsk.su
83wrote the program,
84.An Poul-Henning Kamp Aq phk@FreeBSD.org
85wrote the man-page.
86.An Isao SEKI Aq iseki@gongon.com
87added a new flag, IP protocol number.
88