Hello everyone

I am still testing ippool-dhcp and after updating to the latest git HEAD I have come across a new issue. For some reason I am seeing the error "Unknown attribute" regarding the variable %{pool-key}. Here is a snippet of the debug log:

(0) ERROR: dhcp_sqlippool : database query error in: 'UPDATE radippool SET nasipaddress = 'this sql statement' WHERE nasipaddress = 'is not in use''
(0) ERROR: dhcp_sqlippool : SELECT framedipaddress FROM radippool WHERE pool_name = '%{control:Pool-Name}' AND expiry_time < current_timestamp AND rownum <= 1 ORDER BY CASEšššš WHEN pool_key = '%{pool-key}' THEN 0šššš ELSE 1 END, expiry_time FOR UPDATE
(0) ERROR: dhcp_sqlippool :šššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššš ^ Unknown attribute

In file mods-enabled/dhcp_sqlippool I have the following configuration:

ššššššš # Client's MAC address is mapped to Calling-Station-Id in policy.conf
ššššššš pool-key = "%{DHCP-Client-Hardware-Address}"

I would be grateful for any help in solving this. It was working before but I made the mistake of chnging my configuration and upgradingš FreeRADIUS at the same time so I am not sure where the problem lies. Here is the full debug output :-

root@xxxx:~# /usr/local/sbin/radiusd -X
radiusd: FreeRADIUS Version 3.0.0 (git #e6495d1), for host x86_64-unknown-linux-gnu, built on Junš 9 2013 at 13:41:15
Copyright (C) 1999-2013 The FreeRADIUS server project and contributors.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
You may redistribute copies of FreeRADIUS under the terms of the
GNU General Public License.
For more information about these matters, see the file named COPYRIGHT.
Starting - reading configuration files ...
including dictionary file /usr/local/etc/raddb/dictionary
including configuration file /usr/local/etc/raddb/radiusd.conf
including configuration file /usr/local/etc/raddb/proxy.conf
including configuration file /usr/local/etc/raddb/clients.conf
including files in directory /usr/local/etc/raddb/mods-enabled/
including configuration file /usr/local/etc/raddb/mods-enabled/attr_filter
including configuration file /usr/local/etc/raddb/mods-enabled/dhcp_sqlippool
including configuration file /usr/local/etc/raddb/sql/ippool-dhcp/oracle/queries.conf
including configuration file /usr/local/etc/raddb/mods-enabled/linelog
including configuration file /usr/local/etc/raddb/mods-enabled/sradutmp
including configuration file /usr/local/etc/raddb/mods-enabled/detail
including configuration file /usr/local/etc/raddb/mods-enabled/mschap
including configuration file /usr/local/etc/raddb/mods-enabled/expiration
including configuration file /usr/local/etc/raddb/mods-enabled/always
including configuration file /usr/local/etc/raddb/mods-enabled/passwd
including configuration file /usr/local/etc/raddb/mods-enabled/logintime
including configuration file /usr/local/etc/raddb/mods-enabled/pap
including configuration file /usr/local/etc/raddb/mods-enabled/ntlm_auth
including configuration file /usr/local/etc/raddb/mods-enabled/echo
including configuration file /usr/local/etc/raddb/mods-enabled/utf8
including configuration file /usr/local/etc/raddb/mods-enabled/files
including configuration file /usr/local/etc/raddb/mods-enabled/unix
including configuration file /usr/local/etc/raddb/mods-enabled/cache_eap
including configuration file /usr/local/etc/raddb/mods-enabled/chap
including configuration file /usr/local/etc/raddb/mods-enabled/realm
including configuration file /usr/local/etc/raddb/mods-enabled/replicate
including configuration file /usr/local/etc/raddb/mods-enabled/preprocess
including configuration file /usr/local/etc/raddb/mods-enabled/radutmp
including configuration file /usr/local/etc/raddb/mods-enabled/eap
including configuration file /usr/local/etc/raddb/mods-enabled/dynamic_clients
including configuration file /usr/local/etc/raddb/mods-enabled/soh
including configuration file /usr/local/etc/raddb/mods-enabled/expr
including configuration file /usr/local/etc/raddb/mods-enabled/detail.log
including configuration file /usr/local/etc/raddb/mods-enabled/dhcp
including configuration file /usr/local/etc/raddb/mods-enabled/sql
including configuration file /usr/local/etc/raddb/mods-enabled/../sql/main/oracle/queries.conf
including configuration file /usr/local/etc/raddb/mods-enabled/digest
including configuration file /usr/local/etc/raddb/mods-enabled/exec
including files in directory /usr/local/etc/raddb/policy.d/
including configuration file /usr/local/etc/raddb/policy.d/control
including configuration file /usr/local/etc/raddb/policy.d/cui
including configuration file /usr/local/etc/raddb/policy.d/accounting
including configuration file /usr/local/etc/raddb/policy.d/operator-name
including configuration file /usr/local/etc/raddb/policy.d/eap
including configuration file /usr/local/etc/raddb/policy.d/canonicalization
including configuration file /usr/local/etc/raddb/policy.d/dhcp
including configuration file /usr/local/etc/raddb/policy.d/filter
including files in directory /usr/local/etc/raddb/sites-enabled/
including configuration file /usr/local/etc/raddb/sites-enabled/dhcp
main {
šsecurity {
šššš allow_core_dumps = no
š}
}
main {
ššš name = "radiusd"
ššš prefix = "/usr/local"
ššš localstatedir = "/usr/local/var"
ššš sbindir = "/usr/local/sbin"
ššš logdir = "/usr/local/var/log/radius"
ššš run_dir = "/usr/local/var/run/radiusd"
ššš libdir = "/usr/local/lib"
ššš radacctdir = "/usr/local/var/log/radius/radacct"
ššš hostname_lookups = no
ššš max_request_time = 30
ššš cleanup_delay = 5
ššš max_requests = 1024
ššš pidfile = "/usr/local/var/run/radiusd/radiusd.pid"
ššš checkrad = "/usr/local/sbin/checkrad"
ššš debug_level = 0
ššš proxy_requests = yes
šlog {
šššš stripped_names = no
šššš auth = no
šššš auth_badpass = no
šššš auth_goodpass = no
šššš colourise = yes
š}
šsecurity {
šššš max_attributes = 200
šššš reject_delay = 1
šššš status_server = yes
š}
}
radiusd: #### Loading Realms and Home Servers ####
šproxy server {
šššš retry_delay = 5
šššš retry_count = 3
šššš default_fallback = no
šššš dead_time = 120
šššš wake_all_if_all_dead = no
š}
šhome_server localhost {
šššš ipaddr = 127.0.0.1
šššš port = 1812
šššš type = "auth"
šššš secret = "testing123"
šššš response_window = 20
šššš max_outstanding = 65536
šššš zombie_period = 40
šššš status_check = "status-server"
šššš ping_interval = 30
šššš check_interval = 30
šššš num_answers_to_alive = 3
šššš revive_interval = 120
šššš status_check_timeout = 4
š coa {
š ššš irt = 2
š ššš mrt = 16
š ššš mrc = 5
š ššš mrd = 30
š }
š limit {
š ššš max_connections = 16
š ššš max_requests = 0
š ššš lifetime = 0
š ššš idle_timeout = 0
š }
š}
šhome_server_pool my_auth_failover {
ššš type = fail-over
ššš home_server = localhost
š}
šrealm example.com {
ššš auth_pool = my_auth_failover
š}
šrealm LOCAL {
š}
radiusd: #### Loading Clients ####
šclient localhost {
šššš ipaddr = 127.0.0.1
šššš require_message_authenticator = no
šššš secret = "testing123"
šššš nastype = "other"
šššš proto = "*"
š limit {
š ššš max_connections = 16
š ššš lifetime = 0
š ššš idle_timeout = 30
š }
š}
radiusd: #### Instantiating modules ####
šinstantiate {
š}
šmodules {
š # Loaded module rlm_attr_filter
š # Instantiating module "attr_filter.post-proxy" from file /usr/local/etc/raddb/mods-enabled/attr_filter
š attr_filter attr_filter.post-proxy {
š ššš file = "/usr/local/etc/raddb/filter/post-proxy"
š ššš key = "%{Realm}"
š ššš relaxed = no
š }
reading pairlist file /usr/local/etc/raddb/filter/post-proxy
š # Instantiating module "attr_filter.pre-proxy" from file /usr/local/etc/raddb/mods-enabled/attr_filter
š attr_filter attr_filter.pre-proxy {
š ššš file = "/usr/local/etc/raddb/filter/pre-proxy"
š ššš key = "%{Realm}"
š ššš relaxed = no
š }
reading pairlist file /usr/local/etc/raddb/filter/pre-proxy
š # Instantiating module "attr_filter.access_reject" from file /usr/local/etc/raddb/mods-enabled/attr_filter
š attr_filter attr_filter.access_reject {
š ššš file = "/usr/local/etc/raddb/filter/access_reject"
š ššš key = "%{User-Name}"
š ššš relaxed = no
š }
reading pairlist file /usr/local/etc/raddb/filter/access_reject
š # Instantiating module "attr_filter.access_challenge" from file /usr/local/etc/raddb/mods-enabled/attr_filter
š attr_filter attr_filter.access_challenge {
š ššš file = "/usr/local/etc/raddb/filter/access_challenge"
š ššš key = "%{User-Name}"
š ššš relaxed = no
š }
reading pairlist file /usr/local/etc/raddb/filter/access_challenge
š # Instantiating module "attr_filter.accounting_response" from file /usr/local/etc/raddb/mods-enabled/attr_filter
š attr_filter attr_filter.accounting_response {
š ššš file = "/usr/local/etc/raddb/filter/accounting_response"
š ššš key = "%{User-Name}"
š ššš relaxed = no
š }
reading pairlist file /usr/local/etc/raddb/filter/accounting_response
š # Loaded module rlm_sqlippool
š # Instantiating module "dhcp_sqlippool" from file /usr/local/etc/raddb/mods-enabled/dhcp_sqlippool
š sqlippool dhcp_sqlippool {
š ššš sql-instance-name = "sql"
š ššš lease-duration = 7200
š ššš pool-name = ""
š ššš defaultpool = "main_pool"
š ššš allocate-begin = ""
š ššš allocate-clear = "UPDATE radippool SET nasipaddress = 'this sql statement' WHERE nasipaddress = 'is not in use'"
š ššš allocate-find = "SELECT framedipaddress FROM radippool WHERE pool_name = '%{control:Pool-Name}' AND expiry_time < current_timestamp AND rownum <= 1 ORDER BY CASEšššš WHEN pool_key = '%{pool-key}' THEN 0šššš ELSE 1 END, expiry_time FOR UPDATE"
š ššš allocate-update = "UPDATE radippoolš SET nasipaddress = '%{NAS-IP-Address}', pool_key = '%{DHCP-Client-Hardware-Address}',š callingstationid = '%{Calling-Station-Id}', username = '%{User-Name}',š expiry_time = current_timestamp + INTERVAL '7200' SECOND(1)š WHERE framedipaddress = '%I' AND pool_name = '%{control:Pool-Name}'"
š ššš allocate-commit = "COMMIT"
š ššš pool-check = "SELECT id FROM (SELECT id FROM radippoolš WHERE pool_name = '%{control:Pool-Name}') WHERE ROWNUM = 1"
š ššš start-begin = ""
š ššš start-update = "UPDATE radippoolš SET expiry_time = current_timestamp + INTERVAL '7200' SECOND(1)š WHERE nasipaddress = '%{NAS-IP-Address}' ANDš pool_key = '%{DHCP-Client-Hardware-Address}'š AND username = '%{User-Name}'š AND callingstationid = '%{Calling-Station-Id}'š AND framedipaddress = '%{Framed-IP-Address}'"
š ššš start-commit = "COMMIT"
š ššš alive-begin = ""
š ššš alive-update = "UPDATE radippoolš SET expiry_time = current_timestamp + INTERVAL '7200' SECOND(1)š WHERE nasipaddress = '%{Nas-IP-Address}' AND pool_key = '%{DHCP-Client-Hardware-Address}'š AND username = '%{User-Name}'š AND callingstationid = '%{Calling-Station-Id}'š AND framedipaddress = '%{Framed-IP-Address}'š AND pool_name = '%{control:Pool-Name}'"
š ššš alive-commit = "COMMIT"
š ššš stop-begin = ""
š ššš stop-clear = "UPDATE radippoolš SET nasipaddress = '', pool_key = '0', callingstationid = '', username = '',š expiry_time = current_timestamp - INTERVAL '1' second(1)š WHERE nasipaddress = '%{Nas-IP-Address}' AND pool_key = '%{DHCP-Client-Hardware-Address}'š AND username = '%{User-Name}'š AND callingstationid = '%{Calling-Station-Id}'š AND framedipaddress = '%{Framed-IP-Address}'"
š ššš stop-commit = "COMMIT"
š ššš on-begin = ""
š ššš on-clear = "UPDATE radippoolš SET nasipaddress = '', pool_key = '0', callingstationid = '', username = '',š expiry_time = current_timestamp - INTERVAL '1' second(1)š WHERE nasipaddress = '%{Nas-IP-Address}' AND pool_name = '%{control:Pool-Name}'"
š ššš on-commit = "COMMIT"
š ššš off-begin = ""
š ššš off-clear = "UPDATE radippoolš SET nasipaddress = '', pool_key = '0', callingstationid = '', username = '',š expiry_time = current_timestamp - INTERVAL '1' second(1)š WHERE nasipaddress = '%{Nas-IP-Address}' AND pool_name = '%{control:Pool-Name}'"
š ššš off-commit = "COMMIT"
šš messages {
šš }
š }
š # Loaded module rlm_sql
š # Instantiating module "sql" from file /usr/local/etc/raddb/mods-enabled/sql
š sql {
š ššš driver = "rlm_sql_oracle"
š ššš server = "localhost"
š ššš port = "1521"
š ššš login = "xxxxxx"
š ššš password = "xxxxxx"
š ššš radius_db = "(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SID=xxxxxx)))"
š ššš read_groups = yes
š ššš readclients = no
š ššš deletestalesessions = yes
š ššš sql_user_name = "%{User-Name}"
š ššš default_user_profile = ""
š ššš nas_query = "SELECT id, nasname, shortname, type, secret, server FROM nas"
š ššš authorize_check_query = "SELECT id,UserName,Attribute,Value,op FROM radcheck WHERE Username = '%{SQL-User-Name}' ORDER BY id"
š ššš authorize_reply_query = "SELECT id,UserName,Attribute,Value,op FROM radreply WHERE Username = '%{SQL-User-Name}' ORDER BY id"
š ššš authorize_group_check_query = "SELECT radgroupcheck.id,radgroupcheck.GroupName,radgroupcheck.Attribute,radgroupcheck.Value,radgroupcheck.opš FROM radgroupcheck,radusergroup WHERE radusergroup.Username = '%{SQL-User-Name}' AND radusergroup.GroupName = radgroupcheck.GroupName ORDER BY radgroupcheck.id"
š ššš authorize_group_reply_query = "SELECT radgroupreply.id,radgroupreply.GroupName,radgroupreply.Attribute,radgroupreply.Value,radgroupreply.opš FROM radgroupreply,radusergroup WHERE radusergroup.Username = '%{SQL-User-Name}' AND radusergroup.GroupName = radgroupreply.GroupName ORDER BY radgroupreply.id"
š ššš group_membership_query = "SELECT GroupName FROM radusergroup WHERE UserName='%{SQL-User-Name}'"
š ššš simul_count_query = ""
š ššš simul_verify_query = "SELECT RadAcctId, AcctSessionId, UserName, NASIPAddress, NASPortId, FramedIPAddress, CallingStationId, FramedProtocol FROM radacct WHERE UserName='%{SQL-User-Name}' AND AcctStopTime IS NULL"
š ššš safe-characters = "@abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789.-_: /"
š }
šš accounting {
šš ššš reference = "%{tolower:type.%{Acct-Status-Type}.query}"
šš }
šš post-auth {
šš ššš reference = ".query"
šš }
rlm_sql (sql): Driver rlm_sql_oracle (module rlm_sql_oracle) loaded and linked
rlm_sql (sql): Attempting to connect to database "(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521))(CONNECT_DATA=(SID=xxxxxx)))"
rlm_sql (sql): Initialising connection pool
šš pool {
šš ššš start = 2
šš ššš min = 1
šš ššš max = 2
šš ššš spare = 1
šš ššš uses = 0
šš ššš lifetime = 0
šš ššš cleanup_delay = 5
šš ššš idle_timeout = 60
šš ššš spread = no
šš }
rlm_sql (sql): Opening additional connection (0)
rlm_sql (sql): Opening additional connection (1)
š # Loaded module rlm_linelog
š # Instantiating module "linelog" from file /usr/local/etc/raddb/mods-enabled/linelog
š linelog {
š ššš filename = "/usr/local/var/log/radius/linelog"
š ššš permissions = 384
š ššš format = "This is a log message for %{User-Name}"
š ššš reference = "%{%{Packet-Type}:-format}"
š }
š # Loaded module rlm_radutmp
š # Instantiating module "sradutmp" from file /usr/local/etc/raddb/mods-enabled/sradutmp
š radutmp sradutmp {
š ššš filename = "/usr/local/var/log/radius/sradutmp"
š ššš username = "%{User-Name}"
š ššš case_sensitive = yes
š ššš check_with_nas = yes
š ššš perm = 420
š ššš callerid = no
š }
š # Loaded module rlm_detail
š # Instantiating module "detail" from file /usr/local/etc/raddb/mods-enabled/detail
š detail {
š ššš detailfile = "/usr/local/var/log/radius/radacct/%{%{Packet-Src-IP-Address}:-%{Packet-Src-IPv6-Address}}/detail-%Y%m%d"
š ššš header = "%t"
š ššš detailperm = 384
š ššš dirperm = 493
š ššš locking = no
š ššš log_packet_header = no
š }
š # Loaded module rlm_mschap
š # Instantiating module "mschap" from file /usr/local/etc/raddb/mods-enabled/mschap
š mschap {
š ššš use_mppe = yes
š ššš require_encryption = no
š ššš require_strong = no
š ššš with_ntdomain_hack = yes
šš passchange {
šš }
š ššš allow_retry = yes
š }
š # Loaded module rlm_expiration
š # Instantiating module "expiration" from file /usr/local/etc/raddb/mods-enabled/expiration
š expiration {
š ššš reply-message = "Password Has Expiredš "
š }
š # Loaded module rlm_always
š # Instantiating module "fail" from file /usr/local/etc/raddb/mods-enabled/always
š always fail {
š ššš rcode = "fail"
š ššš simulcount = 0
š ššš mpp = no
š }
š # Instantiating module "reject" from file /usr/local/etc/raddb/mods-enabled/always
š always reject {
š ššš rcode = "reject"
š ššš simulcount = 0
š ššš mpp = no
š }
š # Instantiating module "noop" from file /usr/local/etc/raddb/mods-enabled/always
š always noop {
š ššš rcode = "noop"
š ššš simulcount = 0
š ššš mpp = no
š }
š # Instantiating module "handled" from file /usr/local/etc/raddb/mods-enabled/always
š always handled {
š ššš rcode = "handled"
š ššš simulcount = 0
š ššš mpp = no
š }
š # Instantiating module "updated" from file /usr/local/etc/raddb/mods-enabled/always
š always updated {
š ššš rcode = "updated"
š ššš simulcount = 0
š ššš mpp = no
š }
š # Instantiating module "notfound" from file /usr/local/etc/raddb/mods-enabled/always
š always notfound {
š ššš rcode = "notfound"
š ššš simulcount = 0
š ššš mpp = no
š }
š # Instantiating module "ok" from file /usr/local/etc/raddb/mods-enabled/always
š always ok {
š ššš rcode = "ok"
š ššš simulcount = 0
š ššš mpp = no
š }
š # Loaded module rlm_passwd
š # Instantiating module "etc_passwd" from file /usr/local/etc/raddb/mods-enabled/passwd
š passwd etc_passwd {
š ššš filename = "/etc/passwd"
š ššš format = "*User-Name:Crypt-Password:"
š ššš delimiter = ":"
š ššš ignorenislike = no
š ššš ignoreempty = yes
š ššš allowmultiplekeys = no
š ššš hashsize = 100
š }
rlm_passwd: nfields: 3 keyfield 0(User-Name) listable: no
š # Loaded module rlm_logintime
š # Instantiating module "logintime" from file /usr/local/etc/raddb/mods-enabled/logintime
š logintime {
š ššš minimum-timeout = 60
š }
š # Loaded module rlm_pap
š # Instantiating module "pap" from file /usr/local/etc/raddb/mods-enabled/pap
š pap {
š ššš auto_header = no
š }
š # Loaded module rlm_exec
š # Instantiating module "ntlm_auth" from file /usr/local/etc/raddb/mods-enabled/ntlm_auth
š exec ntlm_auth {
š ššš wait = yes
š ššš program = "/path/to/ntlm_auth --request-nt-key --domain=MYDOMAIN --username=%{mschap:User-Name} --password=%{User-Password}"
š ššš input_pairs = "request"
š ššš shell_escape = yes
š }
š # Instantiating module "echo" from file /usr/local/etc/raddb/mods-enabled/echo
š exec echo {
š ššš wait = yes
š ššš program = "/bin/echo %{User-Name}"
š ššš input_pairs = "request"
š ššš output_pairs = "reply"
š ššš shell_escape = yes
š }
š # Loaded module rlm_utf8
š # Instantiating module "utf8" from file /usr/local/etc/raddb/mods-enabled/utf8
š # Loaded module rlm_files
š # Instantiating module "files" from file /usr/local/etc/raddb/mods-enabled/files
š files {
š ššš usersfile = "/usr/local/etc/raddb/users"
š ššš acctusersfile = "/usr/local/etc/raddb/acct_users"
š ššš preproxy_usersfile = "/usr/local/etc/raddb/preproxy_users"
š ššš compat = "no"
š }
reading pairlist file /usr/local/etc/raddb/users
reading pairlist file /usr/local/etc/raddb/acct_users
reading pairlist file /usr/local/etc/raddb/preproxy_users
š # Loaded module rlm_unix
š # Instantiating module "unix" from file /usr/local/etc/raddb/mods-enabled/unix
š unix {
š ššš radwtmp = "/usr/local/var/log/radius/radwtmp"
š }
š # Loaded module rlm_cache
š # Instantiating module "cache_eap" from file /usr/local/etc/raddb/mods-enabled/cache_eap
š cache cache_eap {
š ššš key = "%{%{control:State}:-%{%{reply:State}:-%{State}}}"
š ššš ttl = 15
š ššš max_entries = 16384
š ššš epoch = 0
š ššš add_stats = no
š }
š # Loaded module rlm_chap
š # Instantiating module "chap" from file /usr/local/etc/raddb/mods-enabled/chap
š # Loaded module rlm_realm
š # Instantiating module "IPASS" from file /usr/local/etc/raddb/mods-enabled/realm
š realm IPASS {
š ššš format = "prefix"
š ššš delimiter = "/"
š ššš ignore_default = no
š ššš ignore_null = no
š }
š # Instantiating module "suffix" from file /usr/local/etc/raddb/mods-enabled/realm
š realm suffix {
š ššš format = "suffix"
š ššš delimiter = "@"
š ššš ignore_default = no
š ššš ignore_null = no
š }
š # Instantiating module "realmpercent" from file /usr/local/etc/raddb/mods-enabled/realm
š realm realmpercent {
š ššš format = "suffix"
š ššš delimiter = "%"
š ššš ignore_default = no
š ššš ignore_null = no
š }
š # Instantiating module "ntdomain" from file /usr/local/etc/raddb/mods-enabled/realm
š realm ntdomain {
š ššš format = "prefix"
š ššš delimiter = "\"
š ššš ignore_default = no
š ššš ignore_null = no
š }
š # Loaded module rlm_replicate
š # Instantiating module "replicate" from file /usr/local/etc/raddb/mods-enabled/replicate
š # Loaded module rlm_preprocess
š # Instantiating module "preprocess" from file /usr/local/etc/raddb/mods-enabled/preprocess
š preprocess {
š ššš huntgroups = "/usr/local/etc/raddb/huntgroups"
š ššš hints = "/usr/local/etc/raddb/hints"
š ššš with_ascend_hack = no
š ššš ascend_channels_per_line = 23
š ššš with_ntdomain_hack = no
š ššš with_specialix_jetstream_hack = no
š ššš with_cisco_vsa_hack = no
š ššš with_alvarion_vsa_hack = no
š }
reading pairlist file /usr/local/etc/raddb/huntgroups
reading pairlist file /usr/local/etc/raddb/hints
š # Instantiating module "radutmp" from file /usr/local/etc/raddb/mods-enabled/radutmp
š radutmp {
š ššš filename = "/usr/local/var/log/radius/radutmp"
š ššš username = "%{User-Name}"
š ššš case_sensitive = yes
š ššš check_with_nas = yes
š ššš perm = 384
š ššš callerid = yes
š }
š # Loaded module rlm_eap
š # Instantiating module "eap" from file /usr/local/etc/raddb/mods-enabled/eap
š eap {
š ššš default_eap_type = "md5"
š ššš timer_expire = 60
š ššš ignore_unknown_eap_types = no
š ššš mod_accounting_username_bug = no
š ššš max_sessions = 4096
š }
šš # Linked to sub-module rlm_eap_md5
šš # Linked to sub-module rlm_eap_leap
šš # Linked to sub-module rlm_eap_gtc
šš gtc {
šš ššš challenge = "Password: "
šš ššš auth_type = "PAP"
šš }
šš # Linked to sub-module rlm_eap_tls
šš tls {
šš ššš tls = "tls-common"
šš }
šš tls-config tls-common {
šš ššš rsa_key_exchange = no
šš ššš dh_key_exchange = yes
šš ššš rsa_key_length = 512
šš ššš dh_key_length = 512
šš ššš verify_depth = 0
šš ššš CA_path = "/usr/local/etc/raddb/certs"
šš ššš pem_file_type = yes
šš ššš private_key_file = "/usr/local/etc/raddb/certs/server.pem"
šš ššš certificate_file = "/usr/local/etc/raddb/certs/server.pem"
šš ššš CA_file = "/usr/local/etc/raddb/certs/ca.pem"
šš ššš private_key_password = "whatever"
šš ššš dh_file = "/usr/local/etc/raddb/certs/dh"
šš ššš fragment_size = 1024
šš ššš include_length = yes
šš ššš check_crl = no
šš ššš cipher_list = "DEFAULT"
šš ššš make_cert_command = "/usr/local/etc/raddb/certs/bootstrap"
šš ššš ecdh_curve = "prime256v1"
ššš cache {
ššš ššš enable = yes
ššš ššš lifetime = 24
ššš ššš max_entries = 255
ššš }
ššš verify {
ššš }
ššš ocsp {
ššš ššš enable = no
ššš ššš override_cert_url = yes
ššš ššš url = "http://127.0.0.1/ocsp/"
ššš ššš use_nonce = yes
ššš ššš timeout = 0
ššš ššš softfail = yes
ššš }
šš }
šš # Linked to sub-module rlm_eap_ttls
šš ttls {
šš ššš tls = "tls-common"
šš ššš default_eap_type = "md5"
šš ššš copy_request_to_tunnel = no
šš ššš use_tunneled_reply = no
šš ššš virtual_server = "inner-tunnel"
šš ššš include_length = yes
šš ššš require_client_cert = no
šš }
Using cached TLS configuration from previous invocation
šš # Linked to sub-module rlm_eap_peap
šš peap {
šš ššš tls = "tls-common"
šš ššš default_method = "mschapv2"
šš ššš copy_request_to_tunnel = no
šš ššš use_tunneled_reply = no
šš ššš proxy_tunneled_request_as_eap = yes
šš ššš virtual_server = "inner-tunnel"
šš ššš soh = no
šš ššš require_client_cert = no
šš }
Using cached TLS configuration from previous invocation
šš # Linked to sub-module rlm_eap_mschapv2
šš mschapv2 {
šš ššš with_ntdomain_hack = no
šš ššš send_error = no
šš }
š # Loaded module rlm_dynamic_clients
š # Instantiating module "dynamic_clients" from file /usr/local/etc/raddb/mods-enabled/dynamic_clients
š # Loaded module rlm_soh
š # Instantiating module "soh" from file /usr/local/etc/raddb/mods-enabled/soh
š soh {
š ššš dhcp = yes
š }
š # Loaded module rlm_expr
š # Instantiating module "expr" from file /usr/local/etc/raddb/mods-enabled/expr
š expr {
š ššš safe-characters = "@abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789.-_: /"
š }
š # Instantiating module "auth_log" from file /usr/local/etc/raddb/mods-enabled/detail.log
š detail auth_log {
š ššš detailfile = "/usr/local/var/log/radius/radacct/%{%{Packet-Src-IP-Address}:-%{Packet-Src-IPv6-Address}}/auth-detail-%Y%m%d"
š ššš header = "%t"
š ššš detailperm = 384
š ššš dirperm = 493
š ššš locking = no
š ššš log_packet_header = no
š }
š # Instantiating module "reply_log" from file /usr/local/etc/raddb/mods-enabled/detail.log
š detail reply_log {
š ššš detailfile = "/usr/local/var/log/radius/radacct/%{%{Packet-Src-IP-Address}:-%{Packet-Src-IPv6-Address}}/reply-detail-%Y%m%d"
š ššš header = "%t"
š ššš detailperm = 384
š ššš dirperm = 493
š ššš locking = no
š ššš log_packet_header = no
š }
š # Instantiating module "pre_proxy_log" from file /usr/local/etc/raddb/mods-enabled/detail.log
š detail pre_proxy_log {
š ššš detailfile = "/usr/local/var/log/radius/radacct/%{%{Packet-Src-IP-Address}:-%{Packet-Src-IPv6-Address}}/pre-proxy-detail-%Y%m%d"
š ššš header = "%t"
š ššš detailperm = 384
š ššš dirperm = 493
š ššš locking = no
š ššš log_packet_header = no
š }
š # Instantiating module "post_proxy_log" from file /usr/local/etc/raddb/mods-enabled/detail.log
š detail post_proxy_log {
š ššš detailfile = "/usr/local/var/log/radius/radacct/%{%{Packet-Src-IP-Address}:-%{Packet-Src-IPv6-Address}}/post-proxy-detail-%Y%m%d"
š ššš header = "%t"
š ššš detailperm = 384
š ššš dirperm = 493
š ššš locking = no
š ššš log_packet_header = no
š }
š # Loaded module rlm_dhcp
š # Instantiating module "dhcp" from file /usr/local/etc/raddb/mods-enabled/dhcp
š # Loaded module rlm_digest
š # Instantiating module "digest" from file /usr/local/etc/raddb/mods-enabled/digest
š # Instantiating module "exec" from file /usr/local/etc/raddb/mods-enabled/exec
š exec {
š ššš wait = no
š ššš input_pairs = "request"
š ššš shell_escape = yes
š }
š} # modules
radiusd: #### Loading Virtual Servers ####
server { # from file /usr/local/etc/raddb/radiusd.conf
} # server
server dhcp { # from file /usr/local/etc/raddb/sites-enabled/dhcp
šModule: Checking dhcp DHCP-Discover {...} for more modules to load
š# Loading virtual module dhcp_sqlippool
šModule: Checking dhcp DHCP-Request {...} for more modules to load
š# Loading virtual module dhcp_sqlippool
šModule: Checking dhcp (null) {...} for more modules to load
/usr/local/etc/raddb/sites-enabled/dhcp[112]: No name specified for Post-Auth-Type block
} # server
radiusd: #### Opening IP addresses and Ports ####
listen {
š ššš type = "dhcp"
š ššš ipaddr = 127.0.0.1
š ššš port = 67
}
Listening on dhcp interface lo address 127.0.0.1 port 67 as server dhcp
Opening new proxy address * port 0
Listening on proxy address * port 52846
Ready to process requests.

Received DHCP-Request of id 3d6ab451 from 127.0.0.1:68 to 127.0.0.1:67
ššš DHCP-Opcode = Client-Message
ššš DHCP-Hardware-Type = Ethernet
ššš DHCP-Hardware-Address-Length = 6
ššš DHCP-Hop-Count = 0
ššš DHCP-Transaction-Id = 1030403153
ššš DHCP-Number-of-Seconds = 0
ššš DHCP-Flags = 0
ššš DHCP-Client-IP-Address = 127.0.0.1
ššš DHCP-Your-IP-Address = 0.0.0.0
ššš DHCP-Server-IP-Address = 0.0.0.0
ššš DHCP-Gateway-IP-Address = 0.0.0.0
ššš DHCP-Client-Hardware-Address = c0:ff:ee:c0:ff:ee
ššš DHCP-Message-Type += DHCP-Request
Trying sub-section dhcp DHCP-Request {...}
(0)šš group DHCP-Request {
(0)š - entering group DHCP-Request {...}
(0)šš update reply {
(0) ššš ššš DHCP-Message-Type = DHCP-Ack
(0)šš } # update reply = noop
(0)šš update reply {
(0) ššš ššš DHCP-Domain-Name-Server = 8.8.8.8
(0) ššš ššš DHCP-Domain-Name-Server = 8.8.4.4
(0) ššš ššš DHCP-Subnet-Mask = 255.255.255.0
(0) ššš ššš DHCP-Router-Address = 127.0.0.1
(0) ššš ššš DHCP-IP-Address-Lease-Time = 300
(0) ššš ššš DHCP-DHCP-Server-Identifier = 127.0.0.1
(0)šš } # update reply = noop
(0)šš update control {
(0) ššš ššš Pool-Name := "test_ip_pool"
(0)šš } # update control = noop
(0)ššš policy dhcp_sqlippool.post-auth {
(0)šš - entering policy dhcp_sqlippool.post-auth {...}
(0)ššš update request {
(0) ššš expand: 'DHCP-%{DHCP-Client-Hardware-Address}' -> 'DHCP-c0:ff:ee:c0:ff:ee'
(0) ššš ššš User-Name = "DHCP-c0:ff:ee:c0:ff:ee"
(0) ššš expand: '%{DHCP-Client-Hardware-Address}' -> 'c0:ff:ee:c0:ff:ee'
(0) ššš ššš Calling-Station-Id = "c0:ff:ee:c0:ff:ee"
(0) ššš expand: '%{%{DHCP-Gateway-IP-Address}:-127.0.0.1}' -> '0.0.0.0'
(0) ššš ššš NAS-IP-Address = 0.0.0.0
(0) ššš ššš Acct-Status-Type = Start
(0)ššš } # update request = noop
rlm_sql (sql): Reserved connection (1)
(0) dhcp_sqlippool : ššš expand: '%{User-Name}' -> 'DHCP-c0:ff:ee:c0:ff:ee'
(0) dhcp_sqlippool : SQL-User-Name updated
(0) dhcp_sqlippool : ššš expand: 'UPDATE radippool SET nasipaddress = 'this sql statement' WHERE nasipaddress = 'is not in use'' -> 'UPDATE radippool SET nasipaddress = 'this sql statement' WHERE nasipaddress = 'is not in use''
rlm_sql (sql): Executing query: 'UPDATE radippool SET nasipaddress = 'this sql statement' WHERE nasipaddress = 'is not in use''
(0) ERROR: dhcp_sqlippool : database query error in: 'UPDATE radippool SET nasipaddress = 'this sql statement' WHERE nasipaddress = 'is not in use''
(0) ERROR: dhcp_sqlippool : SELECT framedipaddress FROM radippool WHERE pool_name = '%{control:Pool-Name}' AND expiry_time < current_timestamp AND rownum <= 1 ORDER BY CASEšššš WHEN pool_key = '%{pool-key}' THEN 0šššš ELSE 1 END, expiry_time FOR UPDATE
(0) ERROR: dhcp_sqlippool :šššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššššš ^ Unknown attribute
(0) dhcp_sqlippool : ššš expand: 'COMMIT' -> 'COMMIT'
rlm_sql (sql): Executing query: 'COMMIT'
(0) ERROR: dhcp_sqlippool : database query error in: 'COMMIT'
(0) dhcp_sqlippool : ššš expand: 'SELECT id FROM (SELECT id FROM radippoolš WHERE pool_name = '%{control:Pool-Name}') WHERE ROWNUM = 1' -> 'SELECT id FROM (SELECT id FROM radippoolš WHERE pool_name = 'test_ip_pool') WHERE ROWNUM = 1'
rlm_sql (sql): Executing query: 'SELECT id FROM (SELECT id FROM radippoolš WHERE pool_name = 'test_ip_pool') WHERE ROWNUM = 1'
rlm_sql (sql): Released connection (1)
rlm_sql (sql): Closing connection (0): Too many free connections (2 > 1)
(0) dhcp_sqlippool : pool appears to be full
(0)ššš [dhcp_sqlippool] = notfound
(0)ššš ? if (ok)
(0)ššš ? if (ok)š -> FALSE
(0)šš - policy dhcp_sqlippool.post-auth returns notfound
(0)šš [ok] = ok
(0) DHCP: Reply will be sent unicast to client-ip-address
Sending DHCP-Ack of id 3d6ab451 to 127.0.0.1:68
(0) Finished request 0.
Waking up in 0.3 seconds.
Received DHCP-Release of id 3d6ab451 from 127.0.0.1:68 to 127.0.0.1:67
(0) Cleaning up request packet ID 1030403153 with timestamp +20
ššš DHCP-Opcode = Client-Message
ššš DHCP-Hardware-Type = Ethernet
ššš DHCP-Hardware-Address-Length = 6
ššš DHCP-Hop-Count = 0
ššš DHCP-Transaction-Id = 1030403153
ššš DHCP-Number-of-Seconds = 0
ššš DHCP-Flags = 0
ššš DHCP-Client-IP-Address = 127.0.0.1
ššš DHCP-Your-IP-Address = 0.0.0.0
ššš DHCP-Server-IP-Address = 0.0.0.0
ššš DHCP-Gateway-IP-Address = 0.0.0.0
ššš DHCP-Client-Hardware-Address = c0:ff:ee:c0:ff:ee
ššš DHCP-Message-Type += DHCP-Release
Trying sub-section dhcp DHCP-Release {...}
(1) WARNING: Unknown value specified for Post-Auth-Type.š Cannot perform requested action.
(1) Finished request 1.
Waking up in 0.3 seconds.
Waking up in 4.6 seconds.








2013/3/31 Alan DeKok <aland@deployingradius.com>
βΕΞ τΟΝΠΣΟΞ wrote:
> Firstly the ippool table for the oracle ippool schema contains various
> columns which are defined as NOT NULL:

š That is probably too strong a requirement.

> CREATE TABLE radippool (
> š š š š id INT PRIMARY KEY,
> š š š š pool_name VARCHAR(30) NOT NULL,
> š š š š framedipaddress VARCHAR(30) NOT NULL,
> š š š š nasipaddress VARCHAR(30) NOT NULL,
> š š š š pool_key INT NOT NULL,
> š š š š CalledStationId VARCHAR(64),
> š š š š CallingStationId VARCHAR(64) NOT NULL,
> š š š š expiry_time timestamp(0) NOT NULL,
> š š š š username VARCHAR(100)
> );
>
> The problem is that we also have insert and update staements which try
> to insert empty strings e.g. (taken from the standard ippol
> queries.conf):

š Yes. šThose queries try to clear the entries... i.e. set them to NULL.

> As I understand it, and empty string and NULL are the same thing in
> Oracle so this update statement will not work as is. I suppose we need
> to change the schema and this is what i have done for testing, but I
> want to understand why it is like this. I don't understand how the
> standard ippool queries.conf ever worked as it is trying to insert
> empty strings into NOT NULL columns.

š I think no one ever tested it on Oracle.

> I can create a new schema and send a patch, but I just wanted to
> double check that this is the right thing to do.

š It's the right thing to do.

š Alan DeKok.
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html