[Top] [All Lists]

Re: [PATCH 3/3 XFRM]: Fix invalid key for lookup of cached bundles

To: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
Subject: Re: [PATCH 3/3 XFRM]: Fix invalid key for lookup of cached bundles
From: Patrick McHardy <kaber@xxxxxxxxx>
Date: Sun, 06 Mar 2005 11:54:07 +0100
Cc: davem@xxxxxxxxxxxxx, netdev@xxxxxxxxxxx
In-reply-to: <>
References: <>
Sender: netdev-bounce@xxxxxxxxxxx
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.7.5) Gecko/20050106 Debian/1.7.5-1
Herbert Xu wrote:
Patrick McHardy <kaber@xxxxxxxxx> wrote:

@@ -97,6 +104,7 @@
                err = xfrm_dst_lookup((struct xfrm_dst**)&rt, &fl_tunnel, 
                if (err)
                        goto error;
+               rt->u.dst.flags |= DST_XFRM_TUNNEL;

This line doesn't look right.  rt is an entry in the IPv4 routing
cache, right? If so why should its flags change when some bundle is

After all, it could also be used at the bottom of a transport mode bundle.

Oops, that is correct of course. I wanted to kill the ugly int *is_tunnel argument to xfrm_bundle_ok() in my last patch, but I need to look for a different way.

Besides, I think IPv4 routing cache entry will never show up at the top of
a bundle anyway which means that this flags value will never be read in
the find_bundle function.

At least that part was correct, __xfrm4_find_bundle() uses dst->path->flags in my patch.


<Prev in Thread] Current Thread [Next in Thread>