<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/net/ipv6/sit.c, branch linux-2.6.33.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.33.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.33.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2011-03-21T19:45:36Z</updated>
<entry>
<title>net: don't allow CAP_NET_ADMIN to load non-netdev kernel modules</title>
<updated>2011-03-21T19:45:36Z</updated>
<author>
<name>Vasiliy Kulikov</name>
</author>
<published>2011-03-01T21:33:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=430681f49ab17c025d631d80436143286436a828'/>
<id>urn:sha1:430681f49ab17c025d631d80436143286436a828</id>
<content type='text'>
commit 8909c9ad8ff03611c9c96c9a92656213e4bb495b upstream.

Since a8f80e8ff94ecba629542d9b4b5f5a8ee3eb565c any process with
CAP_NET_ADMIN may load any module from /lib/modules/.  This doesn't mean
that CAP_NET_ADMIN is a superset of CAP_SYS_MODULE as modules are
limited to /lib/modules/**.  However, CAP_NET_ADMIN capability shouldn't
allow anybody load any module not related to networking.

This patch restricts an ability of autoloading modules to netdev modules
with explicit aliases.  This fixes CVE-2011-1019.

Arnd Bergmann suggested to leave untouched the old pre-v2.6.32 behavior
of loading netdev modules by name (without any prefix) for processes
with CAP_SYS_MODULE to maintain the compatibility with network scripts
that use autoloading netdev modules by aliases like "eth0", "wlan0".

Currently there are only three users of the feature in the upstream
kernel: ipip, ip_gre and sit.

    root@albatros:~# capsh --drop=$(seq -s, 0 11),$(seq -s, 13 34) --
    root@albatros:~# grep Cap /proc/$$/status
    CapInh:	0000000000000000
    CapPrm:	fffffff800001000
    CapEff:	fffffff800001000
    CapBnd:	fffffff800001000
    root@albatros:~# modprobe xfs
    FATAL: Error inserting xfs
    (/lib/modules/2.6.38-rc6-00001-g2bf4ca3/kernel/fs/xfs/xfs.ko): Operation not permitted
    root@albatros:~# lsmod | grep xfs
    root@albatros:~# ifconfig xfs
    xfs: error fetching interface information: Device not found
    root@albatros:~# lsmod | grep xfs
    root@albatros:~# lsmod | grep sit
    root@albatros:~# ifconfig sit
    sit: error fetching interface information: Device not found
    root@albatros:~# lsmod | grep sit
    root@albatros:~# ifconfig sit0
    sit0      Link encap:IPv6-in-IPv4
	      NOARP  MTU:1480  Metric:1

    root@albatros:~# lsmod | grep sit
    sit                    10457  0
    tunnel4                 2957  1 sit

For CAP_SYS_MODULE module loading is still relaxed:

    root@albatros:~# grep Cap /proc/$$/status
    CapInh:	0000000000000000
    CapPrm:	ffffffffffffffff
    CapEff:	ffffffffffffffff
    CapBnd:	ffffffffffffffff
    root@albatros:~# ifconfig xfs
    xfs: error fetching interface information: Device not found
    root@albatros:~# lsmod | grep xfs
    xfs                   745319  0

Reference: https://lkml.org/lkml/2011/2/24/203

Signed-off-by: Vasiliy Kulikov &lt;segoon@openwall.com&gt;
Signed-off-by: Michael Tokarev &lt;mjt@tls.msk.ru&gt;
Acked-by: David S. Miller &lt;davem@davemloft.net&gt;
Acked-by: Kees Cook &lt;kees.cook@canonical.com&gt;
Signed-off-by: James Morris &lt;jmorris@namei.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>net: Simplify ipip6 aka sit pernet operations.</title>
<updated>2009-12-02T00:15:59Z</updated>
<author>
<name>Eric W. Biederman</name>
</author>
<published>2009-11-29T15:46:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=671011720baa222b6de667cd688aed4dc8908924'/>
<id>urn:sha1:671011720baa222b6de667cd688aed4dc8908924</id>
<content type='text'>
Take advantage of the new pernet automatic storage management,
and stop using compatibility network namespace functions.

Signed-off-by: Eric W. Biederman &lt;ebiederm@xmission.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>netns: net_identifiers should be read_mostly</title>
<updated>2009-11-18T13:03:25Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2009-11-17T10:42:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f99189b186f3922ede4fa33c02f6edc735b8c981'/>
<id>urn:sha1:f99189b186f3922ede4fa33c02f6edc735b8c981</id>
<content type='text'>
Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>sit: Clean up DF code by copying from IPIP</title>
<updated>2009-11-11T04:54:43Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2009-11-09T08:42:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=292f4f3ce4b57f17a667cb34c72bca081dcc0281'/>
<id>urn:sha1:292f4f3ce4b57f17a667cb34c72bca081dcc0281</id>
<content type='text'>
This patch rearranges the SIT DF bit handling using the new IPIP DF
code.  The only externally visible effect should be the case where
PMTU is enabled and the MTU is exactly 1280 bytes.  In this case the
previous code would send packets out with DF off while the new code
would set the DF bit.  This is inline with RFC 4213.

Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;

Thanks,
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ipv6 sit: Optimize multiple unregistration</title>
<updated>2009-10-29T08:13:51Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2009-10-28T04:37:43Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=62808f91237181dbac74c2b5be4fa92adfbbbe40'/>
<id>urn:sha1:62808f91237181dbac74c2b5be4fa92adfbbbe40</id>
<content type='text'>
Speedup module unloading by factorizing synchronize_rcu() calls

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ipv6 sit: RCU conversion phase II</title>
<updated>2009-10-24T13:07:56Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2009-10-23T17:52:14Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4543c10de267bdd4f9acdb7708456909ed7eed3c'/>
<id>urn:sha1:4543c10de267bdd4f9acdb7708456909ed7eed3c</id>
<content type='text'>
SIT tunnels use one rwlock to protect their hash tables.

This locking scheme can be converted to RCU for free, since netdevice
already must wait for a RCU grace period at dismantle time.

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ipv6 sit: RCU conversion phase I</title>
<updated>2009-10-24T13:07:55Z</updated>
<author>
<name>Eric Dumazet</name>
</author>
<published>2009-10-23T17:51:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ef9a9d1183b36fbf3de327f44596533b770c3005'/>
<id>urn:sha1:ef9a9d1183b36fbf3de327f44596533b770c3005</id>
<content type='text'>
SIT tunnels use one rwlock to protect their prl entries.

This first patch adds RCU locking for prl management,
with standard call_rcu() calls.

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ipv6 sit: Set relay to 0.0.0.0 directly if relay_prefixlen == 0.</title>
<updated>2009-10-12T06:41:10Z</updated>
<author>
<name>YOSHIFUJI Hideaki / 吉藤英明</name>
</author>
<published>2009-10-11T03:45:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=91b2a3f9bb0fa8d64b365a10b0624b0341e1a338'/>
<id>urn:sha1:91b2a3f9bb0fa8d64b365a10b0624b0341e1a338</id>
<content type='text'>
ipv6 sit: Set relay to 0.0.0.0 directly if relay_prefixlen == 0.

Do not use bit-shift if relay_prefixlen == 0;
relay_prefix &lt;&lt; 32 does not result in 0.

Signed-off-by: YOSHIFUJI Hideaki &lt;yoshfuji@linux-ipv6.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ipv6 sit: Fix 6rd relay address.</title>
<updated>2009-10-12T06:41:08Z</updated>
<author>
<name>YOSHIFUJI Hideaki / 吉藤英明</name>
</author>
<published>2009-10-11T03:44:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e7db38c38fe8df1d890ae772737e27308bdc5956'/>
<id>urn:sha1:e7db38c38fe8df1d890ae772737e27308bdc5956</id>
<content type='text'>
ipv6 sit: Fix 6rd relay address.

Relay's address should be extracted from real IPv6 address
instead of configured prefix.

Signed-off-by: YOSHIFUJI Hideaki &lt;yoshfuji@linux-ipv6.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ipv6 sit: Ensure to initialize 6rd parameters.</title>
<updated>2009-10-12T06:41:07Z</updated>
<author>
<name>YOSHIFUJI Hideaki / 吉藤英明</name>
</author>
<published>2009-10-11T03:31:34Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e0c93948154328e13b4c0b0502d66af93f0fdfc4'/>
<id>urn:sha1:e0c93948154328e13b4c0b0502d66af93f0fdfc4</id>
<content type='text'>
ipv6 sit: Ensure to initialize 6rd parameters.

Signed-off-by: YOSHIFUJI Hideaki &lt;yoshfuji@linux-ipv6.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
