summaryrefslogtreecommitdiffstats
path: root/share/man
diff options
context:
space:
mode:
authorbms <bms@FreeBSD.org>2004-02-11 04:26:04 +0000
committerbms <bms@FreeBSD.org>2004-02-11 04:26:04 +0000
commit903cdeea1a6d0c99fecc1d8aeeab65bdfbab46d7 (patch)
tree7a14054c69fb5681c86f54e9b66a9128c1e16003 /share/man
parentdfc906ec95fc478c611f5ef93b40dc04b3ecb6e8 (diff)
downloadFreeBSD-src-903cdeea1a6d0c99fecc1d8aeeab65bdfbab46d7.zip
FreeBSD-src-903cdeea1a6d0c99fecc1d8aeeab65bdfbab46d7.tar.gz
Initial import of RFC 2385 (TCP-MD5) digest support.
This is the first of two commits; bringing in the kernel support first. This can be enabled by compiling a kernel with options TCP_SIGNATURE and FAST_IPSEC. For the uninitiated, this is a TCP option which provides for a means of authenticating TCP sessions which came into being before IPSEC. It is still relevant today, however, as it is used by many commercial router vendors, particularly with BGP, and as such has become a requirement for interconnect at many major Internet points of presence. Several parts of the TCP and IP headers, including the segment payload, are digested with MD5, including a shared secret. The PF_KEY interface is used to manage the secrets using security associations in the SADB. There is a limitation here in that as there is no way to map a TCP flow per-port back to an SPI without polluting tcpcb or using the SPD; the code to do the latter is unstable at this time. Therefore this code only supports per-host keying granularity. Whilst FAST_IPSEC is mutually exclusive with KAME IPSEC (and thus IPv6), TCP_SIGNATURE applies only to IPv4. For the vast majority of prospective users of this feature, this will not pose any problem. This implementation is output-only; that is, the option is honoured when responding to a host initiating a TCP session, but no effort is made [yet] to authenticate inbound traffic. This is, however, sufficient to interwork with Cisco equipment. Tested with a Cisco 2501 running IOS 12.0(27), and Quagga 0.96.4 with local patches. Patches for tcpdump to validate TCP-MD5 sessions are also available from me upon request. Sponsored by: sentex.net
Diffstat (limited to 'share/man')
-rw-r--r--share/man/man4/tcp.435
1 files changed, 33 insertions, 2 deletions
diff --git a/share/man/man4/tcp.4 b/share/man/man4/tcp.4
index fc1a7bb..dec8870 100644
--- a/share/man/man4/tcp.4
+++ b/share/man/man4/tcp.4
@@ -121,7 +121,7 @@ supports a number of socket options which can be set with
.Xr setsockopt 2
and tested with
.Xr getsockopt 2 :
-.Bl -tag -width ".Dv TCP_NODELAY"
+.Bl -tag -width ".Dv TCP_SIGNATURE_ENABLE"
.It Dv TCP_NODELAY
Under most circumstances,
.Tn TCP
@@ -175,6 +175,31 @@ When this option is set to a non-zero value,
.Tn TCP
will delay sending any data at all until either the socket is closed,
or the internal send buffer is filled.
+.It Dv TCP_SIGNATURE_ENABLE
+This option enables the use of MD5 digests (also known as TCP-MD5)
+on writes to the specified socket.
+In the current release, only outgoing traffic is digested;
+digests on incoming traffic are not verified.
+The current default behavior for the system is to respond to a system
+advertising this option with TCP-MD5; this may change.
+.Pp
+One common use for this in a FreeBSD router deployment is to enable
+based routers to interwork with Cisco equipment at peering points.
+Support for this feature conforms to RFC 2385.
+Only IPv4 (AF_INET) sessions are supported.
+.Pp
+In order for this option to function correctly, it is necessary for the
+administrator to add a tcp-md5 key entry to the system's security
+associations database (SADB) using the
+.Xr setkey 8
+utility.
+This entry must have an SPI of 0x1000 and can therefore only be specified
+on a per-host basis at this time.
+.Pp
+If an SADB entry cannot be found for the destination, the outgoing traffic
+will have an invalid digest option prepended, and the following error message
+will be visible on the system console:
+.Em "tcpsignature_compute: SADB lookup failed for %d.%d.%d.%d" .
.El
.Pp
The option level for the
@@ -489,7 +514,8 @@ address.
.Xr intro 4 ,
.Xr ip 4 ,
.Xr syncache 4 ,
-.Xr ttcp 4
+.Xr ttcp 4 ,
+.Xr setkey 8
.Rs
.%A "V. Jacobson"
.%A "R. Braden"
@@ -502,6 +528,11 @@ address.
.%T "T/TCP \- TCP Extensions for Transactions"
.%O "RFC 1644"
.Re
+.Rs
+.%A "A. Heffernan"
+.%T "Protection of BGP Sessions via the TCP MD5 Signature Option"
+.%O "RFC 2385"
+.Re
.Sh HISTORY
The
.Tn TCP
OpenPOWER on IntegriCloud