Commit 1b9335a
committed
netfilter: nf_tables: reject mismatching sum of field_len with set key length
The field length description provides the length of each separated key
field in the concatenation, each field gets rounded up to 32-bits to
calculate the pipapo rule width from pipapo_init(). The set key length
provides the total size of the key aligned to 32-bits.
Register-based arithmetics still allows for combining mismatching set
key length and field length description, eg. set key length 10 and field
description [ 5, 4 ] leading to pipapo width of 12.
Cc: [email protected]
Fixes: 3ce67e3 ("netfilter: nf_tables: do not allow mismatch field size and set key length")
Reported-by: Noam Rathaus <[email protected]>
Reviewed-by: Florian Westphal <[email protected]>
Signed-off-by: Pablo Neira Ayuso <[email protected]>1 parent 0a5b8ff commit 1b9335a
1 file changed
+4
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5065 | 5065 | | |
5066 | 5066 | | |
5067 | 5067 | | |
5068 | | - | |
| 5068 | + | |
5069 | 5069 | | |
5070 | 5070 | | |
5071 | 5071 | | |
| |||
5079 | 5079 | | |
5080 | 5080 | | |
5081 | 5081 | | |
5082 | | - | |
| 5082 | + | |
5083 | 5083 | | |
5084 | | - | |
5085 | | - | |
| 5084 | + | |
5086 | 5085 | | |
5087 | 5086 | | |
| 5087 | + | |
5088 | 5088 | | |
5089 | 5089 | | |
5090 | 5090 | | |
| |||
0 commit comments