]> git.ipfire.org Git - thirdparty/strongswan.git/commit
connmark: Consider configured mask in installed firewall rules
authorTobias Brunner <tobias@strongswan.org>
Fri, 17 Jun 2022 10:10:19 +0000 (12:10 +0200)
committerTobias Brunner <tobias@strongswan.org>
Mon, 18 Jul 2022 13:05:51 +0000 (15:05 +0200)
commit44ab5533b00cff1efacbb638bea0460f8c8b4027
tree617d84e9f09a00a2fffb642f56be310b4de24ded
parent42ed6b44b2d17fda3a87c9e50ad3a4e5cdae2f40
connmark: Consider configured mask in installed firewall rules

This allows using the upper parts of the marks for other purposes.  For
instance, with `mark_in=mark_out=%unique/0x0000ffff` mark values in the
upper two bytes would not get reset by the rules installed by this plugin.
However, note that in this example the daemon would have to get restarted
after 65'535 CHILD_SAs to reset the counter for unique marks, which is a
global 32-bit counter that's unaware of any masks.

Closes strongswan/strongswan#1087
src/libcharon/plugins/connmark/connmark_listener.c