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]
Date:   Mon, 20 May 2019 23:32:19 +0800
From:   Herbert Xu <herbert@...dor.apana.org.au>
To:     Anirudh Gupta <anirudhrudr@...il.com>
Cc:     Steffen Klassert <steffen.klassert@...unet.com>,
        Anirudh Gupta <anirudh.gupta@...hos.com>,
        "David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH net] xfrm: Fix xfrm sel prefix length validation

On Mon, May 20, 2019 at 03:01:56PM +0530, Anirudh Gupta wrote:
>
> diff --git a/net/xfrm/xfrm_user.c b/net/xfrm/xfrm_user.c
> index eb8d14389601..fc2a8c08091b 100644
> --- a/net/xfrm/xfrm_user.c
> +++ b/net/xfrm/xfrm_user.c
> @@ -149,7 +149,7 @@ static int verify_newsa_info(struct xfrm_usersa_info *p,
>  	int err;
>  
>  	err = -EINVAL;
> -	switch (p->family) {
> +	switch (p->sel.family) {
>  	case AF_INET:
>  		if (p->sel.prefixlen_d > 32 || p->sel.prefixlen_s > 32)
>  			goto out;

You just removed the only verification of p->family...
-- 
Email: Herbert Xu <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt

Powered by blists - more mailing lists