]> git.ipfire.org Git - thirdparty/iptables.git/commit
xtables-translate: Fix for interfaces with asterisk mid-string
authorPhil Sutter <phil@nwl.cc>
Thu, 1 Dec 2022 14:16:43 +0000 (15:16 +0100)
committerPhil Sutter <phil@nwl.cc>
Fri, 2 Dec 2022 00:47:32 +0000 (01:47 +0100)
commitba1c0fe89eb56f8bf25f9165f2e5dc366ea0118c
treed5b03ef3a196917920d0935129974c3171f94a39
parent29387a190f5ba04fb8a902dce9602292979a9ba2
xtables-translate: Fix for interfaces with asterisk mid-string

For nft, asterisk is special at end of the interface name only. Escaping
it mid-string makes the escape char part of the interface name, so avoid
this.

In the test case, also drop the ticks around interface names in
*-translate command - since there's no shell involved which would eat
them, they become part of the interface name.

Fixes: e179e87a1179e ("xtables-translate: Fix for interface name corner-cases")
Signed-off-by: Phil Sutter <phil@nwl.cc>
extensions/generic.txlate
iptables/xtables-translate.c