[Bug 2464] Adding timestamp to debug messages (log.c:do_log)
Mark D. Baushke
mdb at juniper.net
Thu Oct 29 13:11:05 AEDT 2015
Stephen Harris <lists at spuddy.org> writes:
> On Wed, Oct 28, 2015 at 06:32:16PM -0700, Mark D. Baushke wrote:
> > and the format string "%Y%m%dT%H%M%SZ". I think gmtime() may be simpler.
> The world should live in GMT. Unfortunately people want their logs
> to be consitent on a machine; syslog reports in localtime so we should
> report in localtime :-(
I observed that the current patch was not a complete IS8601 timestamp as
it was missing the timezeone. If localtime() is used, then %z should be
added to the format which takes 21 charcters yyyymmddThhmmss-zzzz\0 or
yyyymmddThhmmss+zzzz\0 that is 20 printable characters and the NUL byte
to terminate the string.
More information about the openssh-unix-dev