[RADIATOR] Accessing Timestamp in Postauthhook during Access-Request
Hugh Irvine
hugh at open.com.au
Fri Feb 19 15:28:17 CST 2010
Hello Heikki, Hello Chris -
Heikki is correct - the "Timestamp" is only available in accounting requests.
This is because accounting requests can contain an "Acct-Delay-Time" in case of retransmissions, and Radiator automatically corrects the Timestamp to the time the event occured - ie. current time minus Acct-Delay-Time. There is no equivalent for access requests because you aren't doing billing on access requests.
This is why my response also suggested looking at the other special characters in section 5.2 of the manual ("doc/ref.pdf").
regards
Hugh
On 20 Feb 2010, at 06:47, Heikki Vatiainen wrote:
> On 02/19/2010 08:58 PM, Chris Bland wrote:
>
>> Still now sure what's not working. I tried you solution in a file by
>> itself and this is what showed up in the logs
>
> I am not Hugh, but took look at this too :)
>
>> Fri Feb 19 11:37:25 2010: DEBUG: AuthBy LDAP2 result: ACCEPT,
>> Fri Feb 19 11:37:25 2010: DEBUG: Timestamp is
>> Fri Feb 19 11:37:25 2010: DEBUG: Access accepted for chris at fdu.edu
>>
>> I forgot to mention in my original post that I am able to get the
>> Timestamp during other requests just not in the Access-Request.
>
> I think Timestamp is only available in Accounting-Request packets.
>
> If you check the manual for version 4.5.1, section 5.29.16
> "AcctColumnDef", there is discussion about the Timestamp attribute and
> how it is added by Radiator to received Accounting-Requests.
>
> The log snippet you included shows that the attribute is not in
> Access-Request and since it is not added by Radiator, I think that
> explains why you can not see it.
>
> If the need is only to log the timestamp of request arrival, maybe %B or
> the other time related specifiers would do. For example, %B does not
> depend on the request contents, but is the result of strftime(time()) call.
>
> --
> Heikki Vatiainen, Arch Red Oy
> +358 44 087 6547
> _______________________________________________
> radiator mailing list
> radiator at open.com.au
> http://www.open.com.au/mailman/listinfo/radiator
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.
Includes support for reliable RADIUS transport (RadSec),
and DIAMETER translation agent.
-
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.
More information about the radiator
mailing list