Hello Everyone, We are using freeradius for accounting purposes. When trying to add a new variable to the logs (e.g., NAS-PORT-TYPE) what is required to be modified on the client. We are using radiusclient-ng. In the default dictionary: ATTRIBUTE NAS-Port-Type 61 integer VALUE NAS-Port-Type Async 0 VALUE NAS-Port-Type Sync 1 VALUE NAS-Port-Type ISDN 2 VALUE NAS-Port-Type ISDN-V120 3 VALUE NAS-Port-Type ISDN-V110 4 However, NAS-Port-Type is not being included in the logs, Tue Apr 30 05:50:08 2013 Acct-Status-Type = Start Service-Type = SIP Sip-Response-Code = 200 Sip-Method = Invite Event-Timestamp = "Apr 30 2013 05:50:08 EDT" Sip-From-Tag = "3B7C575D-E798317A" Sip-To-Tag = "as183d6189" Acct-Session-Id = "b7c2af61-2d1b4daf-e558033c@192.168.2.11" User-Name = "1001@example.server.com" NAS-Port = 5060 Acct-Delay-Time = 0 NAS-IP-Address = 127.0.0.1 Acct-Unique-Session-Id = "f538381d8187adf7" Timestamp = 1367315408 Is NAS-PORT-TYPE not being included in the log because it's null? Please excuse the noob question. Kind Regards, Nick
Tue Apr 30 05:50:08 2013 Acct-Status-Type = Start Service-Type = SIP Sip-Response-Code = 200 Sip-Method = Invite Event-Timestamp = "Apr 30 2013 05:50:08 EDT" Sip-From-Tag = "3B7C575D-E798317A" Sip-To-Tag = "as183d6189" Acct-Session-Id = "b7c2af61-2d1b4daf-e558033c@192.168.2.11" User-Name = "1001@example.server.com" NAS-Port = 5060 Acct-Delay-Time = 0 NAS-IP-Address = 127.0.0.1 Acct-Unique-Session-Id = "f538381d8187adf7" Timestamp = 1367315408
Is NAS-PORT-TYPE not being included in the log because it's null?
It's probably not being included because it wasn't present in the Accounting-Request. Also It's an integer attribute, there is no 'NULL'. Arran Cudbard-Bell <a.cudbardb@freeradius.org> FreeRADIUS Development Team
Hello Arran, Thank you so much for your response. I have added the following to the SIP dictionary we are using: ATTRIBUTE NAS-Port-Type 61 integer Please excuse my learning process. Is this considered an accounting request? Cheers, Nick. On 4/30/13, Arran Cudbard-Bell <a.cudbardb@freeradius.org> wrote:
Tue Apr 30 05:50:08 2013 Acct-Status-Type = Start Service-Type = SIP Sip-Response-Code = 200 Sip-Method = Invite Event-Timestamp = "Apr 30 2013 05:50:08 EDT" Sip-From-Tag = "3B7C575D-E798317A" Sip-To-Tag = "as183d6189" Acct-Session-Id = "b7c2af61-2d1b4daf-e558033c@192.168.2.11" User-Name = "1001@example.server.com" NAS-Port = 5060 Acct-Delay-Time = 0 NAS-IP-Address = 127.0.0.1 Acct-Unique-Session-Id = "f538381d8187adf7" Timestamp = 1367315408
Is NAS-PORT-TYPE not being included in the log because it's null?
It's probably not being included because it wasn't present in the Accounting-Request. Also It's an integer attribute, there is no 'NULL'.
Arran Cudbard-Bell <a.cudbardb@freeradius.org> FreeRADIUS Development Team
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Nick Khamis wrote:
Hello Arran,
Thank you so much for your response. I have added the following to the SIP dictionary we are using:
ATTRIBUTE NAS-Port-Type 61 integer
Please excuse my learning process. Is this considered an accounting request?
No. A dictionary is just a dictionary. Like a normal dictionary. It defines something. It doesn't *do* anything. You'll have to modify the source code of the client in order to add NAS-Port-Type to accounting packets. Alan DeKok.
Hello Alan, Thanks so much for your response. I can provide a specific example. In the client we have defined: modparam("acc", "aaa_extra", " Sip-From-Tag=$si; Sip-To-Tag=$tt; ..... In the included dictionary.sip: ATTRIBUTE Sip-From-Tag 105 string ATTRIBUTE Sip-To-Tag 104 string Partial accounting start query: '%{Sip-From-Tag}', \ '%{Sip-To-Tag}', The values are not saved to the corresponding fields in the DB, however, they are included in the log file: Sip-From-Tag = "E94C56E1-DE9870DE" Sip-To-Tag = "as53e58d9c" Thanks in Advance, Nick. On 4/30/13, Alan DeKok <aland@deployingradius.com> wrote:
Nick Khamis wrote:
Hello Arran,
Thank you so much for your response. I have added the following to the SIP dictionary we are using:
ATTRIBUTE NAS-Port-Type 61 integer
Please excuse my learning process. Is this considered an accounting request?
No.
A dictionary is just a dictionary. Like a normal dictionary. It defines something. It doesn't *do* anything.
You'll have to modify the source code of the client in order to add NAS-Port-Type to accounting packets.
Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Nick Khamis wrote:
Thanks so much for your response. I can provide a specific example. In the client we have defined:
modparam("acc", "aaa_extra", " Sip-From-Tag=$si; Sip-To-Tag=$tt; .....
In the included dictionary.sip:
ATTRIBUTE Sip-From-Tag 105 string ATTRIBUTE Sip-To-Tag 104 string
Which is wrong, by the way. The SIP dictionary was *not* allocated through the standard methods. They just invented it.
Partial accounting start query:
'%{Sip-From-Tag}', \ '%{Sip-To-Tag}',
The values are not saved to the corresponding fields in the DB, however, they are included in the log file:
Sip-From-Tag = "E94C56E1-DE9870DE" Sip-To-Tag = "as53e58d9c"
Have you bothered to look at the debug output, as suggested in the FAQ, "man" page, web pages, and daily on this list? Are those SIP attributes even there? My guess is "No", because of the previous issue. Alan DeKok.
It seems that the sql module of freeraedius does not support calls to stored mysql procedures. Is this correct? PS Sorry for the noise. Cheers, Nick On 5/1/13, Alan DeKok <aland@deployingradius.com> wrote:
Nick Khamis wrote:
Thanks so much for your response. I can provide a specific example. In the client we have defined:
modparam("acc", "aaa_extra", " Sip-From-Tag=$si; Sip-To-Tag=$tt; .....
In the included dictionary.sip:
ATTRIBUTE Sip-From-Tag 105 string ATTRIBUTE Sip-To-Tag 104 string
Which is wrong, by the way. The SIP dictionary was *not* allocated through the standard methods. They just invented it.
Partial accounting start query:
'%{Sip-From-Tag}', \ '%{Sip-To-Tag}',
The values are not saved to the corresponding fields in the DB, however, they are included in the log file:
Sip-From-Tag = "E94C56E1-DE9870DE" Sip-To-Tag = "as53e58d9c"
Have you bothered to look at the debug output, as suggested in the FAQ, "man" page, web pages, and daily on this list? Are those SIP attributes even there?
My guess is "No", because of the previous issue.
Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
No calls to stored procedures do not work? Or no. that is not correct? Thanks in Advance, N. On 5/1/13, Alan DeKok <aland@deployingradius.com> wrote:
Nick Khamis wrote:
It seems that the sql module of freeraedius does not support calls to stored mysql procedures. Is this correct?
No.
Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Thank you guys so much for your time. Kind Regards, N. On 5/1/13, Alan DeKok <aland@deployingradius.com> wrote:
Nick Khamis wrote:
No calls to stored procedures do not work? Or no. that is not correct?
Q: Is this correct? A: No.
Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
I really did not mean any trouble. I realize that I am not only too in a hurry to read the proper documentation, but my questions also reflect how rushed I want to get this part over with. Regardless of my last comment, I realized that I should take a step back, go through the documentation, and put this part together correctly. Thank you so much for your help, even though I did not even take the time to ask a proper question. Kind Regards, Nick. On 5/1/13, Alan DeKok <aland@deployingradius.com> wrote:
Nick Khamis wrote:
Thank you guys so much for your time.
If you care to look, good questions get good answers.
Bad questions get bad answers.
People who ask questions and ignore the answers get ignored in turn.
Alan DeKok. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
participants (3)
-
Alan DeKok -
Arran Cudbard-Bell -
Nick Khamis