Help with "extending logging" ...
Hi, I am trying to parse accounting logs of cablelabs format. Some of the attributes are octet strings which in itself contain detailed information that is printed as a octet string by freeradius. e.g.: CableLabs-Event-Message = 0x484153482830783833326632306329 CableLabs-Related-Call-Billing-Crl-ID += 0x494b8dc32020202020202032302b3 0303030303000000040 CableLabs-Related-Call-Billing-Crl-ID += 0x494b8dc32020202020202032302b3 030303030300000003f Acct-Session-Id = "IK\215\303 20+000000\000\000\000?" ..... other avps' ... With help of members on this list, I have been able to write a perl module to parse these octet strings, but am not able to log them in proper place. I need to log all the standard attributes (typically logged in .../Client-IP-Addr/detail-<date> file) as well as these extra parsed attributes in one place. These are all in the accounting messages - need to achieve a consolidated log for accounting messages - does not matter in which file it is. How to achieve that? Do I need to make a code change - if so where? Do I need to make a change to the config files - if so which? Do I need to use a specific log mechanism in the perl module - if so what? Any other input/guidance to help achieve that? Thank You -a
Hi Folks, Trying to look at the problem in another way. I am inclined to think that I may have to write a module to "parse" the octet string and populate the attributes into the AVP list. Assuming that this is feasible, I would like to parse before the logging happens (via the "detail" module). To this end, wondering how to order the execution of modules - is this dictated via the order of entries in the accounting {} part of the radiusd.conf file? Any insight into the questions /issues below will also be very helpful. Thanks -a On Fri, Dec 19, 2008 at 7:18 AM, al pat <alps.oss@gmail.com> wrote:
Hi, I am trying to parse accounting logs of cablelabs format. Some of the attributes are octet strings which in itself contain detailed information that is printed as a octet string by freeradius.
e.g.:
CableLabs-Event-Message = 0x484153482830783833326632306329
CableLabs-Related-Call-Billing-Crl-ID += 0x494b8dc32020202020202032302b3
0303030303000000040
CableLabs-Related-Call-Billing-Crl-ID += 0x494b8dc32020202020202032302b3
030303030300000003f
Acct-Session-Id = "IK\215\303 20+000000\000\000\000?"
..... other avps' ...
With help of members on this list, I have been able to write a perl module to parse these octet strings, but am not able to log them in proper place.
I need to log all the standard attributes (typically logged in .../Client-IP-Addr/detail-<date> file) as well as these extra parsed attributes in one place. These are all in the accounting messages - need to achieve a consolidated log for accounting messages - does not matter in which file it is.
How to achieve that?
Do I need to make a code change - if so where? Do I need to make a change to the config files - if so which? Do I need to use a specific log mechanism in the perl module - if so what?
Any other input/guidance to help achieve that?
Thank You -a
I am inclined to think that I may have to write a module to "parse" the octet string and populate the attributes into the AVP list. Assuming that this is feasible, I would like to parse before the logging happens (via the "detail" module).
Run perl before detail. Put new attributes on the $RAD_REPLY list. Ivan Kalik Kalik Informatika ISP
Hmm, but RAD_REPLY is the list that goes back, no? I have perl before detail. -a On Fri, Dec 19, 2008 at 12:17 PM, <tnt@kalik.net> wrote:
I am inclined to think that I may have to write a module to "parse" the octet string and populate the attributes into the AVP list. Assuming that this is feasible, I would like to parse before the logging happens (via the "detail" module).
Run perl before detail. Put new attributes on the $RAD_REPLY list.
Ivan Kalik Kalik Informatika ISP
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
Yes, sorry $RAD_REQUEST. Accounting request is logged in detail. Ivan Kalik Kalik Informatika ISP Dana 19/12/2008, "al pat" <alps.oss@gmail.com> piše:
Hmm, but RAD_REPLY is the list that goes back, no? I have perl before detail.
-a
On Fri, Dec 19, 2008 at 12:17 PM, <tnt@kalik.net> wrote:
I am inclined to think that I may have to write a module to "parse" the octet string and populate the attributes into the AVP list. Assuming that this is feasible, I would like to parse before the logging happens (via the "detail" module).
Run perl before detail. Put new attributes on the $RAD_REPLY list.
Ivan Kalik Kalik Informatika ISP
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
participants (2)
-
al pat -
tnt@kalik.net