0

I'd like to use wildcards in a list with nftables. I tried this, but it gives me an error when I'm loading it:

iifname {"virbr*", "vboxnet*"} accept
oifname {"virbr*", "vboxnet*"} ct state established,related accept

Putting each interface on a separate line fixes the problem:

iifname "virbr*" accept
iifname "vboxnet*" accept
oifname "virbr*" ct state established,related accept
oifname "vboxnet*" ct state established,related accept

... but I wanted to know if there is any way to use wildcards in a list so that I can put all the interfaces in one line, similar to the first (non-working) method I posted.

  • You should consider asking this on the netfilter mailing list, this could be a feature request. If it's not possible, what would be the best next method? Having to add two rules (or one per chain) in nftables per additional bridge, or keeping the rules static but still having to do an action per additional bridge elsewhere (thinking about devgroup)? – A.B Aug 25 '18 at 15:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.