Thats my bad, I should have realised it was regex cant remember last time I called it "regular expressions" so I was trying logical expression ie =+-<>&
The thing that threw me, is there are only 35 chars for the ip addresses which isnt enough space for ipv6.
Anyway for anyone else interested in how regex works, the link has some good examples to explain.
http://www.proftpd.org/docs/howto/Regex.html
or a quick overview can be seen below.
^ caret matches the start of a string, eg ^192 will match all entries that start with 192, ^10 will match all entries that start with 10, although not relevant on this page, but in other applications ^&foo will match all entries that start with &foo and ^@domain will match all entries that start with @domain
$ dollar sign is similar but the opposite to caret in that its used to match the end of a string, eg 10$ will match all entries that finish with 10, @domain$ will match all entries that finish with @domain.
. period matches any single character eg 1.2 will match the 3 digit numbers 112, 122, 132, all the way up to 192, s.f will match any 3 letter word that starts with s and ends with f, eg saf, sbf, scf, sdf and so on.
open and closed square brackets will match any one or more entries containing the numbers, characters & symbols encapsulated in the square brackets. EG [192] will find all entries that have 1 and/or 9 and/or 2, [abc] will match all entries that contain a and/or b and/or c.Numerics in square brackets can also contain a range eg [0-9] will match all entries that one or more of the numbers in the range specified inside the square brackets.
| Vertical pipe/bar is an either or operator eg ^192|21$ will match either all entries that start with 192 or all entries that finish with 21.
\ Backslash is used to prevent the special meaning of operators eg . will make . (period/fullstop) behave like a period/fullstop and not a single char match, hence the . in the example Jimp provided. ^ will prevent the caret operating as a match the start of a string eg ^foo will find all entries that contain ^foo.
? question mark will match once or not at all, eg 19?2 will return 192 and 12 only, he?llo will return hello or hllo
asterisk will match as many times as possible or not at all eg 192* will return 192, 19, 1922, 19222 and so on. will match at least once 192+ will return 192,1912, 1922, 1932 and so on.*, +, ? are acted upon first, followed by any concatenations and then finally |
fwiw.