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] [day] [month] [year] [list]
Message-ID: <20150313105050.GA3546@salvia>
Date:	Fri, 13 Mar 2015 11:50:50 +0100
From:	Pablo Neira Ayuso <pablo@...filter.org>
To:	Herbert Xu <herbert@...dor.apana.org.au>
Cc:	David Miller <davem@...emloft.net>, tgraf@...g.ch,
	netdev@...r.kernel.org, Patrick McHardy <kaber@...sh.net>,
	netfilter-devel@...r.kernel.org
Subject: Re: netfilter: Fix potential crash in nft_hash walker

On Fri, Mar 13, 2015 at 10:52:14AM +1100, Herbert Xu wrote:
> When we get back an EAGAIN from rhashtable_walk_next we were
> treating it as a valid object which obviously doesn't work too
> well.
>     
> Luckily this is hard to trigger so it seems nobody has run into
> it yet.
>     
> This patch fixes it by redoing the next call when we get an EAGAIN.

I'll enqueue this for nf, thanks Herbert.

> Signed-off-by: Herbert Xu <herbert@...dor.apana.org.au>
> 
> diff --git a/net/netfilter/nft_hash.c b/net/netfilter/nft_hash.c
> index c82df0a..37c15e6 100644
> --- a/net/netfilter/nft_hash.c
> +++ b/net/netfilter/nft_hash.c
> @@ -153,6 +153,8 @@ static void nft_hash_walk(const struct nft_ctx *ctx, const struct nft_set *set,
>  				iter->err = err;
>  				goto out;
>  			}
> +
> +			continue;
>  		}
>  
>  		if (iter->count < iter->skip)
> -- 
> 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
> --
> 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
--
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