Bug#762465: sudo: ignoring time stamp from the future message after each boot
Control: tags 1 + patch The culprit is that get_boottime() fails to parse /proc/stat correctly. It passes a string ending with \n to strtonum(), and that fails. The attached patch fixes the bug. -- Jakub Wilk --- a/plugins/sudoers/boottime.c +++ b/plugins/sudoers/boottime.c @@ -80,6 +80,8 @@ if (fp != NULL) { while ((len = getline(line, linesize, fp)) != -1) { if (strncmp(line, btime , 6) == 0) { + if (line[len - 1] == '\n') + line[len - 1] = '\0'; long long llval = strtonum(line + 6, 1, LLONG_MAX, NULL); if (llval 0) { tv-tv_sec = (time_t)llval;
Bug#762465: sudo: ignoring time stamp from the future message after each boot
Package: sudo Version: 1.8.10p3-1 Followup-For: Bug #762465 This still exists, both on my amd64 laptop and x32 desktop (which I only rebooted just now so I did not notice it earlier) and is highly annoying. -- System Information: Debian Release: jessie/sid APT prefers unreleased APT policy: (500, 'unreleased'), (500, 'buildd-unstable'), (500, 'unstable') Architecture: x32 (x86_64) Foreign Architectures: i386 Kernel: Linux 3.16-2-amd64 (SMP w/4 CPU cores) Locale: LANG=C, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/lksh Versions of packages sudo depends on: ii libaudit1 1:2.4-1 ii libc6 2.19-11 ii libpam-modules 1.1.8-3.1 ii libpam0g1.1.8-3.1 ii libselinux1 2.3-2 sudo recommends no packages. sudo suggests no packages. -- Configuration Files: /etc/sudoers [Errno 13] Permission denied: u'/etc/sudoers' /etc/sudoers.d/README [Errno 13] Permission denied: u'/etc/sudoers.d/README' -- no debconf information -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Bug#762465: sudo: ignoring time stamp from the future message after each boot
On Mon, Sep 22, 2014 at 05:53:19PM +0200, Sven Joachim wrote: Since the upgrade to 1.8.10p3-1, I get an ignoring time stamp from the future warning whenever I first run sudo after a reboot. This is highly annoying since sudo also sends me a mail with that warning. I can confirm this behavior on two different systems. -- brian m. carlson / brian with sandals: Houston, Texas, US +1 832 623 2791 | http://www.crustytoothpaste.net/~bmc | My opinion only OpenPGP: RSA v4 4096b: 88AC E9B2 9196 305B A994 7552 F1BA 225C 0223 B187 signature.asc Description: Digital signature
Bug#762465: sudo: ignoring time stamp from the future message after each boot
Package: sudo Version: 1.8.10p3-1 Severity: normal Since the upgrade to 1.8.10p3-1, I get an ignoring time stamp from the future warning whenever I first run sudo after a reboot. This is highly annoying since sudo also sends me a mail with that warning. The timestamps under /var/lib/sudo look perfectly fine: , | $ LANG=C sudo ls -lR /var/lib/sudo | /var/lib/sudo/: | total 12 | drwx-- 2 root sven 4096 Jan 1 1970 lectured | drwx-- 2 root sven 4096 Jan 1 1970 sven | drwx-- 2 root sven 4096 Jan 1 1970 ts | | /var/lib/sudo/lectured: | total 0 | -rw--- 1 root sven 0 Jan 1 1970 sven | | /var/lib/sudo/sven: | total 8 | -rw--- 1 root sven 28 Jan 1 1970 0 | -rw--- 1 root sven 28 Jan 1 1970 tty1 | | /var/lib/sudo/ts: | total 4 | -rw--- 1 root sven 32 Sep 22 17:47 sven ` I also logged in as root after a fresh boot and could not find any timestamps from the future either, although I'm a bit surprised that /var/lib/sudo/ts/sven does not have the timestamp of the epoch but rather that of sudo's last invocation. -- System Information: Debian Release: jessie/sid APT prefers unstable APT policy: (500, 'unstable'), (101, 'experimental') Architecture: i386 (x86_64) Kernel: Linux 3.16.3-nouveau (SMP w/2 CPU cores) Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages sudo depends on: ii libaudit1 1:2.4-1 ii libc6 2.19-11 ii libpam-modules 1.1.8-3.1 ii libpam0g1.1.8-3.1 ii libselinux1 2.3-2 sudo recommends no packages. sudo suggests no packages. -- Configuration Files: /etc/sudoers [Errno 13] Keine Berechtigung: u'/etc/sudoers' /etc/sudoers.d/README [Errno 13] Keine Berechtigung: u'/etc/sudoers.d/README' -- no debconf information -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org