summaryrefslogtreecommitdiffstats
path: root/sys/netinet/in_pcb.h
diff options
context:
space:
mode:
authorandre <andre@FreeBSD.org>2005-08-22 16:13:08 +0000
committerandre <andre@FreeBSD.org>2005-08-22 16:13:08 +0000
commit573a9535a81268ee8fa937d020dad86235127d2c (patch)
treee4fae08b9c2716f53ec0fdfe0bc72046c99f26b9 /sys/netinet/in_pcb.h
parentef76245e903c6da9b4359edf312f385c9d1ab002 (diff)
downloadFreeBSD-src-573a9535a81268ee8fa937d020dad86235127d2c.zip
FreeBSD-src-573a9535a81268ee8fa937d020dad86235127d2c.tar.gz
Add socketoption IP_MINTTL. May be used to set the minimum acceptable
TTL a packet must have when received on a socket. All packets with a lower TTL are silently dropped. Works on already connected/connecting and listening sockets for RAW/UDP/TCP. This option is only really useful when set to 255 preventing packets from outside the directly connected networks reaching local listeners on sockets. Allows userland implementation of 'The Generalized TTL Security Mechanism (GTSM)' according to RFC3682. Examples of such use include the Cisco IOS BGP implementation command "neighbor ttl-security". MFC after: 2 weeks Sponsored by: TCP/IP Optimization Fundraise 2005
Diffstat (limited to 'sys/netinet/in_pcb.h')
-rw-r--r--sys/netinet/in_pcb.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/netinet/in_pcb.h b/sys/netinet/in_pcb.h
index 99e12ad..3d267ae 100644
--- a/sys/netinet/in_pcb.h
+++ b/sys/netinet/in_pcb.h
@@ -133,6 +133,7 @@ struct inpcb {
#define INP_ONESBCAST 0x10 /* send all-ones broadcast */
u_char inp_ip_ttl; /* time to live proto */
u_char inp_ip_p; /* protocol proto */
+ u_char inp_ip_minttl; /* minimum TTL or drop */
/* protocol dependent part; options */
struct {
OpenPOWER on IntegriCloud