]> git.ipfire.org Git - thirdparty/nftables.git/commit
evaluate: convert the byte-order of payload statement arguments.
authorJeremy Sowden <jeremy@azazel.net>
Tue, 3 Mar 2020 09:48:30 +0000 (09:48 +0000)
committerFlorian Westphal <fw@strlen.de>
Wed, 4 Mar 2020 22:36:41 +0000 (23:36 +0100)
commit904bad2bcfa72cb197e9fe18db3c4681086000ea
treea14437eee9b287f74d6ab14036235e41756aed25
parent4ac2cd199fbae8f52d43db7c817527ba1c5dedaa
evaluate: convert the byte-order of payload statement arguments.

Since shift operations require host byte-order, we need to be able to
convert the result of the shift back to network byte-order, in a rule
like:

  nft add rule ip t c tcp dport set tcp dport lshift 1

Signed-off-by: Jeremy Sowden <jeremy@azazel.net>
Signed-off-by: Florian Westphal <fw@strlen.de>
src/evaluate.c