lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4F46430D.3060802@linuxsystems.it>
Date:	Thu, 23 Feb 2012 14:45:49 +0100
From:	Niccolò Belli <darkbasic@...uxsystems.it>
To:	Eric Dumazet <eric.dumazet@...il.com>
CC:	Linux Networking Developer Mailing List <netdev@...r.kernel.org>,
	openadsl-users@...ts.sourceforge.net,
	openadsl-devel@...ts.sourceforge.net, 660804@...s.debian.org,
	support@...verse.com.au, support@...ksolidelectronics.com
Subject: Re: [Bug 42809] New: kernel panic when receiving an ipsec packet

Il 23/02/2012 03:06, Eric Dumazet ha scritto:
> Thanks !
>
> Please try following patch.
>
> diff --git a/net/ipv4/xfrm4_mode_tunnel.c b/net/ipv4/xfrm4_mode_tunnel.c
> index 534972e..f170933 100644
> --- a/net/ipv4/xfrm4_mode_tunnel.c
> +++ b/net/ipv4/xfrm4_mode_tunnel.c
> @@ -84,9 +84,11 @@ static int xfrm4_mode_tunnel_input(struct xfrm_state *x, struct sk_buff *skb)
>   	if (!(x->props.flags&  XFRM_STATE_NOECN))
>   		ipip_ecn_decapsulate(skb);
>
> -	old_mac = skb_mac_header(skb);
> -	skb_set_mac_header(skb, -skb->mac_len);
> -	memmove(skb_mac_header(skb), old_mac, skb->mac_len);
> +	if (skb_mac_header_was_set(skb)) {
> +		old_mac = skb_mac_header(skb);
> +		skb_set_mac_header(skb, -skb->mac_len);
> +		memmove(skb_mac_header(skb), old_mac, skb->mac_len);
> +	}
>   	skb_reset_network_header(skb);
>   	err = 0;
>

Your patch does solve the problem, thanks!

Niccolò
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ