Re: [nft PATCH] dynset: avoid errouneous assert with ipv6 concat data

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

 



Son Dinh <dinhtrason@xxxxxxxxx> wrote:
> Fix assert bug of map dynset having ipv6 concat data
> 
>  nft add rule ip6 table-test chain-1 update @map-X { ip6 saddr : 1000::1 . 5001 }
>  nft: src/netlink_linearize.c:873: netlink_gen_expr: Assertion `dreg < ctx->reg_low' failed.
>  Aborted (core dumped)
> 
> The current code allocates upto 4 registers for map dynset data, but ipv6 concat
> data of a dynset requires more than 4 registers, resulting in the assert in
> netlink_gen_expr when generating netlink info for the dynset data.

Could you plese either extend an existing test case or add a new one for
this?

> -	sreg_data = get_register(ctx, stmt->map.data);

This line is wrong, this sould be

   	sreg_data = get_register(ctx, stmt->map.data->key);




[Index of Archives]     [Netfitler Users]     [Berkeley Packet Filter]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux