Hi,<br><br>I'm trying to get similar logging in mysql to what you see with:<br><br>log {<br> ...<br> auth = yes<br> auth_badpass = yes<br> auth_goodpass = yes<br>}<br><br>"Login OK: [<user>/<pass>] (from client <client> port 0)"<br>
<br>I've found how to log accepts and rejects using the sql module in the post-auth section, but I'm unsure how to insert the client info (name or IP is fine).<br><br>Here's what I've tried:<br><br>sql/mysql/dialup.conf<br>
postauth_query = "INSERT INTO ${postauth_table} \<br> (username, pass, reply, authdate, nas_ip, nas_id) \<br> VALUES ( \<br> '%{User-Name}', \<br>
'%{%{User-Password}:-%{Chap-Password}}', \<br> '%{NAS-Identifier}', \<br> '%{reply:Packet-Type}', '%S', \<br> '%{NAS-IP-Address}')"<br>
<br>It doesn't appear that the "NAS-IP-Address" has any data at this point in the chain, the debug output shows this as the query run:<br><br>rlm_sql (sql) in sql_postauth: query is INSERT INTO radpostauth (username, pass, nas_id, reply, authdate, nas_ip) VALUES ( 'XXXXX', 'xxxx', 'YYYYY', 'Access-Accept', '2011-04-04 13:56:33', '')<br>
<br>Is there another variable I can use to get the client name/ip inserted into the db? Is this even possible in post-auth?<br><br>Thanks in advance,<br><br>-- <br>Trey Briggs<br>