Monday, January 6, 2003, 6:45:58 PM, Alan DeKok wrote: AD> Andrei Koulik <[EMAIL PROTECTED]> wrote: >> How can I compare complex AV pairs ?
AD> Regular expressions. >> What I should write in users file in order to compare it against other set? >> H323-DialedDigits == "999,711,713,810" ? >> H323-DialedDigits == "711,713,810,999" ? >> all possible combination ? AD> H323-DialedDigits =~ "((711|713|810|999),)*(711|713|810|999)" AD> should do it. yes, it will work well for any sequence consisted from 711,713,810 and 999 divided by ',' (even "999,999,999"). But it is not trivial using regular expression pattern to match exactly that set (not a subset). It is more precisely to use H323-DialedDigits =~ "^((711|713|810|999),){3}(711|713|810|999)$" but I don't know how to refrain from repetition using standard regexp (without \<digit> construction) AD> Alan DeKok. AD> - AD> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html -- Andrei Koulik. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html