rediswho and date timestamps

Alan DeKok aland at deployingradius.com
Wed May 15 21:29:50 CEST 2019


On May 15, 2019, at 2:38 PM, Mike Lopes <mlopes at teksavvy.ca> wrote:
> 
> I'm in the process of updating our radius servers from 3.0.3 to 3.0.18 and I can't seem to get the unix timestamps into redis the way it is currently done.
> 
> Currently my configuration is like this:
> 
> start-insert = "LPUSH logs|%{User-Name} %{Event-Timestamp#}, ...

  I'm not sure that was ever intended to work.

> On the new servers I'm building,

  OK...

> Seems like that changed in the current version freeradius.  I've been over the documentation and read the configuration files to no avail.

  What changed?  What's going wrong?

> I have tried to use date module, I have tried to use %S and %T from reading a few threads on this list but it keeps failing to convert into unix time..
> 
> I've tried this in the preacct section:
> 
> update request {
>                        &Event-Timestamp := "%{date:%{Event-Timestamp}}"
>                }
> 
> Can someone point me to the # equivalent to get conversion to unix time?

  %l is unix time.

  You can use %{integer:Event-Timestamp} to get a "date" attribute converted to an integer.

  For more information, see https://wiki.freeradius.org/config/Xlat

  Alan DeKok.




More information about the Freeradius-Users mailing list