(RADIATOR) Conditional log format

Hugh Irvine hugh at open.com.au
Mon Apr 24 23:51:31 CDT 2006


Hello Claudio -

I think you will either need to use a hook, or write a little script  
to post-process the standard accounting file.

regards

Hugh


On 25 Apr 2006, at 10:06, Claudio Lapidus wrote:

> Hello
>
> We're setting up an accounting file format for an external application
> that handles Livingston files. Unfortunately, the Livingston flavor
> produced by Radiator is not suitable and we must artificially recreate
> the format. We have the following in the config file:
>
> AcctLogFileFormat	%q, %d %v %Y %H:%M:%S%r	\
> 			User-Name = %{User-Name}%r	\
> 			NAS-Port-Type = %{NAS-Port-Type}%r	\
> 			NAS-Port = %{NAS-Port}%r	\
> 			NAS-IP-Address = %{NAS-IP-Address}%r	\
> 			Framed-IP-Address = %{Framed-IP-Address}%r	\
> 			Acct-Status-Type = %{Acct-Status-Type}%r	\
> 			Acct-Session-Id = %{Acct-Session-Id}%r	\
> 			Acct-Session-Time = %{Acct-Session-Time}%r	\
> 			Acct-Delay-Time = %{Acct-Delay-Time}%r	\
> 			Acct-Terminate-Cause = %{Acct-Terminate-Cause}%r	\
> 			Acct-Input-Octets = %{Acct-Input-Octets}%r	\
> 			Acct-Output-Octets = %{Acct-Output-Octets}%r	\
> 			Acct-Input-Packets = %{Acct-Input-Packets}%r	\
> 			Acct-Input-Packets = %{Acct-Output-Packets}%r 	\
> 			Acct-Output-Gigawords = %{Acct-Input-Gigawords}%r	\
> 			Acct-Output-Gigawords = %{Acct-Output-Gigawords}%r%r
>
> which, given the command:
>
> radpwtst -noauth -nostart
>
> gives the following result in the detail file:
>
> Mon, 24 Apr 2006 20:54:32
>         User-Name = mikem
>         NAS-Port-Type = Async
>         NAS-Port = 1234
>         NAS-IP-Address = 203.63.154.1
>         Framed-IP-Address =
>         Acct-Status-Type = Stop
>         Acct-Session-Id = 00001234
>         Acct-Session-Time = 1000
>         Acct-Delay-Time = 0
>         Acct-Terminate-Cause =
>         Acct-Input-Octets = 20000
>         Acct-Output-Octets = 30000
>         Acct-Input-Packets =
>         Acct-Input-Packets =
>         Acct-Output-Gigawords =
>         Acct-Output-Gigawords =
>
> Now, we need a way to include the reference to a certain attribute
> only if it is actually present in the packet, so as to avoid those
> "blank value" lines. Is there a way to specify this from the config
> file?
>
> thanks in advance
> cl.
>
> --
> Archive at http://www.open.com.au/archives/radiator/
> Announcements on radiator-announce at open.com.au
> To unsubscribe, email 'majordomo at open.com.au' with
> 'unsubscribe radiator' in the body of the message.


NB:

Have you read the reference manual ("doc/ref.html")?
Have you searched the mailing list archive (www.open.com.au/archives/ 
radiator)?
Have you had a quick look on Google (www.google.com)?
Have you included a copy of your configuration file (no secrets),
together with a trace 4 debug showing what is happening?

-- 
Radiator: the most portable, flexible and configurable RADIUS server
anywhere. Available on *NIX, *BSD, Windows, MacOS X.
-
Nets: internetwork inventory and management - graphical, extensible,
flexible with hardware, software, platform and database independence.
-
CATool: Private Certificate Authority for Unix and Unix-like systems.


--
Archive at http://www.open.com.au/archives/radiator/
Announcements on radiator-announce at open.com.au
To unsubscribe, email 'majordomo at open.com.au' with
'unsubscribe radiator' in the body of the message.


More information about the radiator mailing list