<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/net/xfrm, branch linux-2.6.28.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.28.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.28.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2009-05-02T17:56:32Z</updated>
<entry>
<title>xfrm: spin_lock() should be spin_unlock() in xfrm_state.c</title>
<updated>2009-05-02T17:56:32Z</updated>
<author>
<name>Chuck Ebbert</name>
</author>
<published>2009-03-27T07:22:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=167b397eb1dd142f14855357d692f98c3e0c0538'/>
<id>urn:sha1:167b397eb1dd142f14855357d692f98c3e0c0538</id>
<content type='text'>
[ Upstream commit 7d0b591c655ca0d72ebcbd242cf659a20a8995c5 ]

spin_lock() should be spin_unlock() in xfrm_state_walk_done().

caused by:
commit 12a169e7d8f4b1c95252d8b04ed0f1033ed7cfe2
"ipsec: Put dumpers on the dump list"

Reported-by: Marc Milgram &lt;mmilgram@redhat.com&gt;
Signed-off-by: Chuck Ebbert &lt;cebbert@redhat.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;

</content>
</entry>
<entry>
<title>xfrm: Fix kernel panic when flush and dump SPD entries</title>
<updated>2008-12-03T08:27:18Z</updated>
<author>
<name>Wei Yongjun</name>
</author>
<published>2008-12-03T08:27:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d5654efd3ff1cd0baa935a0c9a5d89862f07d009'/>
<id>urn:sha1:d5654efd3ff1cd0baa935a0c9a5d89862f07d009</id>
<content type='text'>
After flush the SPD entries, dump the SPD entries will cause kernel painc.

Used the following commands to reproduct:

- echo 'spdflush;' | setkey -c
- echo 'spdadd 3ffe:501:ffff:ff01::/64 3ffe:501:ffff:ff04::/64  any -P out ipsec \
  ah/tunnel/3ffe:501:ffff:ff00:200:ff:fe00:b0b0-3ffe:501:ffff:ff02:200:ff:fe00:a1a1/require;\
  spddump;' | setkey -c
- echo 'spdflush; spddump;' | setkey -c
- echo 'spdadd 3ffe:501:ffff:ff01::/64 3ffe:501:ffff:ff04::/64  any -P out ipsec \
  ah/tunnel/3ffe:501:ffff:ff00:200:ff:fe00:b0b0-3ffe:501:ffff:ff02:200:ff:fe00:a1a1/require;\
  spddump;' | setkey -c

This is because when flush the SPD entries, the SPD entry is not remove
from the list.

This patch fix the problem by remove the SPD entry from the list.

Signed-off-by: Wei Yongjun &lt;yjwei@cn.fujitsu.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>xfrm: Fix xfrm_policy_gc_lock handling.</title>
<updated>2008-11-04T03:11:29Z</updated>
<author>
<name>Alexey Dobriyan</name>
</author>
<published>2008-11-04T03:11:29Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bbb770e7ab9a436752babfc8765e422d7481be1f'/>
<id>urn:sha1:bbb770e7ab9a436752babfc8765e422d7481be1f</id>
<content type='text'>
From: Alexey Dobriyan &lt;adobriyan@gmail.com&gt;

Based upon a lockdep trace by Simon Arlott.

xfrm_policy_kill() can be called from both BH and
non-BH contexts, so we have to grab xfrm_policy_gc_lock
with BH disabling.

Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>XFRM: copy_to_user_kmaddress() reports local address twice</title>
<updated>2008-11-03T09:30:23Z</updated>
<author>
<name>Arnaud Ebalard</name>
</author>
<published>2008-11-03T09:30:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a1caa32295d67284ecba18cd8db692c7166f0706'/>
<id>urn:sha1:a1caa32295d67284ecba18cd8db692c7166f0706</id>
<content type='text'>
While adding support for MIGRATE/KMADDRESS in strongSwan (as specified
in draft-ebalard-mext-pfkey-enhanced-migrate-00), Andreas Steffen
noticed that XFRMA_KMADDRESS attribute passed to userland contains the
local address twice (remote provides local address instead of remote
one).

This bug in copy_to_user_kmaddress() affects only key managers that use
native XFRM interface (key managers that use PF_KEY are not affected).

For the record, the bug was in the initial changeset I posted which
added support for KMADDRESS (13c1d18931ebb5cf407cb348ef2cd6284d68902d
'xfrm: MIGRATE enhancements (draft-ebalard-mext-pfkey-enhanced-migrate)').

Signed-off-by: Arnaud Ebalard &lt;arno@natisbad.org&gt;
Reported-by: Andreas Steffen &lt;andreas.steffen@strongswan.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>xfrm: do not leak ESRCH to user space</title>
<updated>2008-10-31T07:06:03Z</updated>
<author>
<name>fernando@oss.ntt.co</name>
</author>
<published>2008-10-23T04:27:19Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a432226614c5616e3cfd211e0acffa0acfb4770c'/>
<id>urn:sha1:a432226614c5616e3cfd211e0acffa0acfb4770c</id>
<content type='text'>
I noticed that, under certain conditions, ESRCH can be leaked from the
xfrm layer to user space through sys_connect. In particular, this seems
to happen reliably when the kernel fails to resolve a template either
because the AF_KEY receive buffer being used by racoon is full or
because the SA entry we are trying to use is in XFRM_STATE_EXPIRED
state.

However, since this could be a transient issue it could be argued that
EAGAIN would be more appropriate. Besides this error code is not even
documented in the man page for sys_connect (as of man-pages 3.07).

Signed-off-by: Fernando Luis Vazquez Cao &lt;fernando@oss.ntt.co.jp&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>xfrm: MIGRATE enhancements (draft-ebalard-mext-pfkey-enhanced-migrate)</title>
<updated>2008-10-05T20:33:42Z</updated>
<author>
<name>Arnaud Ebalard</name>
</author>
<published>2008-10-05T20:33:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=13c1d18931ebb5cf407cb348ef2cd6284d68902d'/>
<id>urn:sha1:13c1d18931ebb5cf407cb348ef2cd6284d68902d</id>
<content type='text'>
Provides implementation of the enhancements of XFRM/PF_KEY MIGRATE mechanism
specified in draft-ebalard-mext-pfkey-enhanced-migrate-00. Defines associated
PF_KEY SADB_X_EXT_KMADDRESS extension and XFRM/netlink XFRMA_KMADDRESS
attribute.

Signed-off-by: Arnaud Ebalard &lt;arno@natisbad.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ipsec: Put dumpers on the dump list</title>
<updated>2008-10-01T14:03:24Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2008-10-01T14:03:24Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=12a169e7d8f4b1c95252d8b04ed0f1033ed7cfe2'/>
<id>urn:sha1:12a169e7d8f4b1c95252d8b04ed0f1033ed7cfe2</id>
<content type='text'>
Herbert Xu came up with the idea and the original patch to make
xfrm_state dump list contain also dumpers:

As it is we go to extraordinary lengths to ensure that states
don't go away while dumpers go to sleep.  It's much easier if
we just put the dumpers themselves on the list since they can't
go away while they're going.

I've also changed the order of addition on new states to prevent
a never-ending dump.

Timo Teräs improved the patch to apply cleanly to latest tree,
modified iteration code to be more readable by using a common
struct for entries in the list, implemented the same idea for
xfrm_policy dumping and moved the af_key specific "last" entry
caching to af_key.

Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
Signed-off-by: Timo Teras &lt;timo.teras@iki.fi&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6</title>
<updated>2008-10-01T13:12:56Z</updated>
<author>
<name>David S. Miller</name>
</author>
<published>2008-10-01T13:12:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b262e60309e1b0eb25d300c7e739427d5316abb1'/>
<id>urn:sha1:b262e60309e1b0eb25d300c7e739427d5316abb1</id>
<content type='text'>
Conflicts:

	drivers/net/wireless/ath9k/core.c
	drivers/net/wireless/ath9k/main.c
	net/core/dev.c
</content>
</entry>
<entry>
<title>ipsec: Fix pskb_expand_head corruption in xfrm_state_check_space</title>
<updated>2008-09-30T09:03:19Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2008-09-30T09:03:19Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d01dbeb6af7a0848063033f73c3d146fec7451f3'/>
<id>urn:sha1:d01dbeb6af7a0848063033f73c3d146fec7451f3</id>
<content type='text'>
We're never supposed to shrink the headroom or tailroom.  In fact,
shrinking the headroom is a fatal action.

Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ipsec: Fix xfrm_state_walk race</title>
<updated>2008-09-23T02:48:19Z</updated>
<author>
<name>Herbert Xu</name>
</author>
<published>2008-09-23T02:48:19Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5c1824587f0797373c95719a196f6098f7c6d20c'/>
<id>urn:sha1:5c1824587f0797373c95719a196f6098f7c6d20c</id>
<content type='text'>
As discovered by Timo Teräs, the currently xfrm_state_walk scheme
is racy because if a second dump finishes before the first, we
may free xfrm states that the first dump would walk over later.

This patch fixes this by storing the dumps in a list in order
to calculate the correct completion counter which cures this
problem.

I've expanded netlink_cb in order to accomodate the extra state
related to this.  It shouldn't be a big deal since netlink_cb
is kmalloced for each dump and we're just increasing it by 4 or
8 bytes.

Signed-off-by: Herbert Xu &lt;herbert@gondor.apana.org.au&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
