Acct-Status-Type = 7

Oscar Jofre oscar at jofre.com
Mon Apr 17 12:51:01 CEST 2017


Hi,

More info.

I've been trying for hours but can't find the differences between freeradius on my test environment where with empty user Accounting-on is responding and freeradius on production where Accounting-on with empty user is not responding.

PRODUCTION NOT RESPONDING:

(3126) Sun Apr 16 20:24:56 2017: Debug: sql: SQL query returned: success
(3126) Sun Apr 16 20:24:56 2017: Debug: sql: 0 record(s) updated
(3126) Sun Apr 16 20:24:56 2017: Debug: sql: No additional queries configured
(3126) Sun Apr 16 20:24:56 2017: Debug:     [sql] = noop
(3126) Sun Apr 16 20:24:56 2017: Debug:     [exec] = noop
(3126) Sun Apr 16 20:24:56 2017: Debug: attr_filter.accounting_response: EXPAND %{User-Name}
(3126) Sun Apr 16 20:24:56 2017: Debug: attr_filter.accounting_response:    -->
(3126) Sun Apr 16 20:24:56 2017: Debug:     [attr_filter.accounting_response] = noop
(3126) Sun Apr 16 20:24:56 2017: Debug:   } # accounting = noop
(3126) Sun Apr 16 20:24:56 2017: Debug: Not sending reply to client.
(3126) Sun Apr 16 20:24:56 2017: Debug: Finished request
(3126) Sun Apr 16 20:24:56 2017: Debug: Cleaning up request packet ID 7 with timestamp +804


TEST YES RESPONDING

(3) Sun Apr 16 21:46:27 2017: Debug: sql: SQL query returned: success
(3) Sun Apr 16 21:46:27 2017: Debug: sql: 0 record(s) updated
(3) Sun Apr 16 21:46:27 2017: Debug: sql: No additional queries configured
(3) Sun Apr 16 21:46:27 2017: Debug:     [sql] = noop
(3) Sun Apr 16 21:46:27 2017: Debug:     [exec] = noop
(3) Sun Apr 16 21:46:27 2017: Debug: attr_filter.accounting_response: EXPAND %{User-Name}
(3) Sun Apr 16 21:46:27 2017: Debug: attr_filter.accounting_response:    -->
(3) Sun Apr 16 21:46:27 2017: Debug:     [attr_filter.accounting_response] = noop
(3) Sun Apr 16 21:46:27 2017: Debug:   } # accounting = ok
(3) Sun Apr 16 21:46:27 2017: Debug: Sent Accounting-Response Id 13 from 172.17.1.21:1813 to 172.17.1.116:65068 length 0
(3) Sun Apr 16 21:46:27 2017: Debug: Finished request
(3) Sun Apr 16 21:46:27 2017: Debug: Cleaning up request packet ID 13 with timestamp +37


The only place I see something about response is on /sites-enabled/default

#
#  Accounting.  Log the accounting data.
#
accounting {
...
#	if (noop) {
#		ok
#	}
...
}


But both are commented ... where I can see the differences ?

Thanks !

-----Mensaje original-----
De: Freeradius-Users [mailto:freeradius-users-bounces+oscar=jofre.com at lists.freeradius.org] En nombre de Oscar Jofre
Enviado el: domingo, 16 de abril de 2017 20:42
Para: 'FreeRadius users mailing list'
Asunto: RE: Acct-Status-Type = 7 

Hi,

Now I think I Found the issue ...

If the Accounting ON comes with USER informed then radius sends response but if the USER is empty then the radius is not responding. I did check with NTRadPing with user (a) and radius response and with user empty () then radius not responding. 


WITH NO USER: Not sending reply to client

...
(3126) Sun Apr 16 20:24:56 2017: Debug: <running>:   Acct-Status-Type = Accounting-On
(3126) Sun Apr 16 20:24:56 2017: Debug: <running>:   NAS-Identifier = "SERVER"
(3126) Sun Apr 16 20:24:56 2017: Debug: <running>:   Acct-Delay-Time = 0
(3126) Sun Apr 16 20:24:56 2017: Debug: <running>:   NAS-IP-Address = yy.yy.yy.yy
(3126) Sun Apr 16 20:24:56 2017: Debug: <running>: # Executing section preacct from file /etc/raddb/sites-enabled/default
(3126) Sun Apr 16 20:24:56 2017: Debug: <running>:   preacct {

...

(3126) Sun Apr 16 20:24:56 2017: Debug: sql: SQL query returned: success
(3126) Sun Apr 16 20:24:56 2017: Debug: sql: 0 record(s) updated
(3126) Sun Apr 16 20:24:56 2017: Debug: sql: No additional queries configured
(3126) Sun Apr 16 20:24:56 2017: Debug:     [sql] = noop
(3126) Sun Apr 16 20:24:56 2017: Debug:     [exec] = noop
(3126) Sun Apr 16 20:24:56 2017: Debug: attr_filter.accounting_response: EXPAND %{User-Name}
(3126) Sun Apr 16 20:24:56 2017: Debug: attr_filter.accounting_response:    -->
(3126) Sun Apr 16 20:24:56 2017: Debug:     [attr_filter.accounting_response] = noop
(3126) Sun Apr 16 20:24:56 2017: Debug:   } # accounting = noop
(3126) Sun Apr 16 20:24:56 2017: Debug: Not sending reply to client.
(3126) Sun Apr 16 20:24:56 2017: Debug: Finished request
(3126) Sun Apr 16 20:24:56 2017: Debug: Cleaning up request packet ID 7 with timestamp +804

WITH USER (test): Sent Accounting-Response

....
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>: Received Accounting-Request Id 5 from 88.13.35.213:51954 to 91.229.58.125:1813 length 72
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>:   User-Name = " test "
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>:   Acct-Status-Type = Accounting-On
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>:   Acct-Session-Id = "3500"
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>:   NAS-IP-Address = yy.yy.yy.yy
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>:   Acct-Status-Type = Accounting-On
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>:   Acct-Delay-Time = 0
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>:   NAS-Identifier = "\"SERVER\""
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>: # Executing section preacct from file /etc/raddb/sites-enabled/default
(3138) Sun Apr 16 20:24:59 2017: Debug: <running>:   preacct {
....

(3138) Sun Apr 16 20:24:59 2017: Debug: sql: SQL query returned: success
(3138) Sun Apr 16 20:24:59 2017: Debug: sql: 0 record(s) updated
(3138) Sun Apr 16 20:24:59 2017: Debug: sql: No additional queries configured
(3138) Sun Apr 16 20:24:59 2017: Debug:     [sql] = noop
(3138) Sun Apr 16 20:24:59 2017: Debug:     [exec] = noop
(3138) Sun Apr 16 20:24:59 2017: Debug: attr_filter.accounting_response: EXPAND %{User-Name}
(3138) Sun Apr 16 20:24:59 2017: Debug: attr_filter.accounting_response:    --> test
(3138) Sun Apr 16 20:24:59 2017: Debug: attr_filter.accounting_response: Matched entry DEFAULT at line 12
(3138) Sun Apr 16 20:24:59 2017: Debug:     [attr_filter.accounting_response] = updated
(3138) Sun Apr 16 20:24:59 2017: Debug:   } # accounting = updated
(3138) Sun Apr 16 20:24:59 2017: Debug: Sent Accounting-Response Id 5 from xx.xx.xx.xx:1813 to yy.yy.yy.yy:51954 length 0

Is it correct that with no USER radius is not responding an Accounting-On ?

Can I change this ?

Thanks !



 

-----Mensaje original-----
De: Freeradius-Users [mailto:freeradius-users-bounces+oscar=jofre.com at lists.freeradius.org] En nombre de Alan DeKok Enviado el: domingo, 16 de abril de 2017 19:28
Para: FreeRadius users mailing list
Asunto: Re: Acct-Status-Type = 7 

On Apr 16, 2017, at 11:13 AM, Oscar Jofre <oscar at jofre.com> wrote:
> 
> 1) I do Installed freeradius on a virtual machine on my computer.
> 	I run it with -X and without and this server is always responding to the Accounting ON.

  Then the server is working correctly.

> 2) with my freeradius on Production is the same version of freeradius, same config files (except passwords) o got:
> 	Using NTRadPing - Getting Responds  Accounting on
> 	Usung Mikrotik - NO Responding Accounting on

  Then read the debug log from that request.

> I did tried to learn on test radius how works raddebug but I can't 
> filter requests. I'm trying to only see requests from a NAS or from a 
> specific IP but always I get echo information with raddebug

  What is "echo information" ?

  You can also run radsniff, which will show the contents of the packets from Mikrotik.  Then, take those attributes, and use then in radclient, to send packets to the server.  And run the server in debug mode to see what's going on.

  Alan DeKok.


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


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




More information about the Freeradius-Users mailing list