Howto filter Firewall log using regular expression

  • I have a few intefaces (eg: lan, wan, op1, opt2, ...). I can do simple filtering from the System Logs->Firewall and specify, for example, wan or lan to get filtered results. I can also do !lan (which will give me all but lan). However, here's what I would like to do: filter all, but opt1 and opt2. I tried a few combinations like: !(wan & lan), (!wan !lan), !(wan | lan), but none of them worked. How do I filter all interfaces except for the chosen ones?

  • Netgate Administrator

    Just remove the spaces, so: !(wan|lan)

    Or (opt1|opt2) if those are the interfaces you want to see hits on.


Log in to reply