]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
remove '&' from the start of the line
authorAlan T. DeKok <aland@freeradius.org>
Mon, 20 Jan 2025 17:59:36 +0000 (12:59 -0500)
committerAlan T. DeKok <aland@freeradius.org>
Mon, 20 Jan 2025 20:27:06 +0000 (15:27 -0500)
earlier commits didn't do that.

 perl -p -i -e 's/^&//' $(git grep -l '^&' src/tests/modules)

106 files changed:
src/tests/modules/always/set_rcode.unlang
src/tests/modules/always/set_status_dead.unlang
src/tests/modules/always/set_status_revive.unlang
src/tests/modules/attr_filter/bob.unlang
src/tests/modules/attr_filter/operators.unlang
src/tests/modules/cache_rbtree/cache-bin.unlang
src/tests/modules/cache_rbtree/cache-logic.unlang
src/tests/modules/cache_rbtree/cache-method-bin.unlang
src/tests/modules/cache_rbtree/cache-method-logic.unlang
src/tests/modules/cache_rbtree/cache-method-update.unlang
src/tests/modules/cache_rbtree/cache-update.unlang
src/tests/modules/cache_rbtree/cache-xlat.unlang
src/tests/modules/chap/chap_password.unlang
src/tests/modules/cipher/fingerprint.unlang
src/tests/modules/cipher/rsa_encrypt_decrypt.unlang
src/tests/modules/cipher/rsa_sign_verify.unlang
src/tests/modules/cipher/serial.unlang
src/tests/modules/cipher/valid.unlang
src/tests/modules/client/map.unlang
src/tests/modules/client/xlat.unlang
src/tests/modules/detail/escape.unlang
src/tests/modules/detail/simple.unlang
src/tests/modules/detail/suppress.unlang
src/tests/modules/dict/map.unlang
src/tests/modules/eap_sim/sim_xlat_id_aka.unlang
src/tests/modules/eap_sim/sim_xlat_id_aka_decrypt_no_tag.unlang
src/tests/modules/eap_sim/sim_xlat_id_error.unlang
src/tests/modules/eap_sim/sim_xlat_id_sim.unlang
src/tests/modules/exec/async.unlang
src/tests/modules/exec/backticks_list.unlang
src/tests/modules/exec/sync.unlang
src/tests/modules/files/any.unlang
src/tests/modules/files/compound_key.unlang
src/tests/modules/files/prefix.unlang
src/tests/modules/files/subnet2.unlang
src/tests/modules/icmp/ping.unlang
src/tests/modules/idn/idn.unlang
src/tests/modules/imap/auth_bad_pw.unlang
src/tests/modules/imap/auth_bad_usr.unlang
src/tests/modules/imap/auth_plaintext.unlang
src/tests/modules/json/encode.unlang
src/tests/modules/json/encode_error.unlang
src/tests/modules/json/eval.unlang
src/tests/modules/json/json_quote.unlang
src/tests/modules/json/nested_encode.unlang
src/tests/modules/json/regression02.unlang
src/tests/modules/ldap/access_state.unlang
src/tests/modules/ldap/acct.unlang
src/tests/modules/ldap/auth.unlang
src/tests/modules/ldap/auth_nested_profile.unlang
src/tests/modules/ldap/auth_ssl.unlang
src/tests/modules/ldap/auth_starttls.unlang
src/tests/modules/ldap/dynamic_dn.unlang
src/tests/modules/ldap/map_regression0.unlang
src/tests/modules/ldap/xlat.unlang
src/tests/modules/ldap/xlat_profile.unlang
src/tests/modules/linelog/linelog-errors.unlang
src/tests/modules/linelog/linelog-escapes.unlang
src/tests/modules/linelog/linelog-multi.unlang
src/tests/modules/linelog/linelog.unlang
src/tests/modules/linelog/linelog_xlat.unlang
src/tests/modules/mschap/auth.unlang
src/tests/modules/mschap/auth_mschapv2.unlang
src/tests/modules/mschap/auth_winbind.unlang
src/tests/modules/mschap/pwdchange_local.unlang
src/tests/modules/mschap/pwdchange_ntlm.unlang
src/tests/modules/perl/auth.unlang
src/tests/modules/perl/xlat.unlang
src/tests/modules/redis/cluster_key.unlang
src/tests/modules/redis/cluster_node_fail.unlang
src/tests/modules/redis/cluster_reset.inc
src/tests/modules/redis_ippool/alloc.unlang
src/tests/modules/redis_ippool/pool_tool_delete.unlang
src/tests/modules/redis_ippool/pool_tool_modify.unlang
src/tests/modules/redis_ippool/pool_tool_release.unlang
src/tests/modules/redis_ippool/pool_tool_static.unlang
src/tests/modules/redis_ippool/release.unlang
src/tests/modules/redis_ippool/static.unlang
src/tests/modules/redis_ippool/static_dynamic.unlang
src/tests/modules/redis_ippool/static_unassign.unlang
src/tests/modules/redis_ippool/update.unlang
src/tests/modules/redis_ippool/update_alloc.unlang
src/tests/modules/rest/rest_module.unlang
src/tests/modules/rest/rest_timeout.unlang
src/tests/modules/rest/rest_xlat.unlang
src/tests/modules/smtp/smtp_attachment/tls_attachment.unlang
src/tests/modules/smtp/smtp_authenticate/tls_authenticate.unlang
src/tests/modules/smtp/smtp_crln/tls_crln.unlang
src/tests/modules/smtp/smtp_stringparse/tls_stringparse.unlang
src/tests/modules/smtp/tls_delivery.unlang
src/tests/modules/sql/acct_start_conflict.unlang
src/tests/modules/sql/groups.unlang
src/tests/modules/sql/map.unlang
src/tests/modules/sqlcounter/test.unlang
src/tests/modules/sqlippool/alloc.unlang
src/tests/modules/sqlippool/alloc_fail.unlang
src/tests/modules/sqlippool/alloc_requested.unlang
src/tests/modules/sqlippool/release.unlang
src/tests/modules/sqlippool/static.unlang
src/tests/modules/sqlippool/update.unlang
src/tests/modules/sqlippool/update_alloc.unlang
src/tests/modules/test/dollar_expansions.unlang
src/tests/modules/totp/auth.unlang
src/tests/modules/unbound/dns.unlang
src/tests/modules/yubikey/yubikey_auth.unlang
src/tests/modules/yubikey/yubikey_xlat.unlang

index fca86e43af43405d10c0e217ea16b0ee0d3d3bfa..1a2eeabbfeb70299dc4b8d172dc09f4dca085e2b 100644 (file)
@@ -38,4 +38,4 @@ if (notfound) {
        }
 }
 
-&control.Password.Cleartext := "hello"
+control.Password.Cleartext := "hello"
index a2103156256957f1f6caee7688867c05015270b8..078b15d44ecbfe64568a6f412080a54a6f3d863e 100644 (file)
@@ -11,4 +11,4 @@ if (fail) {
        reply.Reply-Message := "success"
 }
 
-&control.Password.Cleartext := "hello"
+control.Password.Cleartext := "hello"
index 092280a0a211a16427437bd7f3b3d03f90e4bc6f..13e6d2464535240f60e3e771de8972beb4d8d9c3 100644 (file)
@@ -23,4 +23,4 @@ if (ok) {
        }
 }
 
-&control.Password.Cleartext := "hello"
+control.Password.Cleartext := "hello"
index ccc9b747f787623c9ec70c7bd16c7ffe5508e3ed..fb197fbc3926f7d41237ed5839f0a9ca37b6c902 100644 (file)
@@ -1,7 +1,7 @@
 attr_filter
 
-&control.Password.Cleartext := "goodbye"
+control.Password.Cleartext := "goodbye"
 
-&reply += {
+reply += {
         Reply-Message = "success"
 }
index d21bbf6d49ba6413d382ba0404a2e90f320cfdc4..2d550749c9ffe5f8dffedf240bed97cfd9364c11 100644 (file)
@@ -1,5 +1,5 @@
 # Copy request to reply for later
-&reply := request
+reply := request
 
 attr_filter
 
@@ -44,7 +44,7 @@ if (reply.Idle-Timeout) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
-&control.Password.Cleartext := "goodbye"
-&reply.Reply-Message := Reply-Message
+control.Password.Cleartext := "goodbye"
+reply.Reply-Message := Reply-Message
index a2fa88863080b684228e138b50da9082a857806f..c007d815f587a28b54286e98b0358afcd5645d03 100644 (file)
@@ -6,8 +6,8 @@
 #  Series of tests to check for binary safe operation of the cache module
 #  both keys and values should be binary safe.
 #
-&Class := 0xaa00bb00cc00dd00
-&Callback-Id := "foo\000bar\000baz"
+Class := 0xaa00bb00cc00dd00
+Callback-Id := "foo\000bar\000baz"
 
 # 0. Sanity check
 if (Callback-Id != "foo\000bar\000baz") {
@@ -21,8 +21,8 @@ if (!updated) {
 }
 
 # Now add a second entry, with the value diverging after the first null byte
-&Class := 0xaa00bb00cc00ee00
-&Callback-Id := "bar\000baz"
+Class := 0xaa00bb00cc00ee00
+Callback-Id := "bar\000baz"
 
 # 2. Should create a *new* entry and not update the existing one
 cache_bin_key_octets.store
@@ -30,11 +30,11 @@ if (!updated) {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # If the key is binary safe, we should now be able to retrieve the first entry
 # if it's not, the above test will likely fail, or we'll get the second entry.
-&Class := 0xaa00bb00cc00dd00
+Class := 0xaa00bb00cc00dd00
 
 cache_bin_key_octets
 if (!updated) {
@@ -49,10 +49,10 @@ if (Callback-Id != "foo\000bar\000baz") {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # Now try and get the second entry
-&Class := 0xaa00bb00cc00ee00
+Class := 0xaa00bb00cc00ee00
 
 cache_bin_key_octets
 if (!updated) {
@@ -67,14 +67,14 @@ if (Callback-Id != "bar\000baz") {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 #
 #  We should also be able to use any fixed length data type as a key
 #  though there are no guarantees this will be portable.
 #
-&Framed-IP-Address := 192.168.0.1
-&Callback-Id := "foo\000bar\000baz"
+Framed-IP-Address := 192.168.0.1
+Callback-Id := "foo\000bar\000baz"
 
 cache_bin_key_ipaddr
 if (!ok) {
@@ -82,18 +82,18 @@ if (!ok) {
 }
 
 # Now add a second entry
-&Framed-IP-Address:= 192.168.0.2
-&Callback-Id := "bar\000baz"
+Framed-IP-Address:= 192.168.0.2
+Callback-Id := "bar\000baz"
 
 cache_bin_key_ipaddr
 if (!ok) {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # Now retrieve the first entry
-&Framed-IP-Address := 192.168.0.1
+Framed-IP-Address := 192.168.0.1
 
 cache_bin_key_ipaddr
 if (!updated) {
@@ -108,10 +108,10 @@ if (Callback-Id != "foo\000bar\000baz") {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # Now try and get the second entry
-&Framed-IP-Address := 192.168.0.2
+Framed-IP-Address := 192.168.0.2
 
 cache_bin_key_ipaddr
 if (!updated) {
@@ -126,6 +126,6 @@ if (Callback-Id != "bar\000baz") {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 test_pass
index 8dc2107080b3608031ec26c240e33d0f9f291ae2..9212aa662f4c93a6c7e0d839d9f2c123c8a0cda5 100644 (file)
@@ -1,12 +1,12 @@
 #
 #  PRE:
 #
-&Filter-Id := 'testkey'
+Filter-Id := 'testkey'
 
 #
 # 0.  Basic store and retrieve
 #
-&control.Callback-Id := 'cache me'
+control.Callback-Id := 'cache me'
 
 cache
 if (!ok) {
@@ -19,7 +19,7 @@ if (Callback-Id) {
 }
 
 # 2. Check status-only works correctly (should return ok and consume attribute)
-&control.Cache-Status-Only := 'yes'
+control.Cache-Status-Only := 'yes'
 
 cache
 if (!ok) {
@@ -43,7 +43,7 @@ if (Callback-Id != control.Callback-Id) {
 }
 
 # 6. Retrieving the entry should not expire it
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 cache
 if (!updated) {
@@ -59,9 +59,9 @@ else {
 }
 
 # 8. Force expiry of the entry
-&control.Cache-Allow-Merge := no
-&control.Cache-Allow-Insert := no
-&control.Cache-TTL := 0
+control.Cache-Allow-Merge := no
+control.Cache-Allow-Insert := no
+control.Cache-TTL := 0
 
 cache
 if (!ok) {
@@ -69,7 +69,7 @@ if (!ok) {
 }
 
 # 9. Check status-only works correctly (should return notfound and consume attribute)
-&control.Cache-Status-Only := 'yes'
+control.Cache-Status-Only := 'yes'
 
 cache
 if (!notfound) {
@@ -82,8 +82,8 @@ if (control.Cache-Status-Only) {
 }
 
 # 11. Check merge-only works correctly (should return notfound and consume attribute)
-&control.Cache-Allow-Merge := 'yes'
-&control.Cache-Allow-Insert := 'no'
+control.Cache-Allow-Merge := 'yes'
+control.Cache-Allow-Insert := 'no'
 
 cache
 if (!notfound) {
@@ -96,7 +96,7 @@ if (control.Cache-Allow-Merge) {
 }
 
 # 13. ...and check the entry wasn't recreated
-&control.Cache-Status-Only := 'yes'
+control.Cache-Status-Only := 'yes'
 
 cache
 if (!notfound) {
@@ -104,7 +104,7 @@ if (!notfound) {
 }
 
 # 14. This should still allow the creation of a new entry
-&control.Cache-TTL := -2
+control.Cache-TTL := -2
 
 cache
 if (!ok) {
@@ -127,10 +127,10 @@ if (Callback-Id != control.Callback-Id) {
        test_fail
 }
 
-&control.Callback-Id := 'cache me2'
+control.Callback-Id := 'cache me2'
 
 # 18. Updating the Cache-TTL shouldn't make things go boom (we can't really check if it works)
-&control.Cache-TTL := 30
+control.Cache-TTL := 30
 
 cache
 if (!updated) {
@@ -143,7 +143,7 @@ if (Callback-Id == control.Callback-Id) {
 }
 
 # 20. Check that a new entry is created
-&control.Cache-TTL := -2
+control.Cache-TTL := -2
 
 cache
 if (!updated) {
@@ -167,9 +167,9 @@ if (Callback-Id != control.Callback-Id) {
 }
 
 # 24. Check Cache-Merge = yes works as expected (should update current request)
-&control.Callback-Id := 'cache me3'
-&control.Cache-TTL := -2
-&control.Cache-Merge-New := yes
+control.Callback-Id := 'cache me3'
+control.Cache-TTL := -2
+control.Cache-Merge-New := yes
 
 cache
 if (!updated) {
index 7fc8af389df016886221d13e5211b0ac25ff5c89..f8f7264874523917ed9918a92f977bf94084a1a1 100644 (file)
@@ -6,8 +6,8 @@
 #  Series of tests to check for binary safe operation of the cache module
 #  both keys and values should be binary safe.
 #
-&Class := 0xaa11bb00cc00dd00
-&Callback-Id := "foo\000bar\000baz"
+Class := 0xaa11bb00cc00dd00
+Callback-Id := "foo\000bar\000baz"
 
 # 0. Sanity check
 if (Callback-Id != "foo\000bar\000baz") {
@@ -21,8 +21,8 @@ if (!updated) {
 }
 
 # Now add a second entry, with the value diverging after the first null byte
-&Class := 0xaa11bb00cc00ee00
-&Callback-Id := "bar\000baz"
+Class := 0xaa11bb00cc00ee00
+Callback-Id := "bar\000baz"
 
 # 2. Should create a *new* entry and not update the existing one
 cache_bin_key_octets.store
@@ -30,11 +30,11 @@ if (!updated) {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # If the key is binary safe, we should now be able to retrieve the first entry
 # if it's not, the above test will likely fail, or we'll get the second entry.
-&Class := 0xaa11bb00cc00dd00
+Class := 0xaa11bb00cc00dd00
 
 cache_bin_key_octets.load
 if (!updated) {
@@ -49,10 +49,10 @@ if (Callback-Id != "foo\000bar\000baz") {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # Now try and get the second entry
-&Class := 0xaa11bb00cc00ee00
+Class := 0xaa11bb00cc00ee00
 
 cache_bin_key_octets.load
 if (!updated) {
@@ -67,14 +67,14 @@ if (Callback-Id != "bar\000baz") {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 #
 #  We should also be able to use any fixed length data type as a key
 #  though there are no guarantees this will be portable.
 #
-&Framed-IP-Address := 192.168.1.1
-&Callback-Id := "foo\000bar\000baz"
+Framed-IP-Address := 192.168.1.1
+Callback-Id := "foo\000bar\000baz"
 
 cache_bin_key_ipaddr.store
 if (!updated) {
@@ -82,18 +82,18 @@ if (!updated) {
 }
 
 # Now add a second entry
-&Framed-IP-Address:= 192.168.1.2
-&Callback-Id := "bar\000baz"
+Framed-IP-Address:= 192.168.1.2
+Callback-Id := "bar\000baz"
 
 cache_bin_key_ipaddr.store
 if (!updated) {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # Now retrieve the first entry
-&Framed-IP-Address := 192.168.1.1
+Framed-IP-Address := 192.168.1.1
 
 cache_bin_key_ipaddr.load
 if (!updated) {
@@ -108,10 +108,10 @@ if (Callback-Id != "foo\000bar\000baz") {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # Now try and get the second entry
-&Framed-IP-Address := 192.168.1.2
+Framed-IP-Address := 192.168.1.2
 
 cache_bin_key_ipaddr.load
 if (!updated) {
@@ -126,6 +126,6 @@ if (Callback-Id != "bar\000baz") {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 test_pass
index 47732ba262dfdba576c3f98ef302e9391128919a..f96b27faf0b925b50e577628d6ee39977fc71bb8 100644 (file)
@@ -1,12 +1,12 @@
 #
 #  PRE:
 #
-&Filter-Id := 'testkey1'
+Filter-Id := 'testkey1'
 
 #
 # 0.  Basic update and retrieve
 #
-&control.Callback-Id := 'cache me'
+control.Callback-Id := 'cache me'
 
 cache.update
 if (!updated) {
@@ -36,7 +36,7 @@ if (Callback-Id != control.Callback-Id) {
 }
 
 # 5. Retrieving the entry should not expire it
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 cache.load
 if (!updated) {
@@ -61,7 +61,7 @@ if (!notfound) {
 }
 
 # 14. This should still allow the creation of a new entry
-&control.Cache-TTL := -2
+control.Cache-TTL := -2
 
 cache.update
 if (!updated) {
@@ -84,10 +84,10 @@ if (Callback-Id != control.Callback-Id) {
        test_fail
 }
 
-&control.Callback-Id := 'cache me2'
+control.Callback-Id := 'cache me2'
 
 # 18. Updating the Cache-TTL shouldn't make things go boom (we can't really check if it works)
-&control.Cache-TTL := 666
+control.Cache-TTL := 666
 
 cache.ttl
 if (!updated) {
@@ -100,7 +100,7 @@ if (Callback-Id == control.Callback-Id) {
 }
 
 # 20. Check that a new entry is created
-&control.Cache-TTL := -2
+control.Cache-TTL := -2
 
 cache.update
 if (!updated) {
@@ -124,9 +124,9 @@ if (Callback-Id != control.Callback-Id) {
 }
 
 # 24. Check Cache-Merge = yes works as expected (should update current request)
-&control.Callback-Id := 'cache me3'
-&control.Cache-TTL := -2
-&control.Cache-Merge-New := yes
+control.Callback-Id := 'cache me3'
+control.Cache-TTL := -2
+control.Cache-Merge-New := yes
 
 cache.update
 if (!updated) {
index 68ce8a307fdc396a5532ccf1e7b16bbdde4c774d..791cfa6833f3c29b2656f6c5d45fa4616b0fc007 100644 (file)
@@ -1,16 +1,16 @@
 #
 #  PRE: cache-logic
 #
-&Filter-Id := 'testkey3'
+Filter-Id := 'testkey3'
 
 # Reply attributes
-&reply.Reply-Message := 'hello'
-&reply += {
+reply.Reply-Message := 'hello'
+reply += {
        Reply-Message = 'goodbye'
 }
 
 # Request attributes
-&request += {
+request += {
        NAS-Port = 10
        NAS-Port = 20
        NAS-Port = 30
@@ -19,7 +19,7 @@
 #
 #  Basic update and retrieve
 #
-&control.Callback-Id := 'cache me'
+control.Callback-Id := 'cache me'
 
 cache_update.update
 if (!updated) {
@@ -76,6 +76,6 @@ if (Login-LAT-Service[2] != 'baz') {
 }
 
 # Clear out the reply list
-&reply := {}
+reply := {}
 
 test_pass
index e42a3b5edb5590276e508c31093be9a6cd1451bb..2f009b97971704895fdf4f4a7eca87fc6da7df8a 100644 (file)
@@ -1,16 +1,16 @@
 #
 #  PRE: cache-logic
 #
-&Filter-Id := 'testkey2'
+Filter-Id := 'testkey2'
 
 # Reply attributes
-&reply.Reply-Message := 'hello'
-&reply += {
+reply.Reply-Message := 'hello'
+reply += {
        Reply-Message = 'goodbye'
 }
 
 # Request attributes
-&request += {
+request += {
        NAS-Port = 10
        NAS-Port = 20
        NAS-Port = 30
@@ -19,7 +19,7 @@
 #
 #  Basic update and retrieve
 #
-&control.Callback-Id := 'cache me'
+control.Callback-Id := 'cache me'
 
 cache_update
 if (!ok) {
@@ -70,7 +70,7 @@ if (Login-LAT-Service[2] != 'baz') {
 }
 
 # Clear out the reply list
-&reply := {}
+reply := {}
 
 # Need to test if thie cache env parses correctly, we dont really care about testing the static key
 static_key
index 8e4044c12eb44ab7a1260fadbbe02bf9406fede8..6787f7c5d5276cdbe8cb3fc24b3921061786e946 100644 (file)
@@ -1,8 +1,8 @@
 #
 #  PRE: cache-logic
 #
-&Filter-Id := 'testkey'
-&control.Callback-Id := 'cache me'
+Filter-Id := 'testkey'
+control.Callback-Id := 'cache me'
 
 cache
 if (!ok) {
@@ -14,24 +14,24 @@ if (%cache.ttl.get() < 4) {
         test_fail
 }
 
-&request.Login-LAT-Service := %cache('request.Callback-Id')
+request.Login-LAT-Service := %cache('request.Callback-Id')
 
 if (Login-LAT-Service != control.Callback-Id) {
         test_fail
 }
 
-&Login-LAT-Node := %cache(request.Login-LAT-Port)
+Login-LAT-Node := %cache(request.Login-LAT-Port)
 
 if (Login-LAT-Node) {
         test_fail
 }
 
 # Regression test for deadlock on notfound
-&Filter-Id := 'testkey0'
+Filter-Id := 'testkey0'
 
-&Login-LAT-Node := %cache(request.Login-LAT-Port)
+Login-LAT-Node := %cache(request.Login-LAT-Port)
 
 # Would previously deadlock
-&Login-LAT-Port := %cache(request.Login-LAT-Port)
+Login-LAT-Port := %cache(request.Login-LAT-Port)
 
 test_pass
index 0fc9480b1b5b1d90c14f9fa584052aeecb913c16..e8ca74f01cdc5b227f283b82b89645151257fb96 100644 (file)
@@ -1,8 +1,8 @@
 
-&CHAP-Challenge := 0x0102030405060708090a0b0c0d0e0f10
-&control.Password.Cleartext := "supersecret"
+CHAP-Challenge := 0x0102030405060708090a0b0c0d0e0f10
+control.Password.Cleartext := "supersecret"
 
-&CHAP-Password := "%chap.password(%{control.Password.Cleartext})"
+CHAP-Password := "%chap.password(%{control.Password.Cleartext})"
 
 chap.authenticate
 if (ok) {
index 4c8c24cd2bdd34de68e6f1837b4727d88cabc845..aeabaa481b383a0c60e24f9b6012d38fcb08b93e 100644 (file)
@@ -3,13 +3,13 @@
 #  but we can test the digest length, and for smoke...
 #
 octets test_octets
-&test_octets := %cipher_rsa.certificate('fingerprint','sha1')
+test_octets := %cipher_rsa.certificate('fingerprint','sha1')
 
 if (%length(%{test_octets}) != 20) {
        test_fail
 }
 
-&test_octets := %cipher_rsa.certificate('fingerprint','sha256')
+test_octets := %cipher_rsa.certificate('fingerprint','sha256')
 
 if (%length(%{test_octets}) != 32) {
        test_fail
index 650bca41134152ad381a2715b7415acdc641c96b..0dcc7e741883895f29d1080ff3e9e07d561539d7 100644 (file)
@@ -3,8 +3,8 @@ string test_string2
 octets test_octets1
 octets test_octets2
 
-&test_string1 := "Hello world!"
-&test_octets1 := %cipher_rsa.encrypt(%{test_string1})
+test_string1 := "Hello world!"
+test_octets1 := %cipher_rsa.encrypt(%{test_string1})
 
 if (!test_octets1) {
        test_fail
@@ -14,7 +14,7 @@ if ((octets)test_string1 == test_octets1) {
        test_fail
 }
 
-&test_string2 := %cipher_rsa.decrypt(%{test_octets1})
+test_string2 := %cipher_rsa.decrypt(%{test_octets1})
 
 if (test_string1 != test_string2) {
        test_fail
@@ -23,7 +23,7 @@ if (test_string1 != test_string2) {
 #
 #  Padding scheme should ensure ciphertext is not consistent
 #
-&test_octets2 := %cipher_rsa.encrypt(%{test_string1})
+test_octets2 := %cipher_rsa.encrypt(%{test_string1})
 
 if (test_octets1 == test_octets2) {
        test_fail
@@ -32,8 +32,8 @@ if (test_octets1 == test_octets2) {
 #
 #  Repeat tests to ensure there are no issues with EVP_PKEY_CTX reuse
 #
-&test_string1 := "Goodbye world!"
-&test_octets1 := %cipher_rsa.encrypt(%{test_string1})
+test_string1 := "Goodbye world!"
+test_octets1 := %cipher_rsa.encrypt(%{test_string1})
 
 if (!test_octets1) {
        test_fail
@@ -43,7 +43,7 @@ if ((octets)test_string1 == test_octets1) {
        test_fail
 }
 
-&test_string2 := %cipher_rsa.decrypt(%{test_octets1})
+test_string2 := %cipher_rsa.decrypt(%{test_octets1})
 
 if (test_string1 != test_string2) {
        test_fail
index 6920e76306a3319261b0bbd2d2e211cf62e5043b..4f115ac5df26380d62cb58456d84d05d8fba3f18 100644 (file)
@@ -1,8 +1,8 @@
 string test_string
 octets test_octets
 
-&test_string := "Hello world!"
-&test_octets := %cipher_rsa.sign(%{test_string})
+test_string := "Hello world!"
+test_octets := %cipher_rsa.sign(%{test_string})
 
 if (!test_octets) {
        test_fail
@@ -15,7 +15,7 @@ if ((octets)test_string[0] == test_octets[0]) {
 #
 #  Pass the signature and the original message to the verification function
 #
-&test_string := %cipher_rsa.verify(%{test_octets}, %{test_string})
+test_string := %cipher_rsa.verify(%{test_octets}, %{test_string})
 
 if (test_string != 'yes') {
        test_fail
@@ -24,8 +24,8 @@ if (test_string != 'yes') {
 #
 #  Verification should now fail
 #
-&test_string := "Goodbye world!"
-&test_string := %cipher_rsa.verify(%{test_octets}, %{test_string})
+test_string := "Goodbye world!"
+test_string := %cipher_rsa.verify(%{test_octets}, %{test_string})
 
 if (test_string != 'no') {
        test_fail
@@ -34,8 +34,8 @@ if (test_string != 'no') {
 #
 #  Repeat tests to ensure there are no issues with EVP_PKEY_CTX reuse
 #
-&test_string := "Hello nurse!"
-&test_octets := %cipher_rsa.sign(%{test_string})
+test_string := "Hello nurse!"
+test_octets := %cipher_rsa.sign(%{test_string})
 
 if (!test_octets) {
        test_fail
@@ -48,7 +48,7 @@ if ((octets)test_string[0] == test_octets[0]) {
 #
 #  Pass the signature and the original message to the verification function
 #
-&test_string := %cipher_rsa.verify(%{test_octets}, %{test_string})
+test_string := %cipher_rsa.verify(%{test_octets}, %{test_string})
 
 if (test_string != 'yes') {
        test_fail
@@ -57,8 +57,8 @@ if (test_string != 'yes') {
 #
 #  Verification should now fail
 #
-&test_string := "Goodbye nurse!"
-&test_string := %cipher_rsa.verify(%{test_octets}, %{test_string})
+test_string := "Goodbye nurse!"
+test_string := %cipher_rsa.verify(%{test_octets}, %{test_string})
 
 if (test_string != 'no') {
        test_fail
index 32e8856f05c206f43b3c18ec50d51710d9dde6a1..b1834255e052392b1d80e53218068d71b9722b68 100644 (file)
@@ -1,6 +1,6 @@
 octets test_octets
 
-&test_octets := %cipher_rsa.certificate('serial')
+test_octets := %cipher_rsa.certificate('serial')
 
 if (%length(%{test_octets}) != 1) {
        test_fail
index ffd6a21e4dbfaf5170048cec2ff1c705e41f2494..f732b35183d112088307b400969e6ef247c76789 100644 (file)
@@ -1,8 +1,8 @@
 date test_date1
 date test_date2
 
-&test_date1 := "%cipher_rsa.certificate(notBefore)"
-&test_date2 := "%cipher_rsa.certificate(notAfter)"
+test_date1 := "%cipher_rsa.certificate(notBefore)"
+test_date2 := "%cipher_rsa.certificate(notAfter)"
 
 # Check the cert validity period is 30 days
 if !((test_date2 - test_date1) == ((time_delta) (86400 * 60))) {
index 4b09829af29e498c1b871a3a2ba267bc80eaae39..211201aab48a092ccb72ae9e983f05a02d398c0e 100644 (file)
@@ -49,7 +49,7 @@ if (Callback-Id[2] != 'c') {
        test_fail
 }
 
-&request -= Filter-Id[*]
+request -= Filter-Id[*]
 
 map client 127.0.0.2 {
        Filter-Id += 'group'
@@ -67,8 +67,8 @@ if (Filter-Id[2] != 'f') {
        test_fail
 }
 
-&request -= Filter-Id[*]
-&request -= Callback-Id[*]
+request -= Filter-Id[*]
+request -= Callback-Id[*]
 
 #
 #  Test non-existent client properties
index 8a9aa40367343897fb6bc8e06f758b1f781aa857..3277ebd0b92743ae879e3e38533076274a88cc5b 100644 (file)
@@ -1,24 +1,24 @@
 string test_string
 
-&test_string := "%client('nas_type')"
+test_string := "%client('nas_type')"
 
 if (test_string != 'a_type') {
         test_fail
 }
 
-&test_string := "%client('nas_type',127.0.0.1)"
+test_string := "%client('nas_type',127.0.0.1)"
 
 if (test_string != 'a_type') {
         test_fail
 }
 
-&test_string := "%client('nas_type',127.0.0.2)"
+test_string := "%client('nas_type',127.0.0.2)"
 
 if (test_string != 'b_type') {
         test_fail
 }
 
-&test_string := "%client('nas_type',127.0.0.5)"
+test_string := "%client('nas_type',127.0.0.5)"
 
 if (test_string != 'b_type') {
        test_fail
@@ -27,12 +27,12 @@ if (test_string != 'b_type') {
 #
 #  Test non-existent client properties
 #
-&test_string := "%client('non-existent-attr')"
+test_string := "%client('non-existent-attr')"
 if !(test_string == "") {
        test_fail
 }
 
-&test_string := "%client('non-existing-attr2')"
+test_string := "%client('non-existing-attr2')"
 if !(test_string == "") {
        test_fail
 }
index 155fdcb35235824ec2252265ad75540528969b40..3cf6823cc9f9bfd55ddb3359fb60499811df532d 100644 (file)
@@ -1,6 +1,6 @@
 %file.rm("$ENV{MODULE_TEST_DIR}/127-2e0-2e0-2e1-with--n-c3-b6n--ascii-21")
 
-&request -= Module-Failure-Message[*]
+request -= Module-Failure-Message[*]
 
 detail_escape
 
index 47a3667ca26b92d910b0e5d5e1933e1ad001aebd..54f8047bdec0c9a93bd8bdf66fbe46251fccdba9 100644 (file)
@@ -1,6 +1,6 @@
 %file.rm("$ENV{MODULE_TEST_DIR}/127.0.0.1-detail")
 
-&request -= Module-Failure-Message[*]
+request -= Module-Failure-Message[*]
 
 detail
 
index a635565e925f9fb09ea3a4e046d3725d7a193df2..a1bdca6cae1d7a3ef8552c3cbf5881657b7527be 100644 (file)
@@ -1,6 +1,6 @@
 %file.rm("$ENV{MODULE_TEST_DIR}/127.0.0.1-suppress")
 
-&request -= Module-Failure-Message[*]
+request -= Module-Failure-Message[*]
 
 detail_suppress
 
index 20ef1a3b3506769bf52742e41b5083bfafc6867e..01cd2025bc8173fe93a50b6a29144bc8ba154b6d 100644 (file)
@@ -1,6 +1,6 @@
-&Vendor-Specific.FreeRADIUS.Proxied-To := 127.0.0.1
+Vendor-Specific.FreeRADIUS.Proxied-To := 127.0.0.1
 
-&Reply-Message := 'foo'
+Reply-Message := 'foo'
 
 if (%dict.attr.by_num(1) != 'User-Name') {
        test_fail
index d587399dca1a89e226a19f0a4e45a2bea38694c1..0a6d7cded633c6bba82764351aca857de5d9f62f 100644 (file)
@@ -12,8 +12,8 @@ if (%aka_sim_id_type("%{User-Name}") != 'permanent') {
 #
 #  Encrypt the permanent ID
 #
-&test_string := '1420032219455258'
-&control.User-Name := %3gpp_temporary_id_encrypt(%{User-Name},%{test_string},6)
+test_string := '1420032219455258'
+control.User-Name := %3gpp_temporary_id_encrypt(%{User-Name},%{test_string},6)
 
 #
 #  0.2 - Can we get the EAP method from the encrypted blob correctly?
@@ -39,7 +39,7 @@ if ("%3gpp_temporary_id_encrypt(%{control.User-Name},%{test_string},6)" != '') {
 #
 #  0.5 - Get the original IMSI back again
 #
-&result_string := %3gpp_temporary_id_decrypt(%{control.User-Name},%{test_string})
+result_string := %3gpp_temporary_id_decrypt(%{control.User-Name},%{test_string})
 
 if (result_string != User-Name) {
        test_fail
@@ -58,8 +58,8 @@ if (User-Name =~ /^[0-9](.*)/) {
 #
 #  1.1 - Encrypt the permanent ID
 #
-&test_string := '1420032219455259'
-&control += {
+test_string := '1420032219455259'
+control += {
        User-Name = %3gpp_temporary_id_encrypt(%{User-Name[1]},%{test_string},6)
 }
 
@@ -80,7 +80,7 @@ if ("%3gpp_temporary_id_encrypt(%{control.User-Name[1]},%{test_string},6)" != ''
 #
 #  1.4 - Get the original IMSI back again
 #
-&result_string := %3gpp_temporary_id_decrypt(%{control.User-Name[1]},%{test_string})
+result_string := %3gpp_temporary_id_decrypt(%{control.User-Name[1]},%{test_string})
 
 if (result_string != "0%{User-Name[1]}") {
        test_fail
@@ -89,8 +89,8 @@ if (result_string != "0%{User-Name[1]}") {
 #
 #  2.1 - Encrypt the permanent ID for fastauth
 #
-&test_string := '1420032219455259'
-&control += {
+test_string := '1420032219455259'
+control += {
        User-Name = %3gpp_temporary_id_encrypt(%{User-Name[1]},%{test_string},6,fastauth)
 }
 
@@ -111,7 +111,7 @@ if ("%3gpp_temporary_id_encrypt(%{control.User-Name[2]},%{test_string},6,fastaut
 #
 #  2.4 - Get the original IMSI back again
 #
-&result_string := %3gpp_temporary_id_decrypt(%{control.User-Name[2]},%{test_string})
+result_string := %3gpp_temporary_id_decrypt(%{control.User-Name[2]},%{test_string})
 
 if (result_string != "0%{User-Name[1]}") {
        test_fail
index 0d8a50ae2cdb8a5e6af040098bc8b85dba88fdb1..c5d588b7563a38aa8e21b0dcb7abd0ba561448c0 100644 (file)
@@ -12,13 +12,13 @@ if (%aka_sim_id_type(%{User-Name}) != 'permanent') {
 #
 #  1.1 - Encrypt the permanent ID
 #
-&test_string := '1420032219455259'
-&control.User-Name := %3gpp_temporary_id_encrypt(%{User-Name},%{test_string},6)
+test_string := '1420032219455259'
+control.User-Name := %3gpp_temporary_id_encrypt(%{User-Name},%{test_string},6)
 
 #
 #  1.2 - Get the original IMSI back again sans tag
 #
-&result_string := %3gpp_temporary_id_decrypt(%{control.User-Name}, %{test_string}, 'false')
+result_string := %3gpp_temporary_id_decrypt(%{control.User-Name}, %{test_string}, 'false')
 
 if ("%{User-Name}" =~ /^0(.*)/) {
        if (!result_string || (result_string == '') || (%{result_string} != "%{1}")) {
index 6aef1631f753f55f5fedd003be6d51af9130618a..f47e3e94598817688b78060f3d7201c3ef97a2e9 100644 (file)
@@ -1,7 +1,7 @@
 #
 #  No domain separator
 #
-&User-Name := '14200322194552581'
+User-Name := '14200322194552581'
 
 if ("%aka_sim_id_method(%{User-Name})" != '') {
        test_fail
@@ -10,7 +10,7 @@ if ("%aka_sim_id_method(%{User-Name})" != '') {
 #
 #  Zero length ID
 #
-&User-Name := ''
+User-Name := ''
 
 if ("%aka_sim_id_method(%{User-Name})" != '') {
        test_fail
index 03bf88b6d465a9d235ab35fbaa8d9c52e735d221..3276247c62ac0c6ebe63771c5bd4624f2c2f1617 100644 (file)
@@ -11,8 +11,8 @@ if (%aka_sim_id_type(%{User-Name}) != 'permanent') {
 #
 #  Encrypt the permanent ID
 #
-&test_string := '1234567812345678'
-&control.User-Name := %3gpp_temporary_id_encrypt(%{User-Name},%{test_string},6)
+test_string := '1234567812345678'
+control.User-Name := %3gpp_temporary_id_encrypt(%{User-Name},%{test_string},6)
 
 #
 #  Can we get the EAP method from the encrypted blob correctly?
index 87788022c3cf4c781bba2a38667fc57409bff569..fe318cc85c138dd61029d5141d04931d5c8cd2a5 100644 (file)
@@ -4,7 +4,7 @@ string test_string
 #  Async calls should always return a zero length string
 #  because we don't wait for the response.
 #
-&test_string := %exec_async('/bin/sh','-c',"'echo -n hello'")
+test_string := %exec_async('/bin/sh','-c',"'echo -n hello'")
 if test_string {
        test_fail
 }
@@ -27,7 +27,7 @@ if (reply.Reply-Message == 'hello') {
 #  Smoke test - Setup an async process that'll keep running after
 #  after the test exits.
 #
-&test_string := %exec_async('/bin/sh','-c',"'sleep 1'")
+test_string := %exec_async('/bin/sh','-c',"'sleep 1'")
 if test_string {
        test_fail
 }
index 25a30e54bc628344c846d172efef27bfd60b8e46..e4e60107d7de334458131168a5d623a90d4f8913 100644 (file)
@@ -4,7 +4,7 @@ string test_string
 #  Sync calls should always return a zero length string
 #  because we don't wait for the response.
 #
-&test_string := %exec('/bin/sh', '-c', 'echo hello')
+test_string := %exec('/bin/sh', '-c', 'echo hello')
 if (test_string != 'hello') {
        test_fail
 }
@@ -12,7 +12,7 @@ if (test_string != 'hello') {
 #
 #  @todo - list over-rides are not allowed!
 #
-&control += %exec('/bin/sh', '-c', "echo Reply-Message := \'hello\'")
+control += %exec('/bin/sh', '-c', "echo Reply-Message := \'hello\'")
 
 if (control.Reply-Message != 'hello') {
        test_fail
index 0174a621e30a5abe9548fd1f8a35b9b00c866dbe..25542de63a2cdb7fac3b8423f1b1b360f322b9e5 100644 (file)
@@ -3,7 +3,7 @@ string test_string
 #
 #  Sync calls return the response
 #
-&test_string := %exec_sync('/bin/sh', '-c', "echo 'hello'")
+test_string := %exec_sync('/bin/sh', '-c', "echo 'hello'")
 if (test_string != 'hello') {
        test_fail
 }
@@ -11,9 +11,9 @@ if (test_string != 'hello') {
 #
 #  Call something which will take longer than the timeout
 #
-&request -= Module-Failure-Message
+request -= Module-Failure-Message
 
-&test_string := %exec_sync('/bin/sleep', '10')
+test_string := %exec_sync('/bin/sleep', '10')
 
 if (Module-Failure-Message != "Execution of external program failed: Timeout running program") {
        test_fail
@@ -23,9 +23,9 @@ if test_string  {
        test_fail
 }
 
-&request -= Module-Failure-Message
+request -= Module-Failure-Message
 
-&test_string := %exec_sync('/bin/sh', "$ENV{MODULE_TEST_DIR}/fail.sh")
+test_string := %exec_sync('/bin/sh', "$ENV{MODULE_TEST_DIR}/fail.sh")
 
 if test_string {
        test_fail
@@ -79,7 +79,7 @@ if (control.NAS-Identifier == "Failure") {
        test_fail
 }
 
-&control -= Filter-Id[*]
+control -= Filter-Id[*]
 #
 #  Call a module which uses an xlat function in its arguments
 #
@@ -89,5 +89,5 @@ if !(control.Filter-Id == 'TONY') {
        test_fail
 }
 
-&reply -= Filter-Id[*]
+reply -= Filter-Id[*]
 test_pass
index a12b5dfe4b78541ced23a282dcd28f47db904bb2..b097e82dcfa83ee090cbf33eeebb4f1de1298d79 100644 (file)
@@ -1,6 +1,6 @@
 # Add multiple instances of Realm to the control list
 # The data should match on the second.
-&control += {
+control += {
        Realm = 'one'
        Realm = 'two'
        Realm = 'three'
index 4256922f44a50a41f5922bafcd884f76574bf6d4..3632ddea09d534f1f373fbb265a3f294c1d96371 100644 (file)
@@ -1,5 +1,5 @@
-&Filter-Id := 'test0'
-&Callback-Id := 'test1'
+Filter-Id := 'test0'
+Callback-Id := 'test1'
 
 compound_key
 if (!ok) {
index 336c386b5d4a83bec26a7b86ec2a6fc3a5dfff76..d3eb89a6731e278659f89b53b9ff94f85881c7de 100644 (file)
@@ -1,4 +1,4 @@
-&FreeRADIUS-Client-IP-Prefix := 10.1.2.3/32
+FreeRADIUS-Client-IP-Prefix := 10.1.2.3/32
 
 subnet
 
@@ -14,9 +14,9 @@ if (control.FreeRADIUS-Client-IP-Prefix != 10.1.0.0/16) {
        test_fail
 }
 
-&FreeRADIUS-Client-IP-Prefix := 10.2.3.4/32
+FreeRADIUS-Client-IP-Prefix := 10.2.3.4/32
 
-&reply -= Reply-Message[*]
+reply -= Reply-Message[*]
 
 subnet
 
@@ -28,16 +28,16 @@ if (control.FreeRADIUS-Client-IP-Prefix != 10.0.0.0/8) {
        test_fail
 }
 
-&FreeRADIUS-Client-IP-Prefix := 10.1.2.3/32
-&Password.Cleartext := "hello"
+FreeRADIUS-Client-IP-Prefix := 10.1.2.3/32
+Password.Cleartext := "hello"
 
-&reply -= Reply-Message[*]
+reply -= Reply-Message[*]
 
 subnet
 
-&FreeRADIUS-Client-IP-Prefix := 192.168.1.1/32
+FreeRADIUS-Client-IP-Prefix := 192.168.1.1/32
 
-&reply -= Reply-Message[*]
+reply -= Reply-Message[*]
 
 subnet
 
index 3fa5086aa1068a19be563db662bd7205a755b8ba..5900b722abd3a5977d1520473e5ea3a0b97d9479 100644 (file)
@@ -1,4 +1,4 @@
-&FreeRADIUS-Client-IP-Prefix := 10.1.2.3/32
+FreeRADIUS-Client-IP-Prefix := 10.1.2.3/32
 
 subnet2
 
@@ -19,9 +19,9 @@ if !(control.FreeRADIUS-Client-IP-Prefix == 10.0.0.0/8) {
 }
 
 #  Delete previous reply messages
-&reply -= Reply-Message[*]
+reply -= Reply-Message[*]
 
-&FreeRADIUS-Client-IP-Prefix := 10.2.2.3/15
+FreeRADIUS-Client-IP-Prefix := 10.2.2.3/15
 
 subnet2
 
index efd035cc4c85abfb22b2ed548e155927ffeea308..1cf99605fcb05aabef8ce947e2ea8aa96f28a621 100644 (file)
@@ -1,5 +1,5 @@
 string test_string
-&test_string := %ping(127.0.0.1)
+test_string := %ping(127.0.0.1)
 
 #
 #  @todo - conditions do not yet support YIELD
index 671e51375fb4bd28363c7cef32fc05fc3bee6e59..91c3ed7b42df71680a776745c056823813cc2c2f 100644 (file)
@@ -3,32 +3,32 @@ string test_string
 #  PRE: update if
 #
 
-&test_string := "%idn('example.com')"
+test_string := "%idn('example.com')"
 if (test_string != "example.com") {
         test_fail
 }
 
-&test_string := "%idn('èxâmpłé.com')"
+test_string := "%idn('èxâmpłé.com')"
 if (test_string != "xn--xmp-ila2ak63d.com") {
         test_fail
 }
 
-&test_string := "%idn('пример.com')"
+test_string := "%idn('пример.com')"
 if (test_string != "xn--e1afmkfd.com") {
         test_fail
 }
 
-&test_string := "%idn('παράδειγμα.com')"
+test_string := "%idn('παράδειγμα.com')"
 if (test_string != "xn--hxajbheg2az3al.com") {
         test_fail
 }
 
-&test_string := "%idn('ตัวอย่าง.com')"
+test_string := "%idn('ตัวอย่าง.com')"
 if (test_string != "xn--72c1a1bt4awk9o.com") {
         test_fail
 }
 
-&test_string := "%idn('invalid_example.com')"
+test_string := "%idn('invalid_example.com')"
 
 if (Module-Failure-Message != "Non-digit/letter/hyphen in input") {
         test_fail
@@ -38,9 +38,9 @@ if (Module-Failure-Message == "") {
         test_fail
 }
 
-&request -= Module-Failure-Message[*]
+request -= Module-Failure-Message[*]
 
-&test_string := "%idn('a.véry.löng.ņàme.whîch.when.expânded.exceedş.ţhe.dns.stanđard.fór.string.łength.of.twø.hündred.ând.fifty.threé.charáctèrs.and.therefore.is.invalid.for.idn.conversion')"
+test_string := "%idn('a.véry.löng.ņàme.whîch.when.expânded.exceedş.ţhe.dns.stanđard.fór.string.łength.of.twø.hündred.ând.fifty.threé.charáctèrs.and.therefore.is.invalid.for.idn.conversion')"
 
 if (Module-Failure-Message != "Conversion was truncated") {
         test_fail
index f31a8572d6517cb08061eaa440fdd7b8964dd9d0..07e1c025440ae0f2d07fe79a9b6e6f9dd03daeac 100644 (file)
@@ -14,4 +14,4 @@ if (fail) {
     reject
 }
 
-&reply.Packet-Type := "Access-Accept"
+reply.Packet-Type := "Access-Accept"
index f31a8572d6517cb08061eaa440fdd7b8964dd9d0..07e1c025440ae0f2d07fe79a9b6e6f9dd03daeac 100644 (file)
@@ -14,4 +14,4 @@ if (fail) {
     reject
 }
 
-&reply.Packet-Type := "Access-Accept"
+reply.Packet-Type := "Access-Accept"
index 794b28d3f0c4bea1c33a4574b644ad4c466b8f41..8223c69509c5ca60e1a4332b90d0e5c7e3ac0e99 100644 (file)
@@ -17,7 +17,7 @@ if !(ok) {
 #
 #  Check for module failing with missing attributes
 #
-&request -= User-Password[*]
+request -= User-Password[*]
 
 imap.authenticate {
     fail = 1
@@ -28,8 +28,8 @@ if !(invalid) {
     test_fail
 }
 
-&User-Password := 'test2'
-&request -= User-Name[*]
+User-Password := 'test2'
+request -= User-Name[*]
 
 imap.authenticate {
     fail = 1
@@ -44,7 +44,7 @@ if !(invalid) {
 #  Now do multiple authentications of different users
 #
 
-&User-Name := 'user2'
+User-Name := 'user2'
 imap.authenticate {
     fail = 1
 }
@@ -57,8 +57,8 @@ if !(ok) {
     test_fail
 }
 
-&User-Name := 'user3'
-&User-Password := 'test3'
+User-Name := 'user3'
+User-Password := 'test3'
 imap.authenticate {
     fail = 1
 }
@@ -74,8 +74,8 @@ if !(ok) {
 #
 #  And repeat all three
 #
-&User-Name := 'user1'
-&User-Password := 'test1'
+User-Name := 'user1'
+User-Password := 'test1'
 imap.authenticate {
     fail = 1
 }
@@ -88,8 +88,8 @@ if !(ok) {
     test_fail
 }
 
-&User-Name := 'user2'
-&User-Password := 'test2'
+User-Name := 'user2'
+User-Password := 'test2'
 imap.authenticate {
     fail = 1
 }
@@ -102,8 +102,8 @@ if !(ok) {
     test_fail
 }
 
-&User-Name := 'user3'
-&User-Password := 'test3'
+User-Name := 'user3'
+User-Password := 'test3'
 imap.authenticate {
     fail = 1
 }
index 2b1b0d43ad11f3780da4ab35ba125fc662b0174e..c5a0f2946795d62b4d552f2a1e3e0a0d0d00f907 100644 (file)
@@ -6,7 +6,7 @@ string test_string5
 #
 #      json.encode tests
 #
-&request -= Packet-Type[*]
+request -= Packet-Type[*]
 
 #
 #  HACK: the edit code does not currently support deleted by parent
@@ -14,18 +14,18 @@ string test_string5
 #  or even request -= Net.[*]
 #  which returns an error?
 #
-&request -= Net.Src.IP
-&request -= Net.Src.Port
-&request -= Net.Dst.IP
-&request -= Net.Dst.Port
-&request -= Net.Timestamp
-&request -= Net[*]
+request -= Net.Src.IP
+request -= Net.Src.Port
+request -= Net.Dst.IP
+request -= Net.Dst.Port
+request -= Net.Timestamp
+request -= Net[*]
 
 # 0. Check basic xlat parsing
-&test_string1 := %json.encode("request.[*]")
-&test_string2 := %json.encode("request.[*] ")
-&test_string3 := %json.encode(" request.[*]")
-&test_string4 := %json.encode("         request.[*]    ")
+test_string1 := %json.encode("request.[*]")
+test_string2 := %json.encode("request.[*] ")
+test_string3 := %json.encode(" request.[*]")
+test_string4 := %json.encode("          request.[*]    ")
 
 if (!(test_string1 == '{"User-Name":{"type":"string","value":"john"},"Filter-Id":{"type":"string","value":["f1","f2"]},"NAS-Port":{"type":"uint32","value":999},"Service-Type":{"type":"uint32","value":"Login-User"}}')) {
        test_fail
@@ -39,19 +39,19 @@ if (!(test_string1 == test_string2) ||
 }
 
 #  Check defaults are the same as output_mode "object":
-&test_string2 := %json_object.encode("request.[*]")
-&test_string3 := %json_object_no.encode("request.[*]")
+test_string2 := %json_object.encode("request.[*]")
+test_string3 := %json_object_no.encode("request.[*]")
 if (!(test_string1 == test_string2) ||
     !(test_string1 == test_string3)) {
        test_fail
 }
 
-&test_string1 := %json.encode(" request.[*]    !Filter-Id ")
+test_string1 := %json.encode(" request.[*]    !Filter-Id ")
 if !(test_string1 == '{"User-Name":{"type":"string","value":"john"},"NAS-Port":{"type":"uint32","value":999},"Service-Type":{"type":"uint32","value":"Login-User"}}') {
        test_fail
 }
 
-&test_string1 := %json.encode("request.[*] ! ")
+test_string1 := %json.encode("request.[*] ! ")
 if test_string1 {
        test_fail
 }
@@ -60,8 +60,8 @@ if test_string1 {
 
 # These are unsorted dictionaries. Hopefully json-c doesn't suddenly
 # decide that it's going to use a different ordering of the keys...
-&test_string1 := %json_object.encode("request.[*]")
-&test_string2 := %json_object_ex.encode("request.[*]")
+test_string1 := %json_object.encode("request.[*]")
+test_string2 := %json_object_ex.encode("request.[*]")
 
 if !(test_string1 == '{"User-Name":{"type":"string","value":"john"},"Filter-Id":{"type":"string","value":["f1","f2"]},"NAS-Port":{"type":"uint32","value":999},"Service-Type":{"type":"uint32","value":"Login-User"}}') {
        test_fail
@@ -73,15 +73,15 @@ if !(test_string2 == '{"pf:User-Name":{"type":"string","value":["john"]},"pf:Fil
 }
 
 # 1b. "object" empty inputs
-&test_string1 := %json_object.encode("!request.[*]")
+test_string1 := %json_object.encode("!request.[*]")
 
 if !(test_string1 == '{}') {
        test_fail
 }
 
 # 2a. Output mode "object_simple" tests
-&test_string1 := %json_object_simple.encode("request.[*]")
-&test_string2 := %json_object_simple_ex.encode("request.[*]")
+test_string1 := %json_object_simple.encode("request.[*]")
+test_string2 := %json_object_simple_ex.encode("request.[*]")
 
 if !(test_string1 == '{"User-Name":"john","Filter-Id":["f1","f2"],"NAS-Port":999,"Service-Type":"Login-User"}') {
        test_fail
@@ -92,15 +92,15 @@ if !(test_string2 == '{"pf:User-Name":["john"],"pf:Filter-Id":["f1","f2"],"pf:NA
 }
 
 # 2b. "object_simple" empty inputs
-&test_string1 := %json_object_simple.encode("!request.[*]")
+test_string1 := %json_object_simple.encode("!request.[*]")
 
 if !(test_string1 == '{}') {
        test_fail
 }
 
 # 3a. Output mode "array" tests
-&test_string1 := %json_array.encode("request.[*]")
-&test_string2 := %json_array_ex.encode("request.[*]")
+test_string1 := %json_array.encode("request.[*]")
+test_string2 := %json_array_ex.encode("request.[*]")
 
 if !(test_string1 == '[{"name":"User-Name","type":"string","value":"john"},{"name":"Filter-Id","type":"string","value":"f1"},{"name":"Filter-Id","type":"string","value":"f2"},{"name":"NAS-Port","type":"uint32","value":999},{"name":"Service-Type","type":"uint32","value":"Login-User"}]') {
        test_fail
@@ -111,15 +111,15 @@ if !(test_string2 == '[{"name":"pf:User-Name","type":"string","value":["john"]},
 }
 
 # 3b. "array" empty inputs
-&test_string1 := %json_array.encode("!request.[*]")
+test_string1 := %json_array.encode("!request.[*]")
 
 if !(test_string1 == '[]') {
        test_fail
 }
 
 # 4a. Output mode "array_of_names" tests
-&test_string1 := %json_array_names.encode("request.[*]")
-&test_string2 := %json_array_names_ex.encode("request.[*]")
+test_string1 := %json_array_names.encode("request.[*]")
+test_string2 := %json_array_names_ex.encode("request.[*]")
 
 if !(test_string1 == '["User-Name","Filter-Id","Filter-Id","NAS-Port","Service-Type"]') {
        test_fail
@@ -130,15 +130,15 @@ if !(test_string2 == '["pf:User-Name","pf:Filter-Id","pf:Filter-Id","pf:NAS-Port
 }
 
 # 4b. "array_of_names" empty inputs
-&test_string1 := %json_array_names.encode("!request.[*]")
+test_string1 := %json_array_names.encode("!request.[*]")
 
 if !(test_string1 == '[]') {
        test_fail
 }
 
 # 5a. Output mode "array_of_values" tests
-&test_string1 := %json_array_values.encode("request.[*]")
-&test_string2 := %json_array_values_ex.encode("request.[*]")
+test_string1 := %json_array_values.encode("request.[*]")
+test_string2 := %json_array_values_ex.encode("request.[*]")
 
 if !(test_string1 == '["john","f1","f2",999,"Login-User"]') {
        test_fail
@@ -149,7 +149,7 @@ if !(test_string2 == '["john","f1","f2","999","1"]') {
 }
 
 # 5b. "array_of_values" empty inputs
-&test_string1 := %json_array_values.encode("!request.[*]")
+test_string1 := %json_array_values.encode("!request.[*]")
 
 if !(test_string1 == '[]') {
        test_fail
index 2babd9c56240e40294a7190309a224d5daa53ba2..69adac27db920e44f53471816ac2ade860393aa4 100644 (file)
@@ -3,7 +3,7 @@ string test_string
 #       json xlat input parsing test - error with no input
 #
 
-&test_string := %json_object_ex_encode()  # ERROR
+test_string := %json_object_ex_encode()  # ERROR
 if (test_string) {
        test_fail
 }
index 49fb591ee8b018be80eb04486ebf1cd39e77df45..a7427d8e15021a5fd9512e4ebc25ef45e1d66ebf 100644 (file)
@@ -5,7 +5,7 @@ uint32 test_integer
 int64 test_int64
 string test_string
 
-&Filter-Id := "{\"foo\":\"bar\"}"
+Filter-Id := "{\"foo\":\"bar\"}"
 
 # 0. Simple field access
 map json Filter-Id {
@@ -16,7 +16,7 @@ if !(Callback-Id == 'bar') {
        test_fail
 }
 
-&Filter-Id := "\
+Filter-Id := "\
 {\
        \"my_array\": [0, 1, 2, 3, 4, 5], \
        \"my_object\": { \
@@ -30,7 +30,7 @@ if !(Callback-Id == 'bar') {
        \"bool_false\": false \
 }"
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # Check conversion of all JSON types to strings
 map json Filter-Id {
@@ -72,7 +72,7 @@ if (Callback-Id[6] != 'no') {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 #
 # Now check array slicing operates correctly
@@ -86,7 +86,7 @@ if !(Callback-Id == '[ 0, 1, 2, 3, 4, 5 ]') {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # 9. Simple index
 map json Filter-Id {
@@ -96,7 +96,7 @@ if !(NAS-Port == 0) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 9a. All of the array
 map json Filter-Id {
@@ -106,7 +106,7 @@ if (!(NAS-Port[0] == 0) || !(NAS-Port[1] == 1) || !(NAS-Port[2] == 2) || !(NAS-P
        test_fail
 }
 
-&NAS-Port := 9
+NAS-Port := 9
 
 # 9b. All of the array using prepend, places the array before the existing value
 map json Filter-Id {
@@ -116,7 +116,7 @@ if (!(NAS-Port[0] == 0) || !(NAS-Port[1] == 1) || !(NAS-Port[2] == 2) || !(NAS-P
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 10. End of the array
 map json Filter-Id {
@@ -126,7 +126,7 @@ if !(NAS-Port == 5) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 11. Past end of the array
 map json Filter-Id {
@@ -136,7 +136,7 @@ if (NAS-Port) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 12. Simple slice
 map json Filter-Id {
@@ -146,7 +146,7 @@ if (!(NAS-Port[0] == 0) || !(NAS-Port[1] == 1)) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 13. Slice with negative start
 map json Filter-Id {
@@ -156,7 +156,7 @@ if !(NAS-Port == 5) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 14. Slice with negative start and negative end
 map json Filter-Id {
@@ -174,7 +174,7 @@ if (!(NAS-Port[0] == 1) && !(NAS-Port[1] == 2)) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 16. Slice with start, end and negative step
 map json Filter-Id {
@@ -184,7 +184,7 @@ if (!(NAS-Port[0] == 4) || !(NAS-Port[1] == 3)) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 17. Slice with start, end (inverted) and negative step
 map json Filter-Id {
@@ -194,7 +194,7 @@ if (NAS-Port) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 18. Slice with start, end and positive step
 map json Filter-Id {
@@ -204,7 +204,7 @@ if (!(NAS-Port[0] == 2) || !(NAS-Port[1] == 3)) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 19. Slice with start, end and positive step > 1
 map json Filter-Id {
@@ -214,7 +214,7 @@ if (!(NAS-Port[0] == 1) && !(NAS-Port[1] == 3)) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 20. Slice with start, end and positive step > end of array
 map json Filter-Id {
@@ -224,7 +224,7 @@ if (!(NAS-Port[0] == 1) || NAS-Port[1]) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 21. Slice with start, end and positive step > end of array
 map json Filter-Id {
@@ -234,7 +234,7 @@ if (!(NAS-Port[0] == 5) || NAS-Port[1]) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 22. No start/end 3 step
 map json Filter-Id {
@@ -244,7 +244,7 @@ if (!(NAS-Port[0] == 0) || !(NAS-Port[1] == 3) || NAS-Port[2]) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 23. No start/end 3 step
 map json Filter-Id {
@@ -254,7 +254,7 @@ if (!(NAS-Port[0] == 5) || !(NAS-Port[1] == 2) || NAS-Port[2]) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 24. No end 3 step
 map json Filter-Id {
@@ -264,7 +264,7 @@ if (!(NAS-Port[0] == 3) || !(NAS-Port[1] == 0) || NAS-Port[2]) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 25. End 0, 3 step
 map json Filter-Id {
@@ -274,7 +274,7 @@ if (!(NAS-Port[0] == 3) || NAS-Port[1]) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 26. End 0, 3 step
 map json Filter-Id {
@@ -284,7 +284,7 @@ if (!(NAS-Port[0] == 0) || NAS-Port[1]) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 27. Everything two levels deep
 map json Filter-Id {
@@ -302,7 +302,7 @@ if (!(Callback-Id[0] == '0') || \
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # 28. Everything three levels deep (nothing)
 map json Filter-Id {
@@ -332,7 +332,7 @@ if (Callback-Id) {
 }
 
 # Some big numbers in nested arrays
-&Filter-Id := "\
+Filter-Id := "\
 [\
        9223372036854775807, \
        -9223372036854775807, \
@@ -367,7 +367,7 @@ if !(NAS-Port == 2147483647) {
        test_fail
 }
 
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 33. Signed 64bit integers
 if (0) {
@@ -386,7 +386,7 @@ if !(test_int64 == -9223372036854775807) {
        test_fail
 }
 
-&request -= test_int64[*]
+request -= test_int64[*]
 
 # 35. Unsigned 64bit integers (not allowed by json so gets truncated)
 map json Filter-Id {
@@ -397,7 +397,7 @@ if !(Acct-Input-Octets64 == 9223372036854775807) {
 }
 }
 
-&request -= Acct-Input-Octets64[*]
+request -= Acct-Input-Octets64[*]
 
 # 36. Multiple array indices
 map json Filter-Id {
@@ -407,10 +407,10 @@ if (!(Cache-TTL[0] == 2147483647) || !(Cache-TTL[1] == -2147483647)) {
        test_fail
 }
 
-&request -= Cache-TTL[*]
+request -= Cache-TTL[*]
 
 # 37. Path containing dynamic expansion
-&test_integer := 0
+test_integer := 0
 
 map json Filter-Id {
        NAS-Port += "$[3][%{test_integer}]"
@@ -418,14 +418,14 @@ map json Filter-Id {
 if !(NAS-Port == 2147483647) {
        test_fail
 }
-&request -= NAS-Port[*]
+request -= NAS-Port[*]
 
 # 38. An expanded field name with bad chars
-&Filter-Id := "\
+Filter-Id := "\
 {\
        \"foo.bar\": \"baz\" \
 }"
-&test_string := "%taint('foo.bar')"
+test_string := "%taint('foo.bar')"
 
 map json Filter-Id {
        Callback-Id := "$.%{test_string}"
@@ -435,9 +435,9 @@ if !(Callback-Id == 'baz') {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
-&Filter-Id := "\
+Filter-Id := "\
 {\
        \"my_array\": [0, 1, 2, 3, 4, 5], \
        \"my_object\": { \
@@ -470,7 +470,7 @@ if (!("%{Callback-Id[#]}" == 1) || !(Callback-Id == 'yes')) {
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # 40. Recursive descent with element match (2nd element in each array)
 map json Filter-Id {
@@ -479,7 +479,7 @@ map json Filter-Id {
 if (!("%{Callback-Id[#]}" == 3) || !(Callback-Id[0] == '1') || !(Callback-Id[1] == 'scratchy') || !(Callback-Id[2] == 'clawy')) {
        test_fail
 }
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 # 41. Recursive descent with field then element match
 map json Filter-Id {
@@ -489,6 +489,6 @@ if (!("%{Callback-Id[#]}" == 2) || !(Callback-Id[0] == 'flat') || !(Callback-Id[
        test_fail
 }
 
-&request -= Callback-Id[*]
+request -= Callback-Id[*]
 
 test_pass
index 97f0799c6e280172d6a6d5114809206b86e7351e..7b21443cf1772212f5d465a261ee8388a9ba6515 100644 (file)
@@ -3,32 +3,32 @@ uint32 test_integer
 ipaddr test_ipaddr
 string dummy_string
 
-&test_string := "Hello\n"
+test_string := "Hello\n"
 if (!(%json.quote(%{test_string}) == "\"Hello\\n\"")) {
        test_fail
 }
 
-&test_string := "Hello\nbob"
+test_string := "Hello\nbob"
 if (!(%json.quote(%{test_string}) == "\"Hello\\nbob\"")) {
        test_fail
 }
 
-&test_string := "\nHello\nbob"
+test_string := "\nHello\nbob"
 if (!(%json.quote(%{test_string}) == "\"\\nHello\\nbob\"")) {
        test_fail
 }
 
-&test_string := "Hello!"
+test_string := "Hello!"
 if (!(%json.quote(%{test_string}) == '"Hello!"')) {
        test_fail
 }
 
-&test_integer := 123456
+test_integer := 123456
 if (!(%json.quote(%{test_integer}) == '123456')) {
        test_fail
 }
 
-&test_ipaddr := 127.0.0.1
+test_ipaddr := 127.0.0.1
 if (!(%json.quote(%{test_ipaddr}) == '"127.0.0.1"')) {
        test_fail
 }
index c0e3a79f7e1e803088c46948e2aff840cd962e17..df691de4ffb195ff31af6cc690ab155e9c73b13e 100644 (file)
@@ -1,4 +1,4 @@
-&Tag-1 := {
+Tag-1 := {
        Vendor-Specific = {
                Unisphere = {
                        Service-Activate = "PPPOE_SERVICE(3072000,2048000)"
index 4e799d273e7a9ce9a994d6d7a9963e40ed319dd7..db46b4e3cd06f88881143f7b806ddde8066684b0 100644 (file)
@@ -1,7 +1,7 @@
 string test_string
 
 # An error string from Azure AD, try and access all the bits
-&test_string := "{\"error\":\"invalid_grant\",\"error_description\":\"AADSTS50126: Error validating credentials due to invalid username or password.\\r\\nTrace ID: 20bb60a5-5504-4a6b-ab40-a353a95c2500\\r\\nCorrelation ID: e58bb567-ad15-4a46-8341-cc6e800dd817\\r\\nTimestamp: 2023-02-11 02:32:40Z\",\"error_codes\":[50126],\"timestamp\":\"2023-02-11 02:32:40Z\",\"trace_id\":\"20bb60a5-5504-4a6b-ab40-a353a95c2500\",\"correlation_id\":\"e58bb567-ad15-4a46-8341-cc6e800dd817\",\"error_uri\":\"https://login.microsoftonline.com/error?code=50126\"}"
+test_string := "{\"error\":\"invalid_grant\",\"error_description\":\"AADSTS50126: Error validating credentials due to invalid username or password.\\r\\nTrace ID: 20bb60a5-5504-4a6b-ab40-a353a95c2500\\r\\nCorrelation ID: e58bb567-ad15-4a46-8341-cc6e800dd817\\r\\nTimestamp: 2023-02-11 02:32:40Z\",\"error_codes\":[50126],\"timestamp\":\"2023-02-11 02:32:40Z\",\"trace_id\":\"20bb60a5-5504-4a6b-ab40-a353a95c2500\",\"correlation_id\":\"e58bb567-ad15-4a46-8341-cc6e800dd817\",\"error_uri\":\"https://login.microsoftonline.com/error?code=50126\"}"
 
 map json test_string {
        Filter-Id := '$.error'
index f35f0b6a58cb8fb1ad940c600347b5ee6f7574ca..13ce77077066c08235c289ed5ba28f7f7d1bb450 100644 (file)
@@ -1,5 +1,5 @@
 # Bill should be disabled
-&Stripped-User-Name := 'bill'
+Stripped-User-Name := 'bill'
 ldap {
        disallow = 1
 }
@@ -8,7 +8,7 @@ if (!disallow) {
 }
 
 # Test suspended profile application
-&Stripped-User-Name := 'bobby'
+Stripped-User-Name := 'bobby'
 ldap
 if (!updated) {
        test_fail
@@ -18,6 +18,6 @@ if (reply.Reply-Message != 'User-Suspended') {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 51721667573b78dd05781474ec04a7bc2ea9ee31..f8f90e6606d44744c3fb12a158e6c818cf9d24ee 100644 (file)
@@ -9,7 +9,7 @@ if (!ok) {
         test_fail
 }
 
-&test_string := %ldap("ldap://$ENV{TEST_SERVER}/uid=bob,ou=people,dc=example,dc=com?description")
+test_string := %ldap("ldap://$ENV{TEST_SERVER}/uid=bob,ou=people,dc=example,dc=com?description")
 
 if (test_string != "User bob is online") {
         test_fail
index 6a9cba0326c979a023058f0c559a84d48081028c..a9e6021b72be055f129cb9f98864e2c32ec6b6a2 100644 (file)
@@ -51,41 +51,41 @@ ldap.authenticate
 
 ldap.send.access-accept
 
-&test_string := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?description")
+test_string := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?description")
 
 if (!(test_string == "User %{User-Name} authenticated")) {
        test_fail
 }
 
 # userPKCS12 is set to be updated from Class - which doesn't exist - check nothing was added
-&test_octets := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?userPKCS12")
+test_octets := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?userPKCS12")
 
 if (test_octets) {
        test_fail
 }
 
 # Add dummy octet data and re-run the LDAP update to check the data is added
-&Class := 0x01020304
+Class := 0x01020304
 ldap.send.access-accept
 
-&test_octets := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?userPKCS12")
+test_octets := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?userPKCS12")
 
 if (test_octets != 0x01020304) {
        test_fail
 }
 
 # Remove the RADIUS attribute and check that the update doesn't clear the LDAP attribute
-&request -= Class[*]
+request -= Class[*]
 ldap.send.access-accept
 
-&test_octets := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?userPKCS12")
+test_octets := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?userPKCS12")
 
 if (test_octets != 0x01020304) {
        test_fail
 }
 
 # carLicense is being populated with += - so there should be 3 instances now
-&control.Filter-Id := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?carLicense")
+control.Filter-Id := %ldap("ldap://$ENV{TEST_SERVER}/uid=john,ou=people,dc=example,dc=com?carLicense")
 if (control.Filter-Id[#] != 3) {
        test_fail
 }
index 695800f7f8155fa31f3710fd6f77ea21c6998605..730618fa988805dcbc3fa9f58d0a34667f998906 100644 (file)
@@ -24,7 +24,7 @@ ldap.authenticate
 
 ldap.send.access-accept
 
-&test_string := %ldap("ldap://$ENV{TEST_SERVER}/uid=peter,ou=people,dc=example,dc=com?description")
+test_string := %ldap("ldap://$ENV{TEST_SERVER}/uid=peter,ou=people,dc=example,dc=com?description")
 
 if (!(test_string == "User %{User-Name} authenticated")) {
        test_fail
index f1c98154cd3ddabfcfbdf476ea0efe0c54ce3ca0..4789eabf2530a0712b20116bb210d4580dae192b 100644 (file)
@@ -28,7 +28,7 @@ ldapssl.authenticate
 
 ldapssl.send.access-accept
 
-&test_string := %ldapssl("ldaps:///uid=fred,ou=people,dc=subdept,dc=example,dc=com?description")
+test_string := %ldapssl("ldaps:///uid=fred,ou=people,dc=subdept,dc=example,dc=com?description")
 
 if (!(test_string == "User %{User-Name} authenticated")) {
        test_fail
index 60cc0dafb877913fc9df30efea9e9f85cadaf17e..0bc339cae67c3b5143a74079d0c8e5e488841293 100644 (file)
@@ -29,7 +29,7 @@ ldaptls.authenticate
 
 ldaptls.send.access-accept
 
-&test_string := %ldaptls("ldap:///uid=joe,ou=people,dc=subdept,dc=example,dc=com?description")
+test_string := %ldaptls("ldap:///uid=joe,ou=people,dc=subdept,dc=example,dc=com?description")
 
 if (!(test_string == "User %{User-Name} authenticated")) {
        test_fail
index de8cc65b6648c7395323f71dac5f9e721b3e14d9..82e63f7619d9de0da4ae5b7262054fedcd69ca2b 100644 (file)
@@ -1,14 +1,14 @@
 
 string base_dn
 
-&base_dn=%ldap.uri.safe('dc=example,dc=com')
+base_dn=%ldap.uri.safe('dc=example,dc=com')
 ldap_dynamic_dn
 if (!ok) {
        test_fail
 }
 
 # Bad DN
-&base_dn := %ldap.uri.safe('dc=example,dc=foo,dc=com')
+base_dn := %ldap.uri.safe('dc=example,dc=foo,dc=com')
 ldap_dynamic_dn
 if (!notfound) {
        test_fail
index 0c637f6db055f120c12b44371068b17428687f65..00b1c8d4c4e439cdd16670cdd7331adbe4ca2d50 100644 (file)
@@ -1,5 +1,5 @@
 
-&net.src.ip := 1.1.1.1
+net.src.ip := 1.1.1.1
 
 map ldap "ldapi:///ou=clients,dc=example,dc=com??sub?(&(objectClass=radiusClient)(objectClass=freeradiusClient)(freeradiusClientIdentifier=%{net.src.ip}))" {
        #  secret
index 6c65cc99d151977790976c2344bf577aa65f9707..166a52e6ac7ff2c8a2f0d8808590e038cc46cc08 100644 (file)
@@ -5,106 +5,106 @@ string result_string
 #  Test the "ldap" module xlat escape functions
 #
 
-&test_string := "safe string"
+test_string := "safe string"
 
 # String with no escaping
-&result_string := %ldap.uri.escape(%{test_string})
+result_string := %ldap.uri.escape(%{test_string})
 
 if (!(result_string == "safe string")) {
         test_fail
 }
 
-&result_string := %ldap.uri.unescape(%{result_string})
+result_string := %ldap.uri.unescape(%{result_string})
 
 if (!(result_string == 'safe string')) {
         test_fail
 }
 
 # String with some characters to escape
-&test_string := 'non safe,+"\<>;*=() string'
-&result_string := %ldap.uri.escape(%{test_string})
+test_string := 'non safe,+"\<>;*=() string'
+result_string := %ldap.uri.escape(%{test_string})
 
 if (!(result_string == 'non safe\2c\2b\22\5c\3c\3e\3b\2a\3d\28\29 string')) {
         test_fail
 }
 
-&result_string := %ldap.uri.unescape(%{result_string})
+result_string := %ldap.uri.unescape(%{result_string})
 
 if (!(result_string == 'non safe,+"\<>;*=() string')) {
         test_fail
 }
 
 # String where all characters require escaping
-&test_string := ',+"\<>;*=()'
-&result_string := %ldap.uri.escape(%{test_string})
+test_string := ',+"\<>;*=()'
+result_string := %ldap.uri.escape(%{test_string})
 
 if (!(result_string == '\2c\2b\22\5c\3c\3e\3b\2a\3d\28\29')) {
         test_fail
 }
 
-&result_string := %ldap.uri.unescape(%{result_string})
+result_string := %ldap.uri.unescape(%{result_string})
 
 if (!(result_string == ',+"\<>;*=()')) {
         test_fail
 }
 
-&result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=people,dc=example,dc=com?displayName?sub?(uid=john)")
+result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=people,dc=example,dc=com?displayName?sub?(uid=john)")
 
 if (!(result_string == "John Doe")) {
         test_fail
 }
 
 # Return multiple values - could be in any sequence
-&Framed-IP-Address := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=clients,dc=example,dc=com?freeradiusClientIdentifier?sub?(objectClass=freeradiusClient)")
+Framed-IP-Address := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=clients,dc=example,dc=com?freeradiusClientIdentifier?sub?(objectClass=freeradiusClient)")
 
 if !((Framed-IP-Address[0] == "1.1.1.1") && (Framed-IP-Address[1] == "2.2.2.2")) {
         test_fail
 }
 
 # Use tainted string in filter - with special characters
-&result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=people,dc=example,dc=com?cn?sub?(displayName=*%{Filter-Id}*)")
+result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=people,dc=example,dc=com?cn?sub?(displayName=*%{Filter-Id}*)")
 
 if (!(result_string == "Bob Smith")) {
         test_fail
 }
 
 # A query which should return no results
-&result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=people,dc=example,dc=com?displayName?sub?(uid=notknown)")
+result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=people,dc=example,dc=com?displayName?sub?(uid=notknown)")
 
 if (result_string) {
         test_fail
 }
 
 # Request an invalid DN
-&result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=notthere?displayName?sub?(uid=john)")
+result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=notthere?displayName?sub?(uid=john)")
 
 if (result_string) {
         test_fail
 }
 
 # Query within a dn which will prompt a referral
-&result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/dc=subdept,dc=example,dc=com?displayName?sub?(uid=fred)")
+result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/dc=subdept,dc=example,dc=com?displayName?sub?(uid=fred)")
 
 if (!(result_string == "Fred Jones")) {
         test_fail
 }
 
 # Reference an alternative LDAP server in the xlat
-&result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:%ldap.uri.escape(%{$ENV{LDAP_TEST_SERVER_PORT} + 1})/dc=subdept,dc=example,dc=com?displayName?sub?(uid=fred)")
+result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:%ldap.uri.escape(%{$ENV{LDAP_TEST_SERVER_PORT} + 1})/dc=subdept,dc=example,dc=com?displayName?sub?(uid=fred)")
 
 if (!(result_string == "Fred Jones")) {
         test_fail
 }
 
 # This query will follow 2 referrals, the second will present an alternate search base
-&result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=offsite,dc=subdept,dc=example,dc=com?displayName?sub?(uid=john)")
+result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=offsite,dc=subdept,dc=example,dc=com?displayName?sub?(uid=john)")
 
 if (!(result_string == "John Doe")) {
         test_fail
 }
 
 # This query will follow 3 referrals - more than our max referral depth
-&result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=bounce1,dc=subdept,dc=example,dc=com?displayName?sub?(uid=fred)")
+result_string := %ldap("ldap://$ENV{LDAP_TEST_SERVER}:$ENV{LDAP_TEST_SERVER_PORT}/ou=bounce1,dc=subdept,dc=example,dc=com?displayName?sub?(uid=fred)")
 
 if (result_string) {
         test_fail
@@ -115,7 +115,7 @@ if (!(Module-Failure-Message == "Maximum LDAP referral depth (2) exceeded")) {
 }
 
 # Use an ldapi:// connection
-&result_string := %ldapldapi("ldapi:///ou=people,dc=example,dc=com?displayName?sub?(uid=john)")
+result_string := %ldapldapi("ldapi:///ou=people,dc=example,dc=com?displayName?sub?(uid=john)")
 
 if !(result_string == 'John Doe') {
        test_fail
index 7fbc297a9e77339f8108f21a81ae3f240db7f447..a57e9ec8efa9507c80d0be78a43636001802c721 100644 (file)
@@ -55,7 +55,7 @@ if (!((reply.Framed-IP-Netmask == 255.255.192.0) && \
        test_fail
 }
 
-&control := {}
-&reply := {}
+control := {}
+reply := {}
 
 test_pass
index 3d9b3b572cb87f4152751211d7029201fc40a93c..e200b86416da07e26686854e48769f043c025912 100644 (file)
@@ -12,7 +12,7 @@ if (!fail) {
 }
 
 #  References are not allowed to go to parent config sections
-&control.Filter-Id := '..messages.valid'
+control.Filter-Id := '..messages.valid'
 
 linelog_missingref {
        fail = 1
@@ -26,7 +26,7 @@ if !(Module-Failure-Message == 'linelog_missingref: Invalid path "..messages.val
 }
 
 #  Missing config items fall back to the default (which is not set)
-&control.Filter-Id := '.message.valid'
+control.Filter-Id := '.message.valid'
 
 linelog_missingref
 
@@ -35,7 +35,7 @@ if (!noop) {
 }
 
 #  Pointing at a config section is not valid
-&control.Filter-Id := '.messages'
+control.Filter-Id := '.messages'
 
 linelog_missingref {
        fail = 1
@@ -46,7 +46,7 @@ if !(Module-Failure-Message == 'linelog_missingref: Path ".messages" resolves to
 }
 
 #  Valid reference, but the message points to an attribute that doesn't exist - so no output
-&control.Filter-Id := 'messages.valid'
+control.Filter-Id := 'messages.valid'
 
 linelog_missingref
 
index ed172a7d7ff531d2c6da0136e72232c0fd1d0125..d383998600ea03212b237a74c8fe94c659c1db20 100644 (file)
@@ -1,7 +1,7 @@
 string test_string1
 string test_string2
 
-&control.Exec-Export := 'PATH="$ENV{PATH}:/bin:/usr/bin:/opt/bin:/usr/local/bin"'
+control.Exec-Export := 'PATH="$ENV{PATH}:/bin:/usr/bin:/opt/bin:/usr/local/bin"'
 
 #
 #  Remove old log files
@@ -10,12 +10,12 @@ string test_string2
 
 #  Raw attribute value should be written out without further molestation.
 #  Because the value is wrapped in '' the \n is left as \n.
-&control.Filter-Id := 'test_attr'
-&control.Callback-Id := 'foo\nbar'
+control.Filter-Id := 'test_attr'
+control.Callback-Id := 'foo\nbar'
 
 linelog_escapes
-&test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_escapes.log")
-&test_string2 := "%hex(%{test_string1})"
+test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_escapes.log")
+test_string2 := "%hex(%{test_string1})"
 
 #
 #  Note that there's a '5f6e' here, which is "\n"
@@ -28,7 +28,7 @@ else {
        test_fail
 }
 
-&test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_escapes.log")
+test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_escapes.log")
 
 #
 #  This is left alone, and not "\n" --> 0x0a, too.
@@ -42,12 +42,12 @@ else {
 
 #  Raw attribute value should be written out without further molestation.
 #  Because the value is wrapped in "" the \n is converted to 0x0a (binary).
-&control.Filter-Id := 'test_attr'
-&control.Callback-Id := "foo\nbar"
+control.Filter-Id := 'test_attr'
+control.Callback-Id := "foo\nbar"
 
 linelog_escapes
-&test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_escapes.log", 2)
-&test_string2 := "%hex(%{test_string1})"
+test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_escapes.log", 2)
+test_string2 := "%hex(%{test_string1})"
 
 if (test_string2 == '666f6f0a626172') {
        test_pass
@@ -56,7 +56,7 @@ else {
        test_fail
 }
 
-&test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_escapes.log")
+test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_escapes.log")
 
 if (test_string1 == "bar") {
        test_pass
index 101b795d4228261020f92b679d76988c486e19c5..69fab68412db4a023640a26dca5cc5b797c4b4c0 100644 (file)
@@ -1,6 +1,6 @@
 string test_string
 
-&control.Exec-Export := 'PATH="$ENV{PATH}:/bin:/usr/bin:/opt/bin:/usr/local/bin"'
+control.Exec-Export := 'PATH="$ENV{PATH}:/bin:/usr/bin:/opt/bin:/usr/local/bin"'
 
 #
 #  Remove old log files
@@ -8,9 +8,9 @@ string test_string
 %file.rm("$ENV{MODULE_TEST_DIR}/test_multi.log")
 
 #  Check multiple string type attributes are logged correctly
-&control.Filter-Id := 'test_multi_str'
+control.Filter-Id := 'test_multi_str'
 
-&control += {
+control += {
        Reply-Message = '0'
        Reply-Message = '1'
        Reply-Message = '2'
@@ -25,31 +25,31 @@ string test_string
 }
 
 linelog_ref_multi
-&test_string := %file.tail("$ENV{MODULE_TEST_DIR}/test_multi.log")
+test_string := %file.tail("$ENV{MODULE_TEST_DIR}/test_multi.log")
 
 if !(test_string == '0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, ') {
        test_fail
 }
 
 # Check octet type attributes are logged in raw form
-&control += {
+control += {
        Class = 0x686970706f    # Hippo
        Class = 0x0a            # new line
        Class = 0x626c6970706f  # Blippo
 }
 
-&control.Filter-Id := 'test_multi_octets'
+control.Filter-Id := 'test_multi_octets'
 
 linelog_ref_multi
 
-&test_string := %file.tail("$ENV{MODULE_TEST_DIR}/test_multi.log")
+test_string := %file.tail("$ENV{MODULE_TEST_DIR}/test_multi.log")
 
 if !(test_string == ', blippo, ') {
        test_fail
 }
 
 #  When no attributes that match are available, linelog should return noop
-&control.Filter-Id := 'test_empty'
+control.Filter-Id := 'test_empty'
 
 linelog_ref_multi
 if !(noop) {
index 45eefa1d82df07de90f13ee0147fa28feeda0693..59df34ef5eab7c403d66d452875073fa46b751e5 100644 (file)
@@ -9,7 +9,7 @@ control.Exec-Export := 'PATH="$ENV{PATH}:/bin:/usr/bin:/opt/bin:/usr/local/bin"'
 %file.rm("$ENV{MODULE_TEST_DIR}/test_a.log")
 
 #  Check linelog fails over to the default message (an xlat expansion)
-&control.Filter-Id := 'test_default'
+control.Filter-Id := 'test_default'
 
 linelog_fmt_and_ref
 test_string := %file.tail("$ENV{MODULE_TEST_DIR}/test_a.log")
index 4effdf13368a884786af394389c9f4b8e81d183a..f5ed7e668a2fe1fafcecd7e74ee6f654b666653b 100644 (file)
@@ -2,7 +2,7 @@ string test_string1
 string test_string2
 string test_string3
 
-&control.Exec-Export := 'PATH="$ENV{PATH}:/bin:/usr/bin:/opt/bin:/usr/local/bin"'
+control.Exec-Export := 'PATH="$ENV{PATH}:/bin:/usr/bin:/opt/bin:/usr/local/bin"'
 
 #
 #  Remove old log files
@@ -12,7 +12,7 @@ string test_string3
 if (%linelog_fmt_delim_xlat('bob') != 5) {
        test_fail
 }
-&test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_xlat.log")
+test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_xlat.log")
 
 if (test_string1 == 'bob, ') {
        test_pass
@@ -21,13 +21,13 @@ else {
        test_fail
 }
 
-&test_string2 := 'more'
-&test_string3 := 'bob'
+test_string2 := 'more'
+test_string3 := 'bob'
 
 if (%linelog_fmt_delim_xlat("%{test_string2}%{test_string3}") != 9) {
        test_fail
 }
-&test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_xlat.log")
+test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_xlat.log")
 if (test_string1 == 'bob, morebob, ') {
        test_pass
 }
@@ -46,7 +46,7 @@ if (%linelog_fmt_delim_xlat("{ \"foo\" : \"bar\", \"baz\" : \"boink\" }") == 36)
        test_fail
 }
 
-&test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_xlat.log")
+test_string1 := %file.tail("$ENV{MODULE_TEST_DIR}/test_xlat.log")
 
 if (test_string1 == '{ "foo" : "bar", "baz" : "boink" }, ') {
        test_pass
index 593fac7d7988d818b739b262d0f5ce27a0b4ac96..bd7c679b5bfcef3069fd6d3695e372e239dd2ede 100644 (file)
@@ -1,4 +1,4 @@
-&control.Password.Cleartext := "supersecret"
+control.Password.Cleartext := "supersecret"
 
 mschap
 
@@ -12,7 +12,7 @@ if !(reply.Vendor-Specific.Microsoft.CHAP-MPPE-Keys) {
        test_fail
 }
 
-&reply -= Vendor-Specific.Microsoft.CHAP-MPPE-Keys
+reply -= Vendor-Specific.Microsoft.CHAP-MPPE-Keys
 
 test_pass
 
index 54dd8eefb6587f05f31b609846618400dd750b51..f799c7bc362bc81c61872e225507871a97a3b1cd 100644 (file)
@@ -1,4 +1,4 @@
-&control.Password.Cleartext := "secret"
+control.Password.Cleartext := "secret"
 
 mschap
 
@@ -16,7 +16,7 @@ if !(reply.Vendor-Specific.Microsoft.MPPE-Recv-Key) {
        test_fail
 }
 
-&reply -= Vendor-Specific.Microsoft.MPPE-Send-Key
-&reply -= Vendor-Specific.Microsoft.MPPE-Recv-Key
+reply -= Vendor-Specific.Microsoft.MPPE-Send-Key
+reply -= Vendor-Specific.Microsoft.MPPE-Recv-Key
 
 test_pass
index c43a60dbbba56a19ab52d553810cfcbdfa1bce50..8778f1b74a1e5c98b6d6686e1d9c57af72e5d557 100644 (file)
@@ -1,4 +1,4 @@
-&control.Password.Cleartext := 'secret_123'
+control.Password.Cleartext := 'secret_123'
 
 mschap_winbind
 
@@ -24,6 +24,6 @@ if !(reply.Vendor-Specific.Microsoft.CHAP-MPPE-Keys) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 57b84196e761448b30177531f79acc140fc7ed94..c0eec218bef7586f72a5755d5e1c11b4069b56b5 100644 (file)
@@ -1,4 +1,4 @@
-&control.Password.Cleartext := "secret"
+control.Password.Cleartext := "secret"
 
 mschap
 
@@ -35,7 +35,7 @@ if !(reply.Vendor-Specific.Microsoft.MPPE-Recv-Key) {
        test_fail
 }
 
-&reply -= Vendor-Specific.Microsoft.MPPE-Send-Key
-&reply -= Vendor-Specific.Microsoft.MPPE-Recv-Key
+reply -= Vendor-Specific.Microsoft.MPPE-Send-Key
+reply -= Vendor-Specific.Microsoft.MPPE-Recv-Key
 
 test_pass
index e25d491c8c5c71481c36fcf0686cb89250945bc2..0884375b8f3a1a075faa64805bee611ec2fa220d 100644 (file)
@@ -1,4 +1,4 @@
-&control.Password.Cleartext := "SuperSecret"
+control.Password.Cleartext := "SuperSecret"
 
 mschap_ntlm
 
@@ -16,7 +16,7 @@ if !(reply.Vendor-Specific.Microsoft.MPPE-Recv-Key) {
        test_fail
 }
 
-&reply -= Vendor-Specific.Microsoft.MPPE-Send-Key
-&reply -= Vendor-Specific.Microsoft.MPPE-Recv-Key
+reply -= Vendor-Specific.Microsoft.MPPE-Send-Key
+reply -= Vendor-Specific.Microsoft.MPPE-Recv-Key
 
 test_pass
index 131e597c4a9767b63f234fbc5d5d3c50108a0180..f1765a9b8ffd1772bb7b8f3b7b54937d7a479151 100644 (file)
@@ -10,14 +10,14 @@ if !(reply.Reply-Message == "Denied access by rlm_perl function") {
     test_fail
 }
 
-&reply -= Reply-Message[*]
+reply -= Reply-Message[*]
 
 #  User will not be rejected - an xlat will be called setting a reply attribute
-&User-Name := 'bob'
+User-Name := 'bob'
 
 # Add two instances of a TLV - will result in an array of hashes in Perl
-&Vendor-Specific.3GPP2.Remote-IP = { Address = 192.168.1.1, Mask = 24 }
-&request.Vendor-Specific.3GPP2 += { Remote-IP = { Address = 172.16.1.1, Mask = 16 } }
+Vendor-Specific.3GPP2.Remote-IP = { Address = 192.168.1.1, Mask = 24 }
+request.Vendor-Specific.3GPP2 += { Remote-IP = { Address = 172.16.1.1, Mask = 16 } }
 
 perl.authenticate
 
@@ -40,7 +40,7 @@ if (control.NAS-Identifier) {
        test_fail
 }
 
-&reply -= Vendor-Specific[*]
-&reply -= Filter-Id[*]
+reply -= Vendor-Specific[*]
+reply -= Filter-Id[*]
 
 test_pass
index 9ce3a8614b250eda29705f4e155298e5436fb3f5..5af0f6ffec0981f3fa05c15433eb5ec4c56d6bdc 100644 (file)
@@ -6,44 +6,44 @@ uint32 result_integer
 #  PRE: update
 #
 
-&Filter-Id := 'hello,goodbye,welcome,farewell'
-&test_string := 'foo,bar'
-&Callback-Id := %perl_xlat('xlat', %{Filter-Id})
+Filter-Id := 'hello,goodbye,welcome,farewell'
+test_string := 'foo,bar'
+Callback-Id := %perl_xlat('xlat', %{Filter-Id})
 
 if (Callback-Id != 'hello|goodbye|welcome|farewell') {
        test_fail
 }
 
 # Check for multiple arguments to perl function
-&result_string := %perl_xlat('xlat', %{Filter-Id}, %{test_string})
+result_string := %perl_xlat('xlat', %{Filter-Id}, %{test_string})
 
 if (result_string != 'hello|goodbye|welcome|farewell#foo|bar') {
        test_fail
 }
 
-&result_integer := %perl_xlat('add', 1, 2, 3)
+result_integer := %perl_xlat('add', 1, 2, 3)
 
 if (result_integer != 6) {
        test_fail
 }
 
-&Filter-Id := 'hello'
-&request += {
+Filter-Id := 'hello'
+request += {
        Filter-Id = 'goodbye'
        Filter-Id = 'welcome'
 }
 
 # Pass a list as an array
-&Callback-Id := %perl_xlat('xlatarray', %{Filter-Id[*]})
+Callback-Id := %perl_xlat('xlatarray', %{Filter-Id[*]})
 
 if (Callback-Id != 'hello|goodbye|welcome') {
        test_fail
 }
 
-&Filter-Id := 'aa bb cc dd ee'
+Filter-Id := 'aa bb cc dd ee'
 
 # Expect an array of returned values
-&Callback-Id := %perl_xlat('xlatscalar2array', %{Filter-Id})
+Callback-Id := %perl_xlat('xlatscalar2array', %{Filter-Id})
 
 if (Callback-Id[#] != 5) {
        test_fail
@@ -52,10 +52,10 @@ if !((Callback-Id[0] == 'aa') && (Callback-Id[1] == 'bb') && (Callback-Id[2] ==
        test_fail
 }
 
-&test_string := 'ff gg hh ii'
+test_string := 'ff gg hh ii'
 
 # Expect an array of array ref returned values
-&Callback-Id := %perl_xlat('xlatscalar2arrayref', %{Filter-Id}, %{test_string})
+Callback-Id := %perl_xlat('xlatscalar2arrayref', %{Filter-Id}, %{test_string})
 
 if (Callback-Id[#] != 9) {
        test_fail
@@ -64,21 +64,21 @@ if !((Callback-Id[0] == 'aa') && (Callback-Id[1] == 'bb') && (Callback-Id[2] ==
        test_fail
 }
 
-&Filter-Id := 'a'
-&request += {
+Filter-Id := 'a'
+request += {
        Filter-Id = 'b'
        Filter-Id = 'c'
 }
 
 # Returns a hash with each element in the provided array converted to Vn->value
-&Callback-Id := %perl_xlat('xlatarray2hash', %{Filter-Id[*]})
+Callback-Id := %perl_xlat('xlatarray2hash', %{Filter-Id[*]})
 
 if (Callback-Id[#] != 6) {
        test_fail
 }
 
 # Note: hashes don't have a defined sequence so these are all the possible return values - mashed to single strings for simplicity's sake
-&result_string := "%{Callback-Id[*]}"
+result_string := "%{Callback-Id[*]}"
 if (result_string != "V1aV2bV3c") && (result_string != "V1aV3cV2b") && (result_string != "V2bV1aV3c") && (result_string != "V2bV3cV1a") && (result_string != "V3cV1aV2b") && (result_string != "V3cV2bV1a") {
        test_fail
 }
index f2089f1261be477c5b19282ca2ed8ab25bfe4268..4d29d4a0629e736d797e60c1baa4f4816fed98e8 100644 (file)
@@ -14,9 +14,9 @@ $INCLUDE cluster_reset.inc
 #  - 127.0.0.1:30005 - slave
 #  - 127.0.0.1:30003 - master [10923-16383]
 #  - 127.0.0.1:30006 - slave
-&testdata1 := "1-%randstr('aaaaaaaa')"
-&testdata2 := "2-%randstr('aaaaaaaa')"
-&testdata3 := "3-%randstr('aaaaaaaa')"
+testdata1 := "1-%randstr('aaaaaaaa')"
+testdata2 := "2-%randstr('aaaaaaaa')"
+testdata3 := "3-%randstr('aaaaaaaa')"
 
 #  Hashes to Redis cluster node master 1 (1)
 if (%redis(SET, b, %{testdata1}) == 'OK') {
index f7f8bcb682981143c4f3d4dc18f77eda04734583..27cccb8b47e959aac3809eb75dcfe84039634a48 100644 (file)
@@ -16,10 +16,10 @@ if (!(%redis(SET, b, 'boom') == 'OK')) {
 %delay(0.5)
 
 #  Note the current master
-&redismaster := %redis.node(b, 0)
+redismaster := %redis.node(b, 0)
 
 #  Note the current replica
-&redisreplica := %redis.node(b, 1)
+redisreplica := %redis.node(b, 1)
 
 #  Cause one of the redis cluster nodes to SEGV
 if (%redis(@%redis.node(b, 0), DEBUG, SEGFAULT)) {
index dfe4408a786144e1dd76dfe726f8b1d35458c4df..cafc8d2b5695ad7c7d0fd15412cf5c9833427999 100644 (file)
@@ -9,11 +9,11 @@ string data3
 string cmdresult
 
 # Some values we need for startup
-&control.Filter-Id := { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21 }
+control.Filter-Id := { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21 }
 
-&data1 := "1-%randstr('aaaaaaaa')"
-&data2 := "2-%randstr('aaaaaaaa')"
-&data3 := "3-%randstr('aaaaaaaa')"
+data1 := "1-%randstr('aaaaaaaa')"
+data2 := "2-%randstr('aaaaaaaa')"
+data3 := "3-%randstr('aaaaaaaa')"
 
 if ("$ENV{REDIS_CLUSTER_CONTROL}" == '') {
        clusterctrl := 'scripts/ci/redis-setup.sh'
@@ -30,7 +30,7 @@ if ("$ENV{REDIS_CLUSTER_CONTROL}" == '') {
 
 # Sometimes redis just fails to start - without it we can't run
 # the tests - so just exit early.
-&cmdresult = %exec(%{clusterctrl}, create)
+cmdresult = %exec(%{clusterctrl}, create)
 if (cmdresult == '') {
        test_pass
        handled
@@ -39,7 +39,7 @@ if (cmdresult == '') {
 #
 #  Determine when initial synchronisation has been completed
 #
-&redisserver := $ENV{REDIS_TEST_SERVER}
+redisserver := $ENV{REDIS_TEST_SERVER}
 
 if (!redisserver || (redisserver == '')) {
        redisserver := "$ENV{REDIS_IPPOOL_TEST_SERVER}"
index 0f87440f9e456ddd8cf8ecda706aefd76fdc0734..e8460ede25b21b42140bc0e7c721168da3c87858 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_alloc'
+control.IP-Pool.Name := 'test_alloc'
 
 #
 #  Add IP addresses
@@ -67,10 +67,10 @@ if !(reply.Session-Timeout == 30) {
        test_fail
 }
 
-&IP-Pool.Range := reply.IP-Pool.Range
-&Framed-IP-Address := reply.Framed-IP-Address
-&Session-Timeout := reply.Session-Timeout # We should get the same lease time
-&reply := {}
+IP-Pool.Range := reply.IP-Pool.Range
+Framed-IP-Address := reply.Framed-IP-Address
+Session-Timeout := reply.Session-Timeout # We should get the same lease time
+reply := {}
 
 #
 #  Add IP addresses
@@ -109,12 +109,12 @@ if ((Session-Timeout - reply.Session-Timeout) > 5) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 #
 #  Now change the Calling-Station-ID and check we get a different lease
 #
-&Calling-Station-ID := 'another_mac'
+Calling-Station-ID := 'another_mac'
 
 redis_ippool
 if (!updated) {
@@ -128,6 +128,6 @@ if !(reply.Framed-IP-Address == 192.168.1.1) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index caa358d63c9efa03c7c0ee2e309f07e4b736b727..9caeab8937d7af5d40f00c26e8224a5c69a45dd5 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_delete'
+control.IP-Pool.Name := 'test_delete'
 
 #
 #  Add IP addresses
@@ -48,6 +48,6 @@ if !(%redis(ZCOUNT, {%{control.IP-Pool.Name}%}:pool, -inf, +inf) == 0) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 8df47d93b1a2bf4d68227a5817c785edadf47e01..f03e81c57dbfbd80e65aa2c700a32a179c3ac481 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_tool_modify'
+control.IP-Pool.Name := 'test_tool_modify'
 
 #
 #  Add IP addresses
index 5e5d6aa09f9b83002e75fec8b41b894f1dfa94b2..4304f7ed7de4ff542e711c8d8183c14934e4b599 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_tool_release'
+control.IP-Pool.Name := 'test_tool_release'
 
 #
 #  Add IP addresses
@@ -56,6 +56,6 @@ if !(%redis(ZSCORE, {%{control.IP-Pool.Name}}:pool, %{reply.Framed-IP-Address})
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 54f1f70b7c177618dc1090b7fe1d797e8ff42566..8f5cf4d43b666d6f0abf9aad8e8e1e3d2e721f26 100644 (file)
@@ -4,7 +4,7 @@
 uint64 zscore
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_tool_static'
+control.IP-Pool.Name := 'test_tool_static'
 
 #
 #  Add a dynamic IP addresses
@@ -33,7 +33,7 @@ if !(reply.Framed-IP-Address == 192.168.0.10) {
 #
 #  Fetch the ZSCORE now on the address
 #
-&zscore := %redis(ZSCORE, {%{control.IP-Pool.Name}}:pool, %{reply.Framed-IP-Address})
+zscore := %redis(ZSCORE, {%{control.IP-Pool.Name}}:pool, %{reply.Framed-IP-Address})
 
 #
 #  Attempt to re-assign static lease
@@ -69,8 +69,8 @@ if !(%redis(GET, {%{control.IP-Pool.Name}}:device:aa:bb:cc:dd:ee:ff) == '192.168
 
 #
 #  Change device to grab the dynamic address
-&Calling-Station-ID := '11:22:33:44:55:66'
-&reply -= Framed-IP-Address[*]
+Calling-Station-ID := '11:22:33:44:55:66'
+reply -= Framed-IP-Address[*]
 
 redis_ippool {
        invalid = 1
@@ -98,7 +98,7 @@ if !(%redis(GET, {%{control.IP-Pool.Name}}:device:11:22:33:44:55:66) == '192.168
        test_fail
 }
 
-&zscore := %redis(ZSCORE, {%{control.IP-Pool.Name}}:pool, 192.168.0.1)
+zscore := %redis(ZSCORE, {%{control.IP-Pool.Name}}:pool, 192.168.0.1)
 if !(zscore < (uint64)0x10000000000000) {
        test_fail
 }
@@ -122,6 +122,6 @@ if (%redis(TTL, {%{control.IP-Pool.Name}}:device:%{Calling-Station-Id}) != '-1')
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index b738f7ce842600c2678f7216f91a7dc2558242c2..b7868f5bff5ac296cabe1970c124d25b35104b11 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_release'
+control.IP-Pool.Name := 'test_release'
 
 #
 #  Add IP addresses
@@ -27,7 +27,7 @@ if (!(reply.Framed-IP-Address == 192.168.0.1)) {
 #
 #  Release the IP address
 #
-&Framed-IP-Address := reply.Framed-IP-Address
+Framed-IP-Address := reply.Framed-IP-Address
 
 redis_ippool.release {
        invalid = 1
@@ -70,7 +70,7 @@ if ((%c - %redis(ZSCORE, {%{control.IP-Pool.Name}}:pool, %{reply.Framed-IP-Addre
 #
 #  Release the IP address again (should still be fine)
 #
-&Framed-IP-Address := reply.Framed-IP-Address
+Framed-IP-Address := reply.Framed-IP-Address
 
 redis_ippool.release {
        invalid = 1
@@ -81,4 +81,4 @@ if (updated) {
        test_fail
 }
 
-&reply := {}
+reply := {}
index ab5c9ca7df96304dfbf435813f19978937c4e997..1afd7aba2d7c11cb3b1fbb5bbd5922cf323207d9 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_static'
+control.IP-Pool.Name := 'test_static'
 
 #
 #  Add a dynamic IP addresses
@@ -40,7 +40,7 @@ if (!(reply.Session-Timeout == 30)) {
 #
 #  Check that renewal does not mess with static IP
 #
-&Framed-IP-Address := reply.Framed-IP-Address
+Framed-IP-Address := reply.Framed-IP-Address
 
 redis_ippool.renew {
        invalid = 1
@@ -89,6 +89,6 @@ if (%redis(ZSCORE, {%{control.IP-Pool.Name}%}:pool, %{reply.Framed-IP-Address})
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 9040d40a1b6ffa1646b57a3483fbacc5e34ea368..0d975f6a5f78d49a3926e4d302291dd0d8c4af16 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_static_dynamic'
+control.IP-Pool.Name := 'test_static_dynamic'
 
 #
 #  Add a static IP assigned to a calling station not in the request
@@ -39,6 +39,6 @@ if (!(reply.Framed-IP-Address == 192.168.0.1)) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index e3ddf69fa4f73e8501041eb3478ae444a82956d6..04ed8047f5da7724ad190a0f3b947c00bfc5e8ad 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_static_unassign'
+control.IP-Pool.Name := 'test_static_unassign'
 
 #
 #  Add a dynamic IP addresses
@@ -61,7 +61,7 @@ if (%redis(TTL, {%{control.IP-Pool.Name}}:device:%{Calling-Station-Id}) < 20) {
 #
 #  Check that renewal still works as we are within the exipiry time
 #
-&Framed-IP-Address := reply.Framed-IP-Address
+Framed-IP-Address := reply.Framed-IP-Address
 
 redis_ippool.renew {
        invalid = 1
@@ -98,9 +98,9 @@ if (%redis(ZSCORE, {%{control.IP-Pool.Name}%}:pool, %{reply.Framed-IP-Address})
 #  Perform IP allocation for alternative device
 #  Should be allocated the previously static address as that is the only one in the pool
 #
-&reply -= Framed-IP-Address[*]
-&request -= Framed-IP-Address[*]
-&Calling-Station-Id := '00:11:22:33:44:55'
+reply -= Framed-IP-Address[*]
+request -= Framed-IP-Address[*]
+Calling-Station-Id := '00:11:22:33:44:55'
 
 redis_ippool.allocate {
        invalid = 1
@@ -121,6 +121,6 @@ if !(%redis(HGET, {%{control.IP-Pool.Name}}:ip:%{reply.Framed-IP-Address}, devic
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index b21ef9cc0cba51ac1977e8eee760970c1eb21fa8..e3c0db4f2d1fc41f109601872d0276e84d91eab2 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_update'
+control.IP-Pool.Name := 'test_update'
 
 #
 #  Add IP addresses
@@ -35,8 +35,8 @@ if !(%redis(HGET, {%{control.IP-Pool.Name}}:ip:%{reply.Framed-IP-Address}, gatew
 %exec(./build/bin/local/rlm_redis_ippool_tool, -a, 192.168.1.1/32, $ENV{REDIS_IPPOOL_TEST_SERVER}:30001, %{control.IP-Pool.Name}, 192.168.1.0)
 
 # 6. Verify that the lease time is extended
-&Framed-IP-Address := reply.Framed-IP-Address
-&NAS-IP-Address := 127.0.0.2
+Framed-IP-Address := reply.Framed-IP-Address
+NAS-IP-Address := 127.0.0.2
 
 redis_ippool.renew
 if (!updated) {
@@ -79,7 +79,7 @@ if !(reply.IP-Pool.Range && (reply.IP-Pool.Range == '192.168.0.0')) {
 }
 
 # Change the ip address to one that doesn't exist in the pool and check we *can't* update it
-&Framed-IP-Address := 192.168.3.1
+Framed-IP-Address := 192.168.3.1
 
 redis_ippool.renew {
        invalid = 1
@@ -88,10 +88,10 @@ redis_ippool.renew {
 if (!notfound) {
        test_fail
 }
-&Framed-IP-Address := 192.168.0.1
+Framed-IP-Address := 192.168.0.1
 
 # 15. Now change the calling station ID and check that we *can't* update the lease
-&Calling-Station-ID := 'naughty'
+Calling-Station-ID := 'naughty'
 
 redis_ippool.renew {
        invalid = 1
@@ -105,6 +105,6 @@ if !(reply.Framed-IP-Address == %redis(GET, {%{control.IP-Pool.Name}}:device:00:
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index ae4a734700f2844fd85cada42fc52846d5f65f9e..85164c0815f342ade2e9039caab5caaea90fdccc 100644 (file)
@@ -3,7 +3,7 @@
 #
 $INCLUDE cluster_reset.inc
 
-&control.IP-Pool.Name := 'test_update_alloc'
+control.IP-Pool.Name := 'test_update_alloc'
 
 #
 #  Add IP addresses
@@ -19,8 +19,8 @@ if (!updated) {
 #
 #  Attempt to reserve an IP address by performing a renew
 #
-&Framed-IP-Address := 192.168.0.1
-&NAS-IP-Address := 127.0.0.1
+Framed-IP-Address := 192.168.0.1
+NAS-IP-Address := 127.0.0.1
 
 redis_ippool.renew
 
@@ -39,6 +39,6 @@ if !(reply.Framed-IP-Address == 192.168.0.1) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 831ce0e19d79bc0f26ba4957e3ace73653d77f4d..52c937c8ef016b544bde3cdd85a4aeea38a969cc 100644 (file)
@@ -1,5 +1,5 @@
 # Pre-set Login-LAT-Node to check correct operator behaviour
-&control.Login-LAT-Node := "foo"
+control.Login-LAT-Node := "foo"
 
 # Test "authorize" rest call.  Uses http to a GET end point
 rest
@@ -32,12 +32,12 @@ if (!(control.Login-LAT-Node[0] == "Bob") || !(control.Login-LAT-Node[1] == "foo
 }
 
 # Reset control attributes
-&control -= Filter-Id[*]
-&control -= Callback-Id[*]
-&control -= User-Name[*]
+control -= Filter-Id[*]
+control -= Callback-Id[*]
+control -= User-Name[*]
 
 # Pre-fill NAS-IP-Address to check operator behaviour
-&control.NAS-IP-Address := "10.0.0.10"
+control.NAS-IP-Address := "10.0.0.10"
 test_pass
 handled
 # Test "accounting" rest call.  Uses https to a POST end point
index e5fd37e83c990d688ac644646b78ea210e298503..6c1d66bc7858124b3834f3298b805aa71388a017 100644 (file)
@@ -1,5 +1,5 @@
 # Pre-set Login-LAT-Node to check correct operator behaviour
-&control.Login-LAT-Node := "foo"
+control.Login-LAT-Node := "foo"
 
 # Test "authorize" rest call.  Uses http to a GET end point
 
index 57f6e721511d5ff0438bb4b4ebb434e261a12c2b..e96b7689c51821892f2063a0ef6d734a3b06350a 100644 (file)
@@ -7,13 +7,13 @@ uint32 server_ssl_port
 string test_string
 string result_string
 
-&server_host := "$ENV{REST_TEST_SERVER}"
-&server_port := "$ENV{REST_TEST_SERVER_PORT}"
-&server_ssl_port := "$ENV{REST_TEST_SERVER_SSL_PORT}"
-&test_string := 'notfound'
+server_host := "$ENV{REST_TEST_SERVER}"
+server_port := "$ENV{REST_TEST_SERVER_PORT}"
+server_ssl_port := "$ENV{REST_TEST_SERVER_SSL_PORT}"
+test_string := 'notfound'
 
 # Retrieve a plain text file
-&result_string := %rest('GET', "http://%{server_host}:%uri.safe(%{server_port})/test.txt")
+result_string := %rest('GET', "http://%{server_host}:%uri.safe(%{server_port})/test.txt")
 
 if (!(REST-HTTP-Status-Code == 200)) {
        test_fail
@@ -24,28 +24,28 @@ if (!(result_string == "Sample text response\n")) {
 }
 
 # Take host from incoming packet
-&result_string := %rest('GET', "http://%{Login-IP-Host}:%uri.safe(%{server_port})/test.txt")
+result_string := %rest('GET', "http://%{Login-IP-Host}:%uri.safe(%{server_port})/test.txt")
 
 if (!(REST-HTTP-Status-Code == 200) || !(result_string == "Sample text response\n")) {
        test_fail
 }
 
 # Port is not allowed from incoming packets
-&result_string := %rest('GET', "http://%{server_host}:%{NAS-Port}/test.txt")
+result_string := %rest('GET', "http://%{server_host}:%{NAS-Port}/test.txt")
 
 if (!(Module-Failure-Message == "Failed escaping URI: Unsafe input \"8080\" not allowed in URI part port") || result_string) {
        test_fail
 }
 
 # Check a "not found" gives a 404 status code
-&result_string := %rest('GET', "http://%{server_host}:%uri.safe(%{server_port})/%{test_string}")
+result_string := %rest('GET', "http://%{server_host}:%uri.safe(%{server_port})/%{test_string}")
 
 if (!(REST-HTTP-Status-Code == 404)) {
        test_fail
 }
 
 # GET with URL parameters
-&test_string := %rest('GET', "http://%{server_host}:%uri.safe(%{server_port})/user/%{User-Name}/mac/%{Called-Station-Id}")
+test_string := %rest('GET', "http://%{server_host}:%uri.safe(%{server_port})/user/%{User-Name}/mac/%{Called-Station-Id}")
 
 if (!(REST-HTTP-Status-Code == 200)) {
        test_fail
@@ -64,7 +64,7 @@ if (!(control.User-Name == "Bob")) {
        test_fail
 }
 
-&control.User-Name := 'dummy'
+control.User-Name := 'dummy'
 
 # Directly use json map and prepend the returned value
 map json %rest('GET', "http://%{server_host}:%uri.safe(%{server_port})/user/%{User-Name}/mac/%{Called-Station-Id}") {
@@ -75,10 +75,10 @@ if (!(control.User-Name[0] == 'Bob') || !(control.User-Name[1] == 'dummy')) {
        test_fail
 }
 
-&test_string := %json.encode('request.NAS-IP-Address')
+test_string := %json.encode('request.NAS-IP-Address')
 
 # POST to https with JSON body data
-&result_string := %rest('POST', "https://%{server_host}:%uri.safe(%{server_ssl_port})/user/%{User-Name}/mac/%{Called-Station-Id}?section=accounting", %{test_string})
+result_string := %rest('POST', "https://%{server_host}:%uri.safe(%{server_ssl_port})/user/%{User-Name}/mac/%{Called-Station-Id}?section=accounting", %{test_string})
 
 if (!(REST-HTTP-Status-Code == 200)) {
        test_fail
@@ -102,10 +102,10 @@ if (!(control.NAS-IP-Address == "192.168.1.1")) {
        test_fail
 }
 
-&result_string := "NAS=%{NAS-IP-Address}&user=%{User-Name}"
+result_string := "NAS=%{NAS-IP-Address}&user=%{User-Name}"
 
 # POST to https with POST body data
-&result_string := %rest('POST', "https://%{server_host}:%uri.safe(%{server_ssl_port})/post/test?section=dummy", %{result_string})
+result_string := %rest('POST', "https://%{server_host}:%uri.safe(%{server_ssl_port})/post/test?section=dummy", %{result_string})
 
 if (!(REST-HTTP-Status-Code == 200)) {
        test_fail
@@ -202,7 +202,7 @@ group {
 }
 
 # Test against endpoint which will time out
-&result_string := %restshorttimeout('GET', "http://%{server_host}:%uri.safe(%{server_port})/delay")
+result_string := %restshorttimeout('GET', "http://%{server_host}:%uri.safe(%{server_port})/delay")
 
 if (REST-HTTP-Status-Code) {
        test_fail
index 896d4d184814d0a54d8f15b4b7923c29f7636ada..379e0deb31d57af1a5655f3e04d979c6dff6950e 100644 (file)
@@ -1,4 +1,4 @@
-&request += {
+request += {
        SMTP-Mail-Header = "x-test-Subject: smtp test"
        SMTP-Mail-Body = "sent from the smtp test module\r\n"
 
index e0a3b2ccde8480230259939098c0095f2adb6ab7..64979dad8a373394b559fc097a63e1eb3dddbebd 100644 (file)
@@ -1,4 +1,4 @@
-&request += {
+request += {
        SMTP-Mail-Header = "Subject: smtp test"
        SMTP-Mail-Header = "FROM: smtp_sender@gmail.com"
        SMTP-Mail-Header = "TO: smtp_receiver@localhost"
@@ -27,7 +27,7 @@ if !(ok) {
 #
 #  Check the wrong password results in a reject
 #
-&User-Password := 'Wrong'
+User-Password := 'Wrong'
 
 smtp.authenticate {
        reject = 1
@@ -46,8 +46,8 @@ if !(reject) {
 #
 #  Check an invalid user results in a reject
 #
-&User-Name := 'Invalid'
-&User-Password := 'Saget'
+User-Name := 'Invalid'
+User-Password := 'Saget'
 
 smtp.authenticate {
        reject = 1
@@ -62,7 +62,7 @@ if !(reject) {
        test_fail
 }
 
-&request -= User-Password[*]
+request -= User-Password[*]
 
 #
 #  Check that missing password is an invalid request
@@ -76,8 +76,8 @@ if !(invalid) {
        test_fail
 }
 
-&User-Password := 'Saget'
-&request -= User-Name[*]
+User-Password := 'Saget'
+request -= User-Name[*]
 
 #
 #  Check that missing user name is an invalid request
index 340cdca6325ef2410e09cdf6fd383e596f4605ae..664afd17d772514ef286e2d9ca286055a8c10fed 100644 (file)
@@ -1,4 +1,4 @@
-&request += {
+request += {
        SMTP-Mail-Body = "sent from the smtp test module\r\n"
        SMTP-Mail-Body = "\r\n"
        SMTP-Mail-Body = "Some Body\r\n"
index b22236d6f2961dc289de2be4cef163265caa0859..bae40faf4f9447cdc504bc1048e589006dc2587f 100644 (file)
@@ -1,4 +1,4 @@
-&request += {
+request += {
        SMTP-Mail-Body = "sent from the smtp test module\r\n"
        SMTP-Recipients = "stringparse_test_receiver@localhost"
        SMTP-Sender-Address = "smtp_sender@localhost"
index e91ad642480698ce83f2f8da8e7c803a772bf4f2..d440b57db4ad97dfb2b5d7e482d35a808d570e86 100644 (file)
@@ -1,4 +1,4 @@
-&request += {
+request += {
        SMTP-Mail-Header = "x-test-Subject: smtp test"
        SMTP-Mail-Body = "sent from the smtp test module\r\n"
 
@@ -45,12 +45,12 @@ echo $?"` == "1") {
 #
 if (!(`/bin/bash -c "for i in {0..50} ; \
 do if [ -e build/ci/exim4/mail/smtp_cc_request_1 ] \
-&& [ -e build/ci/exim4/mail/smtp_cc_request_2 ] \
-&& [ -e build/ci/exim4/mail/smtp_to_request_1 ] \
-&& [ -e build/ci/exim4/mail/smtp_to_request_2 ] \
-&& [ -e build/ci/exim4/mail/smtp_recipient_request ] \
-&& [ -e build/ci/exim4/mail/conf_recipient_1 ] \
-&& [ -e build/ci/exim4/mail/conf_recipient_2 ] ;\
+& [ -e build/ci/exim4/mail/smtp_cc_request_2 ] \
+& [ -e build/ci/exim4/mail/smtp_to_request_1 ] \
+& [ -e build/ci/exim4/mail/smtp_to_request_2 ] \
+& [ -e build/ci/exim4/mail/smtp_recipient_request ] \
+& [ -e build/ci/exim4/mail/conf_recipient_1 ] \
+& [ -e build/ci/exim4/mail/conf_recipient_2 ] ;\
 then \
 echo 'found' ;\
 break; \
@@ -70,7 +70,7 @@ grep -f build/ci/exim4/testfile"`){
        test_fail
 }
 
-&request := {
+request := {
        SMTP-Mail-Header = "x-test-Subject: 2nd smtp test"
        SMTP-Mail-Body = "sent from the smtp test module\r\n"
 
index a324b18ac5227492ebb638ebfc136bdb428eb049..892f6bffd8ff181e81464c2e5b73294b8a3decba 100644 (file)
@@ -32,7 +32,7 @@ if (%sql("SELECT acctsessiontime FROM radacct WHERE AcctSessionId = '00000003'")
 #
 #  Change acctsessiontime and verify it's updated
 #
-&Connect-Info = 'updated'
+Connect-Info = 'updated'
 
 sql.accounting.start
 if !(ok) {
index aa76e21d3dc5c5c9b240cb7b3a1c2e1a489ab403..8c4f313cc8d0b28f0c29444fa68c575de58eb84f 100644 (file)
@@ -84,7 +84,7 @@ if (%sql.group('groups_group_d')) {
 #
 #  Test paircmp group comparisons with dynamic expansions
 #
-&groupname := 'groups_group_b'
+groupname := 'groups_group_b'
 
 if !(%sql.group(%{groupname})) {
        test_fail
index 6ae342c792c58c6ccf34899321dca1a1aa7d9d3c..62f0e5f8d228745983ecef31525fc386b1b98b9b 100644 (file)
@@ -54,9 +54,9 @@ if !(control.NAS-Port == 0) {
 }
 
 # Clear the control list
-&control -= User-Name[*]
-&control -= Filter-Id[*]
-&control -= NAS-Port[*]
+control -= User-Name[*]
+control -= Filter-Id[*]
+control -= NAS-Port[*]
 
 # Insert our second test row
 %sql("INSERT INTO radusergroup (username, groupname, priority) VALUES ('oof', 'rab', 1)")
@@ -85,9 +85,9 @@ if !(control.NAS-Port == 1) {
 }
 
 # Clear the control list
-&control -= User-Name[*]
-&control -= Filter-Id[*]
-&control -= NAS-Port[*]
+control -= User-Name[*]
+control -= Filter-Id[*]
+control -= NAS-Port[*]
 
 # Retrieve our test row(s) - With = we should get the values from the first row
 map sql 'SELECT * FROM radusergroup WHERE priority <= 1 ORDER BY priority' {
@@ -113,9 +113,9 @@ if !(control.NAS-Port == 0) {
 }
 
 # Clear the control list
-&control -= User-Name[*]
-&control -= Filter-Id[*]
-&control -= NAS-Port[*]
+control -= User-Name[*]
+control -= Filter-Id[*]
+control -= NAS-Port[*]
 
 # Retrieve our test row(s) - With ^= we should get the values from the second row then the first
 map sql 'SELECT * FROM radusergroup WHERE priority <= 1 ORDER BY priority' {
@@ -143,9 +143,9 @@ if ((control.NAS-Port[0] != 1) || (control.NAS-Port[1] != 0)) {
 }
 
 # Clear the control list
-&control -= User-Name[*]
-&control -= Filter-Id[*]
-&control -= NAS-Port[*]
+control -= User-Name[*]
+control -= Filter-Id[*]
+control -= NAS-Port[*]
 
 # Retrieve our test row(s) - With += we should get the values from both rows
 map sql 'SELECT * FROM radusergroup WHERE priority <= 1 ORDER BY priority' {
@@ -188,9 +188,9 @@ else {
 }
 
 # Clear the control list
-&control -= User-Name[*]
-&control -= Filter-Id[*]
-&control -= NAS-Port[*]
+control -= User-Name[*]
+control -= Filter-Id[*]
+control -= NAS-Port[*]
 
 # Retrieve the username column only (should result in noop because not in map)
 map sql 'SELECT username FROM radusergroup WHERE priority = 0' {
@@ -225,12 +225,12 @@ if !(control.NAS-Port == 0) {
        test_fail
 }
 
-&sqlcmd := %sql.safe("SELECT * FROM radusergroup WHERE priority <= 1 AND username = '%sql.escape(%{User-Name})'")
+sqlcmd := %sql.safe("SELECT * FROM radusergroup WHERE priority <= 1 AND username = '%sql.escape(%{User-Name})'")
 
 # Clear the control list
-&control -= User-Name[*]
-&control -= Filter-Id[*]
-&control -= NAS-Port[*]
+control -= User-Name[*]
+control -= Filter-Id[*]
+control -= NAS-Port[*]
 
 # Retrieve test row with specific username (using ref'd query)
 map sql sqlcmd {
@@ -256,12 +256,12 @@ if !(control.NAS-Port == 0) {
 }
 
 # Clear the control list
-&control -= User-Name[*]
-&control -= Filter-Id[*]
-&control -= NAS-Port[*]
+control -= User-Name[*]
+control -= Filter-Id[*]
+control -= NAS-Port[*]
 
-&userfield := 'username'
-&groupfield := 'name'
+userfield := 'username'
+groupfield := 'name'
 
 # Retrieve our test row(s) - Using different RHS types
 map sql 'SELECT * FROM radusergroup WHERE priority = 0' {
@@ -296,8 +296,8 @@ if (!notfound) {
 }
 
 # Clear the control list
-&control -= User-Name[*]
-&control -= Filter-Id[*]
+control -= User-Name[*]
+control -= Filter-Id[*]
 
 # Check behaviour of NULL vs empty string returns.
 # radacct is used here as the default schema allows NULL in many columns
index 09274439ec0ca063927c037dfa5180e4dc2f548c..ba4994ec5c3cf6dddeb9081c0f01baa5e767e858 100644 (file)
@@ -22,7 +22,7 @@ if (!noop) {
 #
 #  Now set a limit and re-call the module
 #
-&control.Max-Daily-Session := 100
+control.Max-Daily-Session := 100
 
 dailycounter
 if (!updated) {
@@ -43,12 +43,12 @@ if !(reply.Session-Timeout == 100) {
 #
 #  Calculate the start date/time to compare with attribute set by the module
 #
-&date_str = %date('now')
-&now = %date(%{date_str})
+date_str = %date('now')
+now = %date(%{date_str})
 if (date_str =~ /([0-9]{4}-[0-9]{2}-[0-9]{2}T)[0-9]{2}:[0-9]{2}:[0-9]{2}Z/) {
        date_str := "%{1}" + '00:00:00Z'
 }
-&start = %date(%{date_str})
+start = %date(%{date_str})
 
 if !(control.dailycounter-Reset-Start == start) {
        test_fail
@@ -104,7 +104,7 @@ if !(reply.Session-Timeout == 40) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 #
 #  Insert a second fake accounting record, which when summed with the existing will exceed the limit.
@@ -129,10 +129,10 @@ if !(control.Daily-Session-Time == 109) {
 #  Find how much time is left before the next reset and set the limit
 #  so the user has enough remaining to get into the next period
 #
-&remaining = control.dailycounter-Reset-End - now
-&control.Max-Daily-Session := remaining + 110
+remaining = control.dailycounter-Reset-End - now
+control.Max-Daily-Session := remaining + 110
 
-&reply := {}
+reply := {}
 
 dailycounter
 
@@ -140,7 +140,7 @@ if !(reply.Session-Timeout == (control.Max-Daily-Session - 109)) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 #
 #  Now use module instance with auto_extend = yes
@@ -153,6 +153,6 @@ if !((reply.Session-Timeout > (remaining + control.Max-Daily-Session - 2)) && (r
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index ac7e3bbafbcfc538a6d9fcffd1a2c2806019ac8b..1f26f41039c7d1a30e3ce68ed894ed1b42ce5f28 100644 (file)
@@ -2,7 +2,7 @@
 #  Allocate an address from an SQL IP Pool
 #
 uint32 expiry
-&control.IP-Pool.Name := 'test_alloc'
+control.IP-Pool.Name := 'test_alloc'
 
 #
 #  Add IP addresses
@@ -25,7 +25,7 @@ if !(reply.Framed-IP-Address == 192.168.0.1) {
 #
 #  Check Expiry
 #
-&expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
+expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
 if ((expiry - %l) < 20) {
        test_fail
 }
@@ -46,8 +46,8 @@ if !(%sql("SELECT gateway FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Na
        test_fail
 }
 
-&Framed-IP-Address := reply.Framed-IP-Address
-&reply := {}
+Framed-IP-Address := reply.Framed-IP-Address
+reply := {}
 
 #
 #  Add IP addresses
@@ -69,12 +69,12 @@ if !(Framed-IP-Address == reply.Framed-IP-Address) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 #
 #  Now change the Calling-Station-ID and check we get a different lease
 #
-&Calling-Station-ID := 'another_mac'
+Calling-Station-ID := 'another_mac'
 
 sqlippool.allocate
 if (!updated) {
@@ -88,6 +88,6 @@ if !(reply.Framed-IP-Address == 192.168.1.1) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 0fffcc7bdc7988183bafdf161c1a69e2b09df647..e1a2822c70c561745484d88ff3cb90b52ddfcdae 100644 (file)
@@ -2,7 +2,7 @@
 #  Allocate an address from an SQL IP Pool
 #
 uint32 expiry
-&control.IP-Pool.Name := 'test_alloc_fail'
+control.IP-Pool.Name := 'test_alloc_fail'
 
 #
 #  Ensure no matching records
@@ -38,12 +38,12 @@ if !(reply.Framed-IP-Address == 192.168.0.1) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 #
 #  Now change the Calling-Station-ID and check we don't get an address (pool full)
 #
-&Calling-Station-ID := 'another_mac'
+Calling-Station-ID := 'another_mac'
 
 sqlippool.allocate
 if (!notfound) {
index 304849d7ec184038d8441149ce209aff6af00cd4..e5fa6ab289d9726bae10ef5dd2c85b8d14ab1fc8 100644 (file)
@@ -2,7 +2,7 @@
 #  Allocate an address from an SQL IP Pool
 #
 uint32 expiry
-&control.IP-Pool.Name := 'test_alloc_requested'
+control.IP-Pool.Name := 'test_alloc_requested'
 
 #
 #  Add IP addresses
@@ -28,7 +28,7 @@ if !(reply.Framed-IP-Address == 192.168.0.2) {
 #
 #  Check Expiry
 #
-&expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
+expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
 if ((expiry - %l) < 20) {
        test_fail
 }
@@ -49,13 +49,13 @@ if !(%sql("SELECT gateway FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Na
        test_fail
 }
 
-&reply := {}
-&request -= Framed-IP-Address
+reply := {}
+request -= Framed-IP-Address
 
 #
 #  Now change the Calling-Station-ID and check we get a different lease
 #
-&Calling-Station-ID := 'another_mac'
+Calling-Station-ID := 'another_mac'
 
 sqlippool.allocate
 if (!updated) {
@@ -69,6 +69,6 @@ if !(reply.Framed-IP-Address == 192.168.0.3) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 120982f3018fb7355c917ae2a5fa87af8e5fa7ad..5886b25b8c9b1eebf11234a6beb64fab48438371 100644 (file)
@@ -2,7 +2,7 @@
 #  Test releasing IP addresses in the sqlippool module
 #
 uint32 expiry
-&control.IP-Pool.Name := 'test_release'
+control.IP-Pool.Name := 'test_release'
 
 #
 #  Add IP addresses
@@ -25,7 +25,7 @@ if !(reply.Framed-IP-Address == 192.168.0.1) {
 #
 #  Release the IP address
 #
-&Framed-IP-Address := reply.Framed-IP-Address
+Framed-IP-Address := reply.Framed-IP-Address
 
 sqlippool.release
 if !(updated) {
@@ -42,7 +42,7 @@ if (%sql("SELECT address FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Nam
 
 # Check the expiry - releasing an address sets the exipry to now
 # Allow for some time passing between packet processing and "now"
-&expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
+expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
 if (expiry > (%l + 5)) {
        test_fail
 }
@@ -55,7 +55,7 @@ if ((%l - expiry) > 5) {
 #  Release the IP address again
 #  Will return notfound as address is already released.
 #
-&Framed-IP-Address := reply.Framed-IP-Address
+Framed-IP-Address := reply.Framed-IP-Address
 
 sqlippool.release
 
@@ -63,6 +63,6 @@ if (!notfound) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index bb9411927349149f6be9a10e4692d18790853624..3076c31d29de1cf5ebe662622879d4c05d33d741 100644 (file)
@@ -1,7 +1,7 @@
 #
 #  Test static IP allocation using sqlippool
 #
-&control.IP-Pool.Name := 'test_static'
+control.IP-Pool.Name := 'test_static'
 
 #
 #  Add a dynamic IP addresses
@@ -31,7 +31,7 @@ if !(reply.Framed-IP-Address == 192.168.0.10) {
 #
 #  Check that renewal does not mess with static IP
 #
-&Framed-IP-Address := reply.Framed-IP-Address
+Framed-IP-Address := reply.Framed-IP-Address
 
 sqlippool.renew
 if !(updated) {
@@ -59,6 +59,6 @@ if (%sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index 445ad4f5d255abb408e641196d8cf458066e7ed6..1e19dc3f2ac0bd7e87fd182c63b045f5f2403438 100644 (file)
@@ -2,7 +2,7 @@
 #  Test updates on sqlippool allocated addresses.
 #
 uint32 expiry
-&control.IP-Pool.Name := 'test_update'
+control.IP-Pool.Name := 'test_update'
 
 #
 #  Add IP addresses
@@ -22,7 +22,7 @@ if !(reply.Framed-IP-Address == 192.168.0.1) {
 }
 
 # 3. Verify expiry time is based on offer duration
-&expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
+expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
 if ((expiry - %l) < 20) {
        test_fail
 }
@@ -42,8 +42,8 @@ if !(%sql("SELECT gateway FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Na
 %sql("INSERT INTO fr_ippool (pool_name, address, expiry_time) values ('%{control.IP-Pool.Name}', '192.168.1.1', datetime('now', '-00:10'))")
 
 # 7. Verify that the lease time is extended
-&Framed-IP-Address := reply.Framed-IP-Address
-&NAS-IP-Address := 127.0.0.2
+Framed-IP-Address := reply.Framed-IP-Address
+NAS-IP-Address := 127.0.0.2
 
 sqlippool.renew
 if (!updated) {
@@ -51,7 +51,7 @@ if (!updated) {
 }
 
 # 8. Check expiry reflects that
-&expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
+expiry := %sql("SELECT strftime('%%s', expiry_time) FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Name}' AND address = '%{reply.Framed-IP-Address}'")
 if ((expiry - %l) < 50) {
        test_fail
 }
@@ -67,7 +67,7 @@ if !(%sql("SELECT gateway FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Na
 }
 
 # Change the ip address to one that doesn't exist in the pool and check we *can't* update it
-&Framed-IP-Address := 192.168.3.1
+Framed-IP-Address := 192.168.3.1
 
 sqlippool.renew
 # 11.
@@ -81,12 +81,12 @@ if (%sql("SELECT address FROM fr_ippool WHERE pool_name = '%{control.IP-Pool.Nam
 }
 
 # re-issue the original allocation
-&reply := {}
-&Framed-IP-Address := 192.168.0.1
+reply := {}
+Framed-IP-Address := 192.168.0.1
 sqlippool.allocate
 
 # 13. Now change the calling station ID and check that we *can't* update the lease
-&Calling-Station-ID := 'naughty'
+Calling-Station-ID := 'naughty'
 
 sqlippool.renew
 if (!notfound) {
@@ -98,6 +98,6 @@ if !(reply.Framed-IP-Address == %sql("SELECT address FROM fr_ippool WHERE pool_n
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index e747d912f89eb0d9808165fda4f4999217cade2e..1953ea0225a63e67834d4ca3ff7db323573c4084 100644 (file)
@@ -1,7 +1,7 @@
 #
 #  Allocate an address from an SQL IP Pool and update
 #
-&control.IP-Pool.Name := 'test_update_alloc'
+control.IP-Pool.Name := 'test_update_alloc'
 
 #
 #  Add IP addresses
@@ -18,8 +18,8 @@ if (!updated) {
 #
 #  Attempt to update an IP address by performing a renew
 #
-&Framed-IP-Address := 192.168.0.1
-&NAS-IP-Address := 127.0.0.1
+Framed-IP-Address := 192.168.0.1
+NAS-IP-Address := 127.0.0.1
 
 sqlippool.renew
 
@@ -33,6 +33,6 @@ if !(reply.Framed-IP-Address == 192.168.0.1) {
        test_fail
 }
 
-&reply := {}
+reply := {}
 
 test_pass
index e1311f4d012638a3f546792edaf6fc2d8affd034..d4d522dd3fa8765e68fa52c0fcae2ada6749b58c 100644 (file)
@@ -1,4 +1,4 @@
-&Fall-Through := yes
+Fall-Through := yes
 
 # Should be compiled out
 if ('${a_term}' != '${a_term}') {
index 115a7a68978a8e0aeb9548da157cadab84897cec..aa0df8e4e424e2b33e7534389138fa6648dc4d8f 100644 (file)
@@ -1,6 +1,6 @@
 string otp
 
-&control.TOTP.Secret := 'ONSWG4TFOQYTEMZUGU3DOOBZ'
+control.TOTP.Secret := 'ONSWG4TFOQYTEMZUGU3DOOBZ'
 
 #
 #  With no OTP from the user, the module does nothing
@@ -15,7 +15,7 @@ if (!noop) {
 #
 #  Use oathtool to calculate OTP
 #
-&TOTP.From-User := %exec('/usr/bin/oathtool', '--base32', '--totp', 'ONSWG4TFOQYTEMZUGU3DOOBZ')
+TOTP.From-User := %exec('/usr/bin/oathtool', '--base32', '--totp', 'ONSWG4TFOQYTEMZUGU3DOOBZ')
 
 totp.authenticate
 
@@ -26,7 +26,7 @@ if (!ok) {
 #
 #  Now set an incorrect OTP and check for reject
 #
-&TOTP.From-User := 'ABCDEF'
+TOTP.From-User := 'ABCDEF'
 
 totp.authenticate {
        reject = 1
@@ -39,7 +39,7 @@ if !(reject) {
 #
 #  And an invalid length OTP
 #
-&TOTP.From-User := '12345'
+TOTP.From-User := '12345'
 
 totp.authenticate {
        fail = 1
index e34e5cc1248ee84511dd6d1afb691dc3c4f49fe0..076b59b731418a63163927b6a2dfb5568f3c5595 100644 (file)
@@ -2,32 +2,32 @@ ipaddr result_ipaddr
 string result_string
 
 #  Use builtin "local" zone
-&result_ipaddr := %dns('localhost', 'A')
+result_ipaddr := %dns('localhost', 'A')
 
 if (result_ipaddr != 127.0.0.1) {
        test_fail
 }
 
-&result_string := %dns('localhost', 'AAAA')
+result_string := %dns('localhost', 'AAAA')
 
 if (result_string != '::1') {
        test_fail
 }
 
-&result_string := %dns('1.0.0.127.in-addr.arpa', 'PTR')
+result_string := %dns('1.0.0.127.in-addr.arpa', 'PTR')
 
 if (result_string != 'localhost') {
        test_fail
 }
 
 #  Use local data in module config to allow for dotted names
-&result_ipaddr := %dns('www.example.com', 'A')
+result_ipaddr := %dns('www.example.com', 'A')
 
 if (result_ipaddr != 192.168.1.1) {
        test_fail
 }
 
-&result_string := %dns('1.1.168.192.in-addr.arpa', 'PTR')
+result_string := %dns('1.1.168.192.in-addr.arpa', 'PTR')
 
 if (result_string != 'www.example.com') {
        test_fail
@@ -42,14 +42,14 @@ if (result_string != 'www.example.com') {
 #}
 
 # Invalid query
-&result_string := %dns('www.example.com', 'ABC')
+result_string := %dns('www.example.com', 'ABC')
 
 if (Module-Failure-Message != "Invalid / unsupported DNS query type") {
        test_fail
 }
 
-&result_string := ''
-&result_string := %dns(%{result_string}, 'A')
+result_string := ''
+result_string := %dns(%{result_string}, 'A')
 
 if (Module-Failure-Message != "Can't resolve zero length host") {
        test_fail
@@ -57,7 +57,7 @@ if (Module-Failure-Message != "Can't resolve zero length host") {
 
 # Will return multiple records, though not in a defined sequence.
 # Each returned record is a pair of priority and host values.
-&Filter-Id := %dns(example.com, 'MX')
+Filter-Id := %dns(example.com, 'MX')
 
 if !(((Filter-Id[0] == '10') && (Filter-Id[1] == 'mail.example.com') && (Filter-Id[2] == '20') && (Filter-Id[3] == 'mail2.example.com')) || ((Filter-Id[2] == '10') && (Filter-Id[3] == 'mail.example.com') && (Filter-Id[0] == '20') && (Filter-Id[1] == 'mail2.example.com'))) {
        test_fail
@@ -65,13 +65,13 @@ if !(((Filter-Id[0] == '10') && (Filter-Id[1] == 'mail.example.com') && (Filter-
 
 # Just return a single record
 # As results are not in a specified order, it could be either.
-&Filter-Id := %dns(example.com,MX,1)
+Filter-Id := %dns(example.com,MX,1)
 
 if !(((Filter-Id[0] == '10') && (Filter-Id[1] == 'mail.example.com')) || ((Filter-Id[0] == '20') && (Filter-Id[1] == 'mail2.example.com'))) {
        test_fail
 }
 
-&result_string := %dns('n0nex1stent.d0ma1n', 'A')
+result_string := %dns('n0nex1stent.d0ma1n', 'A')
 
 # Running this on macOS produces a timeout due to the nonexistent TLD
 if ((Module-Failure-Message != "dns - Nonexistent domain name") && (Module-Failure-Message != "Timeout waiting for DNS resolution")) {
index 8197568f3921d10e9c878cff35bfae30fd14cac2..8f84cee167f70c1eb969998a8b9819b3eab85782 100644 (file)
@@ -11,8 +11,8 @@ if !(Vendor-Specific.Yubico.Yubikey-Public-Id == 'ddddgciilcjk') {
        test_fail
 }
 
-&control.Vendor-Specific.Yubico.Yubikey-Counter := 1
-&control.Vendor-Specific.Yubico.Yubikey-Key := 0xb8c56af07ff79b2230e04ab8891784ce
+control.Vendor-Specific.Yubico.Yubikey-Counter := 1
+control.Vendor-Specific.Yubico.Yubikey-Key := 0xb8c56af07ff79b2230e04ab8891784ce
 
 # Call module in authenticate mode to decrypt OTP
 yubikey.authenticate
@@ -33,7 +33,7 @@ if !(Vendor-Specific.Yubico.Yubikey-Random) {
 
 
 # Increase the known "counter" value to detect a replay attack
-&control.Vendor-Specific.Yubico.Yubikey-Counter := Vendor-Specific.Yubico.Yubikey-Counter
+control.Vendor-Specific.Yubico.Yubikey-Counter := Vendor-Specific.Yubico.Yubikey-Counter
 
 yubikey.authenticate {
        reject = 1
index 6080a0f4f44683d40cdc3415d2e823e32caa4875..ffd82e8224f1577bafae75bf6848f8fafd78473a 100644 (file)
@@ -1,17 +1,17 @@
 string test_string
 string result_string
 
-&test_string := 'vvrbuctetdhc'
-&result_string := %modhextohex(%{test_string})
+test_string := 'vvrbuctetdhc'
+result_string := %modhextohex(%{test_string})
 
 if (result_string != 'ffc1e0d3d260') {
        test_fail
 }
 
 #  Invalid modhex string - not even length
-&test_string := 'vvrbuctetdh'
+test_string := 'vvrbuctetdh'
 
-&result_string := %modhextohex(%{test_string})
+result_string := %modhextohex(%{test_string})
 
 if (ok) {
        test_fail
@@ -26,9 +26,9 @@ if (Module-Failure-Message != "Modhex string invalid") {
 }
 
 #  Invalid modhex string - invalid characters
-&test_string := 'vxrbmctetdhc'
+test_string := 'vxrbmctetdhc'
 
-&result_string := %modhextohex(%{test_string})
+result_string := %modhextohex(%{test_string})
 
 if (ok) {
        test_fail