Having a consistent Event-Timestamp format
Arran Cudbard-Bell
a.cudbardb at freeradius.org
Thu Oct 13 16:05:34 CEST 2016
> On Oct 13, 2016, at 6:49 AM, Herwin Weststrate <herwin at quarantainenet.nl> wrote:
>
> On 13-10-16 12:37, Anuruddha Premalal wrote:
>> Hi All,
>>
>> I'm using the 'Event-Timestamp' in the python module it's printed as
>> follows.
>>
>> *Oct 12 2016 13:59:27 UTC*
>>
>> However the timestamp format present in the MySQL databse is *2006-01-02
>> 15:04:00*
>>
>> Is it possible to enforce the same format as MySQL across the board?, I
>> wasn't able to locate related documentation on this.
>
> Normalizing to MySQL sounds pretty unusual, I'd normalize it to ISO8601.
>
> But I think the Python-module has a different problem here: the
> Event-Timestamp attribute is marked in the dictionary as type date.
> Python has a datetime class. Wouldn't it be better to pass a datetime
> object to the Python script instead of a stringified version of the date?
I started converting some stuff to proper Python types in v3.1.x/v4.0.x, but the default type is string for most dictionary types.
-Arran
Arran Cudbard-Bell <a.cudbardb at freeradius.org>
FreeRADIUS Development Team
FD31 3077 42EC 7FCD 32FE 5EE2 56CF 27F9 30A8 CAA2
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.freeradius.org/pipermail/freeradius-users/attachments/20161013/01615713/attachment-0001.sig>
More information about the Freeradius-Users
mailing list