concept: datetime
See https://github.com/privacyidea/privacyidea/issues/644
In certain cases like the validity start time and validity endtime the user enters dates and times and privacyIDEA stores these datetimes. Problems arise, if the user and the privacyIDEA system are located in different timezones.
The help desk user could be located in Ireland, the server could be located in U.S.A. and the token owner could be located in Australia.
It is difficult to decide, what to display to the help desk user. The idea is to keep things simple by keeping things transparent without any hidden logic.
Times should be enteres and stored according to ISO8601. In certain cases this might be inconvenient, since the helpdesk user would like to enter a local time, but it is transparent.
Thus privacyIDEA will store the time as '2017-04-26T10:30+0400'
. As the time is stored in the tokeninfo table, this is stored as a string!
The user/helpdesk user can enter the following values and privacyIDEA will expand these accordingly:
- 2017-04-26T10:30+0200 -> 2017-04-26T10:30+0200
- 2017-04-26T10:30 -> 2017-04-26T10:30+0000
- 2017-04-26 -> 2017-04-26T12:00+0000
The web UI / REST docu will get a note about the accepted formats.
If no time is given, the decision to expand to which time is not an easy one. It might make sense to expand to different times depending on whether it is a starttime or an endtime. But this again could be not very transparent. THis is why we have the idea to expand to 12:00+0000.