+++ /dev/null
-#
-# Input packet
-#
-User-Name = "john"
-User-Password = "password"
-NAS-IP-Address = 1.2.3.5
-
-#
-# Expected answer
-#
-Response-Packet-Type == Access-Accept
-Idle-Timeout == 3600
-Session-Timeout == 7200
-Acct-Interim-Interval == 1800
-Framed-IP-Netmask == "255.255.0.0"
+++ /dev/null
-#
-# Run the "ldap" module
-#
-ldap
-
-if ("%{client:1.1.1.1.secret}" != "secret123") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:1.1.1.1.shortname}" != "client1") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:1.1.1.1.nas_type}" != "other") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:1.1.1.1.require_message_authenticator}" != "FALSE") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:1.1.1.1.proto}" != "udp") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:1.1.1.1.login}" != "foo") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:1.1.1.1.password}" != "bar") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:2.2.2.2.secret}" != "123secret") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:2.2.2.2.shortname}" != "client2") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:2.2.2.2.nas_type}" != "cisco") {
- test_fail
-}
-else {
- test_pass
-}
-
-if ("%{client:2.2.2.2.require_message_authenticator}" != "TRUE") {
- test_fail
-}
-else {
- test_pass
-}
attribute = 'radiusProfileDn'
}
- #
- # Bulk load clients from the directory
- #
- client {
- # Where to start searching in the tree for clients
- base_dn = "ou=clients,${..base_dn}"
-
- #
- # Filter to match client objects
- #
- filter = '(objectClass=radiusClient)'
-
- # Search scope, may be 'base', 'one', 'sub' or 'children'
-# scope = 'sub'
-
- #
- # Sets default values (not obtained from LDAP) for new client entries
- #
- template {
- login = 'foo'
- password = 'bar'
- proto = udp
- require_message_authenticator = yes
-
- # Uncomment to add a home_server with the same
- # attributes as the client.
-# coa_server {
-# response_window = 2.0
-# }
- }
-
- #
- # Client attribute mappings are in the format:
- # <client attribute> = <ldap attribute>
- #
- # The following attributes are required:
- # * ipaddr | ipv4addr | ipv6addr - Client IP Address.
- # * secret - RADIUS shared secret.
- #
- # All other attributes usually supported in a client
- # definition are also supported here.
- #
- # Schemas are available in doc/schemas/ldap for openldap and eDirectory
- #
- attribute {
- ipaddr = 'radiusClientIdentifier'
- secret = 'radiusClientSecret'
- shortname = 'radiusClientShortname'
- nas_type = 'radiusClientType'
- virtual_server = 'radiusClientVirtualServer'
- require_message_authenticator = 'radiusClientRequireMa'
- }
- }
-
- # Load clients on startup
- read_clients = yes
-
#
# Modify user object on receiving Accounting-Request
#