remarkable-linux/net
Hannes Frederic Sowa 218774dc34 ipv6: add anti-spoofing checks for 6to4 and 6rd
This patch adds anti-spoofing checks in sit.c as specified in RFC3964
section 5.2 for 6to4 and RFC5969 section 12 for 6rd. I left out the
checks which could easily be implemented with netfilter.

Specifically this patch adds following logic (based loosely on the
pseudocode in RFC3964 section 5.2):

if prefix (inner_src_v6) == rd6_prefix (2002::/16 is the default)
        and outer_src_v4 != embedded_ipv4 (inner_src_v6)
                drop
if prefix (inner_dst_v6) == rd6_prefix (or 2002::/16 is the default)
        and outer_dst_v4 != embedded_ipv4 (inner_dst_v6)
                drop
accept

To accomplish the specified security checks proposed by above RFCs,
it is still necessary to employ uRPF filters with netfilter. These new
checks only kick in if the employed addresses are within the 2002::/16 or
another range specified by the 6rd-prefix (which defaults to 2002::/16).

Cc: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2013-01-29 15:22:03 -05:00
..
9p
802
8021q ethtool: fix drvinfo strings set in drivers 2013-01-06 21:06:31 -08:00
appletalk
atm
ax25
batman-adv batman-adv: Start new development cycle 2013-01-19 21:18:13 +08:00
bluetooth Bluetooth: Check if the hci connection exists in SCO shutdown 2013-01-10 03:53:32 -02:00
bridge Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2013-01-15 15:05:59 -05:00
caif
can can: rework skb reserved data handling 2013-01-28 18:17:25 -05:00
ceph Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client 2013-01-02 17:32:49 -08:00
core pktgen: support net namespace 2013-01-29 15:17:46 -05:00
dcb
dccp
decnet decnet: use correct RCU API to deref sk_dst_cache field 2013-01-28 00:15:27 -05:00
dns_resolver
dsa dsa: make dsa_switch_setup check for valid port names 2013-01-21 15:40:12 -05:00
ethernet net: split eth_mac_addr for better error handling 2013-01-21 14:07:44 -05:00
ieee802154 6lowpan: Handle uncompressed IPv6 packets over 6LoWPAN 2013-01-18 14:18:30 -05:00
ipv4 ip_gre: When TOS is inherited, use configured TOS value for non-IP packets 2013-01-29 14:05:28 -05:00
ipv6 ipv6: add anti-spoofing checks for 6to4 and 6rd 2013-01-29 15:22:03 -05:00
ipx
irda irda: buffer overflow in irnet_ctrl_read() 2013-01-27 20:38:19 -05:00
iucv s390/irq: remove split irq fields from /proc/stat 2013-01-08 10:57:07 +01:00
key
l2tp
lapb
llc
mac80211 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless 2013-01-28 13:54:03 -05:00
mac802154 mac802154: fix NOHZ local_softirq_pending 08 warning 2013-01-04 13:47:21 -08:00
netfilter netfilter: nf_conntrack: fix compilation if sysctl are disabled 2013-01-23 15:14:31 +01:00
netlabel
netlink netlink: Use FIELD_SIZEOF() in netlink_proto_init(). 2013-01-09 23:38:23 -08:00
netrom
nfc NFC: Use skb_copy_datagram_iovec 2013-01-11 14:56:32 +01:00
openvswitch openvswitch: Use FIELD_SIZEOF() in dp_init(). 2013-01-09 23:38:24 -08:00
packet
phonet
rds
rfkill
rose
rxrpc rxrpc: Use FIELD_SIZEOF() in af_rxrpc_init(). 2013-01-09 23:38:24 -08:00
sched pkt_sched: namespace aware act_mirred 2013-01-14 15:09:36 -05:00
sctp Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2013-01-15 15:05:59 -05:00
sunrpc NFS client bugfixe for Linux 3.8 2013-01-11 12:09:04 -08:00
tipc
unix unix: Use FIELD_SIZEOF() in af_unix_init(). 2013-01-09 23:38:24 -08:00
wanrouter
wimax
wireless Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next into for-davem 2013-01-28 14:43:00 -05:00
x25
xfrm xfrm: use separated locks to protect pointers of struct xfrm_state_afinfo 2013-01-17 10:03:57 +01:00
compat.c
Kconfig net: Add support for XPS without sysfs being defined 2013-01-10 22:47:04 -08:00
Makefile
nonet.c
socket.c
sysctl_net.c