Re: [PATCH nft 1/3] meta: add random expression key

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Pablo Neira Ayuso <pablo@xxxxxxxxxxxxx> wrote:
> On Tue, Jul 05, 2016 at 09:35:33AM +0200, Florian Westphal wrote:
> > meta random fills a 32bit register with a pseudo-random number.
> > 
> > For instance one can now use
> > 
> > meta random <= 2147483647
> > 
> > ... to match every 2nd packet, on average.
> > 
> > A followup patch will add a short-hand version ('probability 0.5') so
> > that users do not have to deal with details.
> > 
> > Signed-off-by: Florian Westphal <fw@xxxxxxxxx>
> 
> Please, apply this patch.
> 
> Acked-by: Pablo Neira Ayuso <pablo@xxxxxxxxxxxxx>
> 
> We can later on revisit the probability scaling, so keep 2/3 and 3/3
> back by now.

Done, I pushed a slightly amended version (no additional #include, only
needed in followup changes, I also edited the changelog to not mention
probability anymore.
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux