Bug 189878 - newsyslog(8) confused by some timezones (apparently)
Summary: newsyslog(8) confused by some timezones (apparently)
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: 9.1-RELEASE
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-17 01:50 UTC by Kurt Lidl
Modified: 2017-12-31 22:23 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Kurt Lidl freebsd_committer freebsd_triage 2014-05-17 01:50:00 UTC
The time parsing routines in use by the newsyslog program are apparently not terribly robust.
On many timezones, they fail to parse the "when" field of the newsyslog.conf if it
contains a valid with a leading asterisk.  e.g. "@T00" - both given as an example in
the manpage, as well as in the distributed /etc/newsyslog.conf file.

The behavior is reproducable on 9.1-RELEASE, stable/9, stable/10 and "head" as of
today (May 16, 2014).

How-To-Repeat: TZ=UTC newsyslog -s -C -n -r

Notice that output is generated.

TZ=EST5DT newsyslog -s -C -n -r

Notice that no output is generated.

Under a system running stable/9.2-ish, I get output like this in the failing case:
# TZ=EST5EDT newsyslog -s -C -n -r
newsyslog: malformed 'at' value:
/var/log/maillog                        640  7     *    @T00  C

(it dies at whatever the first line with an "@...." in the when field.)
Comment 1 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:01:16 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped