]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Check number strings fed into dynamic regular expressions work
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Wed, 5 Nov 2014 22:35:53 +0000 (17:35 -0500)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Wed, 5 Nov 2014 22:35:53 +0000 (17:35 -0500)
src/tests/keywords/if-regex-match

index 2b2b11b9c33e3250be82645dca4536fbc3d529fa..7021288a6ccc67d5a9470036c90620c00fbb8fa1 100644 (file)
@@ -1,5 +1,8 @@
 # PRE: if
 #
+update request {
+       Tmp-Integer-0 := '123456789'
+}
 
 # Non matching on attribute ref
 if (User-Name !~ /^([0-9])_([0-9])?_([0-9]*)_([0-9]+)_([^_])_(6)_([7-8])%{Tmp-String-0}/) {
@@ -91,6 +94,11 @@ if (Service-Type =~ /^framed-user%{Tmp-String-0}$/) {
        }
 }
 
-
+# uncompiled - integer - ref
+if (Tmp-Integer-0 !~ /%{Tmp-Integer-0}/) {
+       update reply {
+               Filter-Id += 'Fail 10'
+       }
+}