sql { driver = "rlm_sql_mysql" server = "localhost" login = "xxxxxx" password = "xxxxxx" radius_db = "xxxxxx" acct_table = "radacct" acct_table1 = "radacct" acct_table2 = "radacct" authcheck_table = "radcheck" authreply_table = "radreply" groupreply_table = "radgroupreply" usergroup_table = "radusergroup" groupcheck_table = "radgroupcheck" postauth_table = "radpostauth" nas_table = "nas" sqltrace = no sqltracefile = ${logdir}/sqltrace-%Y%m%d.log num_sql_socks = 25 connect_failure_retry_delay = 60 accounting_start_query = "\ CALL insert_radacct_record( \ 'radius', \ '%{Acct-Session-Id}', \ '%{Acct-Unique-Session-Id}', \ '%{Billing-Party}', \ '%{Billing-Party}', \ '%{SIP-Proxy-IP}', \ '%{NAS-Port}', \ '%S', \ '0', \ '0', \ '0', \ '0', \ '%{Called-Station-Id}', \ '%{Calling-Station-Id}', \ '%{Sip-Response-Code}', \ '%{Service-Type}', \ '%{ENUM-TLD}', \ '%{Framed-IP-Address}', \ '%{Acct-Delay-Time}', \ '0', \ '%{Sip-Response-Code}', \ '%{Sip-Method}', \ '%{Sip-Translated-Request-URI}', \ '%{Sip-To-Tag}', \ '%{Sip-From-Tag}', \ '%{Sip-RPId}', \ '%{Source-IP}', \ '%{Source-Port}', \ '%{Canonical-URI}', \ '', \ '', \ '%{Sip-Application-Type}', \ '%{User-Agent}', \ '%{From-Header}' \ )" accounting_stop_query = "\ CALL update_radacct_record( \ 'radius', \ '%S', \ '%{Acct-Delay-Time}', \ '%{Connect-Info}', \ '%{X-RTP-Stat}', \ '%{Acct-Session-Id}', \ '%{Sip-To-Tag}', \ '%{Sip-From-Tag}' \ )" accounting_update_query = "\ CALL update_raddact_record_mediaproxy( \ 'radius', \ '%{Acct-Session-Time}', \ '%{Acct-Input-Octets}', \ '%{Acct-Output-Octets}', \ '%{Sip-User-Agents}', \ '%{Media-Codecs}', \ '%{Sip-Application-Type}', \ '%{Media-Info}', \ '0', \ '%{Acct-Session-Id}', \ '%{Sip-To-Tag}', \ '%{Sip-From-Tag}' \ )" accounting_failed_query = "\ CALL insert_radacct_record( \ 'radius', \ '%{Acct-Session-Id}', \ '%{Acct-Unique-Session-Id}', \ '%{Billing-Party}', \ '%{Billing-Party}', \ '%{SIP-Proxy-IP}', \ '%{NAS-Port}', \ '%S', \ '%S', \ '0', \ '0', \ '0', \ '%{Called-Station-Id}', \ '%{Calling-Station-Id}', \ '%{Sip-Response-Code}', \ '%{Service-Type}', \ '%{ENUM-TLD}', \ '%{Framed-IP-Address}', \ '%{Acct-Delay-Time}', \ '0', \ '%{Sip-Response-Code}', \ '%{Sip-Method}', \ '%{Sip-Translated-Request-URI}', \ MD5(RAND()), \ '%{Sip-From-Tag}', \ '%{Sip-RPId}', \ '%{Source-IP}', \ '%{Source-Port}', \ '%{Canonical-URI}', \ '', \ '', \ '%{Sip-Application-Type}', \ '%{User-Agent}', \ '%{From-Header}' \ )" $INCLUDE /etc/freeradius/sql/mysql/dialup.conf }