netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH nft 0/3] fix map update with concatenation and timeouts
@ 2022-12-12 10:04 Florian Westphal
  2022-12-12 10:04 ` [PATCH nft 1/3] netlink_delinearize: fix decoding of concat data element Florian Westphal
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Florian Westphal @ 2022-12-12 10:04 UTC (permalink / raw)
  To: netfilter-devel; +Cc: Florian Westphal

When "update" is used with a map, nft will ignore a given timeout.
Futhermore, listing is broken, only the first data expression
gets decoded:

in:
 meta l4proto tcp update @pinned { ip saddr . ct original proto-src : ip daddr . ct original proto-dst timeout 90s }
out:
 meta l4proto tcp update @pinned { ip saddr . ct original proto-src : ip daddr }

Missing timeout is input bug (never passed to kernel), mussing
"proto-dst" is output bug.

Also add a test case.

Florian Westphal (3):
  netlink_delinearize: fix decoding of concat data element
  netlink_linearize: fix timeout with map updates
  tests: add a test case for map update from packet path with concat

 src/netlink_delinearize.c                      |  8 ++++++++
 src/netlink_linearize.c                        |  7 +++++++
 .../maps/dumps/typeof_maps_concat_update_0.nft | 12 ++++++++++++
 .../testcases/maps/typeof_maps_concat_update_0 | 18 ++++++++++++++++++
 4 files changed, 45 insertions(+)
 create mode 100644 tests/shell/testcases/maps/dumps/typeof_maps_concat_update_0.nft
 create mode 100755 tests/shell/testcases/maps/typeof_maps_concat_update_0

-- 
2.38.1


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2022-12-12 16:45 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-12-12 10:04 [PATCH nft 0/3] fix map update with concatenation and timeouts Florian Westphal
2022-12-12 10:04 ` [PATCH nft 1/3] netlink_delinearize: fix decoding of concat data element Florian Westphal
2022-12-12 10:04 ` [PATCH nft 2/3] netlink_linearize: fix timeout with map updates Florian Westphal
2022-12-12 13:35   ` Pablo Neira Ayuso
2022-12-12 13:56     ` Florian Westphal
2022-12-12 10:04 ` [PATCH nft 3/3] tests: add a test case for map update from packet path with concat Florian Westphal
2022-12-12 13:38 ` [PATCH nft 0/3] fix map update with concatenation and timeouts Pablo Neira Ayuso
2022-12-12 16:42   ` Florian Westphal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).