Mangle to match wildcard address list entries

I am attempting to set a mangle rule which matches a few address lists. I would like to achieve this by using a wildcard in the matching src address list entry. If the address lists i need to match all starts with incl**** how do i need to set this in the mangle src address list ?

1st rule: src-address-list=incl1 action=jump to ‘xxx’ chain
2nd rule: src-address-list=incl2 action=jump to ‘xxx’ chain
3rd rule: src-address-list=incl3 action=jump to ‘xxx’ chain
4th rule: guess what =)


‘xxx’ chain: do what you want

Thanks for the reply

I was hoping i could do that in just one mangle entry:

src-address-list=incl(WILDCARD *) action=jump to ‘xxx’ chain

on the other hand you can create address-list that contains all these entries. and if you have to merge several, you can use scripting, to remove old entries and recreate full list once more as there are no wild-cards available.

Hello Janisk

Thats exactly what I have at this stage, for each rule that creates an address-list entry i added another rule which then adds this entry to a global address list. It would have been much simpler to use either a regex or wildcard to match these address lists. Thank you for your reply though.