mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
[XFRM]: BEET mode
This patch introduces the BEET mode (Bound End-to-End Tunnel) with as specified by the ietf draft at the following link: http://www.ietf.org/internet-drafts/draft-nikander-esp-beet-mode-06.txt The patch provides only single family support (i.e. inner family = outer family). Signed-off-by: Diego Beltrami <diego.beltrami@gmail.com> Signed-off-by: Miika Komu <miika@iki.fi> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: Abhinav Pathak <abhinav.pathak@hiit.fi> Signed-off-by: Jeff Ahrenholz <ahrenholz@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
80246ab36e
commit
0a69452cb4
14 changed files with 308 additions and 10 deletions
|
@ -206,6 +206,7 @@ static void ipcomp4_err(struct sk_buff *skb, u32 info)
|
|||
static struct xfrm_state *ipcomp_tunnel_create(struct xfrm_state *x)
|
||||
{
|
||||
struct xfrm_state *t;
|
||||
u8 mode = XFRM_MODE_TUNNEL;
|
||||
|
||||
t = xfrm_state_alloc();
|
||||
if (t == NULL)
|
||||
|
@ -216,7 +217,9 @@ static struct xfrm_state *ipcomp_tunnel_create(struct xfrm_state *x)
|
|||
t->id.daddr.a4 = x->id.daddr.a4;
|
||||
memcpy(&t->sel, &x->sel, sizeof(t->sel));
|
||||
t->props.family = AF_INET;
|
||||
t->props.mode = XFRM_MODE_TUNNEL;
|
||||
if (x->props.mode == XFRM_MODE_BEET)
|
||||
mode = x->props.mode;
|
||||
t->props.mode = mode;
|
||||
t->props.saddr.a4 = x->props.saddr.a4;
|
||||
t->props.flags = x->props.flags;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue