Deleted Added
full compact
faith.4 (145358) faith.4 (201870)
1.\" $KAME: faith.4,v 1.9 2001/04/27 17:26:35 itojun Exp $
2.\"
3.\" Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:

--- 13 unchanged lines hidden (view full) ---

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
28.\" SUCH DAMAGE.
29.\"
1.\" $KAME: faith.4,v 1.9 2001/04/27 17:26:35 itojun Exp $
2.\"
3.\" Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
4.\" All rights reserved.
5.\"
6.\" Redistribution and use in source and binary forms, with or without
7.\" modification, are permitted provided that the following conditions
8.\" are met:

--- 13 unchanged lines hidden (view full) ---

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
28.\" SUCH DAMAGE.
29.\"
30.\" $FreeBSD: head/share/man/man4/faith.4 145358 2005-04-21 13:27:13Z suz $
30.\" $FreeBSD: head/share/man/man4/faith.4 201870 2010-01-09 00:24:54Z brueffer $
31.\"
32.Dd April 10, 1999
33.Dt FAITH 4
34.Os
35.Sh NAME
36.Nm faith
37.Nd IPv6-to-IPv4 TCP relay capturing interface
38.Sh SYNOPSIS

--- 14 unchanged lines hidden (view full) ---

53.Xr ifconfig 8
54.Cm create
55command or using the
56.Va cloned_interfaces
57variable in
58.Xr rc.conf 5 .
59.Pp
60Special action will be taken when IPv6 TCP traffic is seen on a router,
31.\"
32.Dd April 10, 1999
33.Dt FAITH 4
34.Os
35.Sh NAME
36.Nm faith
37.Nd IPv6-to-IPv4 TCP relay capturing interface
38.Sh SYNOPSIS

--- 14 unchanged lines hidden (view full) ---

53.Xr ifconfig 8
54.Cm create
55command or using the
56.Va cloned_interfaces
57variable in
58.Xr rc.conf 5 .
59.Pp
60Special action will be taken when IPv6 TCP traffic is seen on a router,
61and routing table suggests to route it to
61and the routing table suggests to route it to the
62.Nm
63interface.
64In this case, the packet will be accepted by the router,
62.Nm
63interface.
64In this case, the packet will be accepted by the router,
65regardless of list of IPv6 interface addresses assigned to the router.
66The packet will be captured by an IPv6 TCP socket, if it has
65regardless of the list of IPv6 interface addresses assigned to the router.
66The packet will be captured by an IPv6 TCP socket, if it has the
67.Dv IN6P_FAITH
67.Dv IN6P_FAITH
68flag turned on and it has matching address/port pairs.
69In result,
68flag turned on and matching address/port pairs.
69As a result,
70.Nm
71will let you capture IPv6 TCP traffic to some specific destination addresses.
72Userland programs, such as
73.Xr faithd 8
74can use this behavior to relay IPv6 TCP traffic to IPv4 TCP traffic.
75The program can accept some specific IPv6 TCP traffic, perform
76.Xr getsockname 2
77to get the IPv6 destination address specified by the client,
78and perform application-specific address mapping to relay IPv6 TCP to IPv4 TCP.
79.Pp
80The
81.Dv IN6P_FAITH
70.Nm
71will let you capture IPv6 TCP traffic to some specific destination addresses.
72Userland programs, such as
73.Xr faithd 8
74can use this behavior to relay IPv6 TCP traffic to IPv4 TCP traffic.
75The program can accept some specific IPv6 TCP traffic, perform
76.Xr getsockname 2
77to get the IPv6 destination address specified by the client,
78and perform application-specific address mapping to relay IPv6 TCP to IPv4 TCP.
79.Pp
80The
81.Dv IN6P_FAITH
82flag on IPv6 TCP socket can be set by using
82flag on a IPv6 TCP socket can be set by using
83.Xr setsockopt 2 ,
83.Xr setsockopt 2 ,
84with level equals to
84with level
85.Dv IPPROTO_IPV6
85.Dv IPPROTO_IPV6
86and optname equals to
86and optname
87.Dv IPv6_FAITH .
88.Pp
87.Dv IPv6_FAITH .
88.Pp
89To handle error reports by ICMPv6, some of ICMPv6 packets routed to
89To handle error reports by ICMPv6, some ICMPv6 packets routed to an
90.Nm
91interface will be delivered to IPv6 TCP, as well.
92.Pp
93To understand how
94.Nm
90.Nm
91interface will be delivered to IPv6 TCP, as well.
92.Pp
93To understand how
94.Nm
95can be used, take a look at source code of
95can be used, take a look at the source code of
96.Xr faithd 8 .
97.Pp
96.Xr faithd 8 .
97.Pp
98As
98As the
99.Nm
99.Nm
100interface implements potentially dangerous operation,
101great care must be taken when configuring
102.Nm
103interface.
104To avoid possible misuse,
100interface implements potentially dangerous operations,
101great care must be taken when configuring it.
102To avoid possible misuse, the
105.Xr sysctl 8
106variable
107.Li net.inet6.ip6.keepfaith
108must be set to
109.Li 1
103.Xr sysctl 8
104variable
105.Li net.inet6.ip6.keepfaith
106must be set to
107.Li 1
110prior to the use of the interface.
108prior to using the interface.
111When
112.Li net.inet6.ip6.keepfaith
113is
114.Li 0 ,
109When
110.Li net.inet6.ip6.keepfaith
111is
112.Li 0 ,
115no packet will be captured by
113no packets will be captured by the
116.Nm
117interface.
118.Pp
114.Nm
115interface.
116.Pp
117The
119.Nm
120interface is intended to be used on routers, not on hosts.
121.\"
122.Sh SEE ALSO
123.Xr inet 4 ,
124.Xr inet6 4 ,
125.Xr faithd 8
126.Rs
127.%A Jun-ichiro itojun Hagino
128.%A Kazu Yamamoto
129.%T "An IPv6-to-IPv4 transport relay translator"
130.%O RFC3142
131.Re
132.Sh HISTORY
118.Nm
119interface is intended to be used on routers, not on hosts.
120.\"
121.Sh SEE ALSO
122.Xr inet 4 ,
123.Xr inet6 4 ,
124.Xr faithd 8
125.Rs
126.%A Jun-ichiro itojun Hagino
127.%A Kazu Yamamoto
128.%T "An IPv6-to-IPv4 transport relay translator"
129.%O RFC3142
130.Re
131.Sh HISTORY
133The FAITH IPv6-to-IPv4 TCP relay translator was first appeared in
132The FAITH IPv6-to-IPv4 TCP relay translator first appeared in the
134WIDE hydrangea IPv6 stack.
133WIDE hydrangea IPv6 stack.