GNU bug report logs - #21918
'visudo' non-deterministic (sudo 1.8.15)

Previous Next

Package: guix;

Reported by: ludo <at> gnu.org (Ludovic Courtès)

Date: Sat, 14 Nov 2015 15:46:02 UTC

Severity: normal

Done: Leo Famulari <leo <at> famulari.name>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 21918 in the body.
You can then email your comments to 21918 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#21918; Package guix. (Sat, 14 Nov 2015 15:46:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to ludo <at> gnu.org (Ludovic Courtès):
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Sat, 14 Nov 2015 15:46:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: ludo <at> gnu.org (Ludovic Courtès)
To: bug-guix <at> gnu.org
Subject: 'visudo' non-deterministic (sudo 1.8.15)
Date: Sat, 14 Nov 2015 16:45:37 +0100
The ‘visudo’ bits can differ depending on the phase of moon.

In Diffoscope we see a tiny difference in its .rodata section:

--8<---------------cut here---------------start------------->8---
7241 	Contents·​of·​section·​.​rodata:​ 	7241 	Contents·​of·​section·​.​rodata:​
7242 	·​1c580·​01000200·​65646974·​6f722e63·​00200900·​·​.​.​.​.​editor.​c.​·​.​.​ 	7242 	·​1c580·​01000200·​65646974·​6f722e63·​00200900·​·​.​.​.​.​editor.​c.​·​.​.​
7243 	·​1c590·​756e6162·​6c652074·​6f20616c·​6c6f6361·​·​unable·​to·​alloca 	7243 	·​1c590·​756e6162·​6c652074·​6f20616c·​6c6f6361·​·​unable·​to·​alloca
7244 	·​1c5a0·​7465206d·​656d6f72·​79002d2d·​00726573·​·​te·​memory.​-​-​.​res 	7244 	·​1c5a0·​7465206d·​656d6f72·​79002d2d·​00726573·​·​te·​memory.​-​-​.​res
7245 	·​1c5b0·​6f6c7665·​5f656469·​746f7200·​2e2f6669·​·​olve_editor.​.​/​fi 	7245 	·​1c5b0·​6f6c7665·​5f656469·​746f7200·​66696e64·​·​olve_editor.​find
7246 	·​1c5c0·​6e645f70·​6174682e·​63003a00·​252e2a73·​·​nd_path.​c.​:​.​%.​*s 	7246 	·​1c5c0·​5f706174·​682e6300·​3a00252e·​2a732f25·​·​_path.​c.​:​.​%.​*s/​%
--8<---------------cut here---------------end--------------->8---

On the left-hand side, we see “./find_path.c”; on the right-hand side,
it’s just “find_path.c”.

Looking at the build logs, we have:

--8<---------------cut here---------------start------------->8---
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/bash ../../libtool  --mode=compile gcc -std=gnu99 -c -I../../include -I../.. -I. -I. -I../.. -DLIBDIR=\"/gnu/store/chyca85i2xfib5c5inj1bd6sq5vl56in-sudo-1.8.15/lib\" -DLOCALEDIR=\"/gnu/store/chyca85i2xfib5c5inj1bd6sq5vl56in-sudo-1.8.15/share/locale\" -D_PATH_SUDOERS=\"/etc/sudoers\" -DSUDOERS_UID=0 -DSUDOERS_GID=0 -DSUDOERS_MODE=0440 -D_PATH_MV='"/gnu/store/mnwjrkbfzkb5ifhqf8hssf3cxfvg11l6-coreutils-8.24/bin/mv"' -D_FORTIFY_SOURCE=2 -g -O2 -fvisibility=hidden -fPIE -fstack-protector-strong ./find_path.c
--8<---------------cut here---------------end--------------->8---

versus:

--8<---------------cut here---------------start------------->8---
/gnu/store/311nvir0pz1mhf0mgsmfrw00qfj7yq0j-bash-4.3.39/bin/bash ../../libtool  --mode=compile gcc -std=gnu99 -c -I../../include -I../.. -I. -I. -I../.. -DLIBDIR=\"/gnu/store/chyca85i2xfib5c5inj1bd6sq5vl56in-sudo-1.8.15/lib\" -DLOCALEDIR=\"/gnu/store/chyca85i2xfib5c5inj1bd6sq5vl56in-sudo-1.8.15/share/locale\" -D_PATH_SUDOERS=\"/etc/sudoers\" -DSUDOERS_UID=0 -DSUDOERS_GID=0 -DSUDOERS_MODE=0440 -D_PATH_MV='"/gnu/store/mnwjrkbfzkb5ifhqf8hssf3cxfvg11l6-coreutils-8.24/bin/mv"' -D_FORTIFY_SOURCE=2 -g -O2 -fvisibility=hidden -fPIE -fstack-protector-strong ./find_path.c

[…]

gcc -std=gnu99 -c -I../../include -I../.. -I. -I. -I../.. -DLIBDIR=\"/gnu/store/chyca85i2xfib5c5inj1bd6sq5vl56in-sudo-1.8.15/lib\" -DLOCALEDIR=\"/gnu/store/chyca85i2xfib5c5inj1bd6sq5vl56in-sudo-1.8.15/share/locale\" -D_PATH_SUDOERS=\"/etc/sudoers\" -DSUDOERS_UID=0 -DSUDOERS_GID=0 -DSUDOERS_MODE=0440 -D_PATH_MV='"/gnu/store/mnwjrkbfzkb5ifhqf8hssf3cxfvg11l6-coreutils-8.24/bin/mv"' -D_FORTIFY_SOURCE=2 -g -O2 -fvisibility=hidden -fPIE -fstack-protector-strong find_path.c
--8<---------------cut here---------------end--------------->8---

(See
<http://hydra.gnu.org/log/chyca85i2xfib5c5inj1bd6sq5vl56in-sudo-1.8.15>.)

Ludo’.

Information forwarded to bug-guix <at> gnu.org:
bug#21918; Package guix. (Sun, 15 Nov 2015 23:48:02 GMT) Full text and rfc822 format available.

Message #8 received at 21918 <at> debbugs.gnu.org (full text, mbox):

From: ludo <at> gnu.org (Ludovic Courtès)
To: 21918 <at> debbugs.gnu.org
Subject: Re: bug#21918: 'visudo' non-deterministic (sudo 1.8.15)
Date: Mon, 16 Nov 2015 00:47:16 +0100
[Message part 1 (text/plain, inline)]
Building things with -j1 (commit 511495f) doesn’t help.  This time,
‘visudo’ ends up with a similar difference:

--8<---------------cut here---------------start------------->8---
7241 	Contents·​of·​section·​.​rodata:​ 	7241 	Contents·​of·​section·​.​rodata:​
7242 	·​1c580·​01000200·​2e2f6564·​69746f72·​2e630020·​·​.​.​.​.​.​/​editor.​c.​·​ 	7242 	·​1c580·​01000200·​65646974·​6f722e63·​00200900·​·​.​.​.​.​editor.​c.​·​.​.​
--8<---------------cut here---------------end--------------->8---

The two build logs show one interesting difference:

[Message part 2 (text/x-patch, inline)]
@@ -1198,6 +1201,7 @@ case "" in \
 esac
 libtool: link: gcc -shared  -fPIC -DPIC  .libs/sudo_auth.o .libs/pam.o .libs/boottime.o .libs/check.o .libs/editor.o .libs/env.o .libs/find_path.o .libs/goodpath.o .libs/group_plugin.o .libs/interfaces.o .libs/iolog.o .libs/iolog_path.o .libs/locale.o .libs/logging.o .libs/logwrap.o .libs/parse.o .libs/policy.o .libs/prompt.o .libs/set_perms.o .libs/sudo_nss.o .libs/sudoers.o .libs/timestamp.o  -Wl,--whole-archive ./.libs/libparsesudoers.a -Wl,--no-whole-archive  -Wl,-rpath -Wl,/gnu/store/ijjmxqjbq6pxlimajzifi2r77dq41h01-linux-pam-1.2.1/lib -Wl,-rpath -Wl,/tmp/nix-build-sudo-1.8.15.drv-0/sudo-1.8.15/lib/util/.libs -Wl,-rpath -Wl,/gnu/store/ijjmxqjbq6pxlimajzifi2r77dq41h01-linux-pam-1.2.1/lib -Wl,-rpath -Wl,/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/libexec/sudo /gnu/store/ijjmxqjbq6pxlimajzifi2r77dq41h01-linux-pam-1.2.1/lib/libpam.so ../../lib/util/.libs/libsudo_util.so -ldl  -Wl,-z -Wl,relro -fstack-protector-strong   -Wl,-soname -Wl,sudoers.so -o .libs/sudoers.so
 libtool: link: ( cd ".libs" && rm -f "sudoers.la" && ln -s "../sudoers.la" "sudoers.la" )
+gcc -std=gnu99 -c -I../../include -I../.. -I. -I. -I../.. -DLIBDIR=\"/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/lib\" -DLOCALEDIR=\"/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/share/locale\" -D_PATH_SUDOERS=\"/etc/sudoers\" -DSUDOERS_UID=0 -DSUDOERS_GID=0 -DSUDOERS_MODE=0440 -D_PATH_MV='"/gnu/store/mnwjrkbfzkb5ifhqf8hssf3cxfvg11l6-coreutils-8.24/bin/mv"' -D_FORTIFY_SOURCE=2 -g -O2 -fvisibility=hidden -fPIE -fstack-protector-strong editor.c
 gcc -std=gnu99 -c -I../../include -I../.. -I. -I. -I../.. -DLIBDIR=\"/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/lib\" -DLOCALEDIR=\"/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/share/locale\" -D_PATH_SUDOERS=\"/etc/sudoers\" -DSUDOERS_UID=0 -DSUDOERS_GID=0 -DSUDOERS_MODE=0440 -D_PATH_MV='"/gnu/store/mnwjrkbfzkb5ifhqf8hssf3cxfvg11l6-coreutils-8.24/bin/mv"' -D_FORTIFY_SOURCE=2 -g -O2 -fvisibility=hidden -fPIE -fstack-protector-strong find_path.c
 gcc -std=gnu99 -c -I../../include -I../.. -I. -I. -I../.. -DLIBDIR=\"/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/lib\" -DLOCALEDIR=\"/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/share/locale\" -D_PATH_SUDOERS=\"/etc/sudoers\" -DSUDOERS_UID=0 -DSUDOERS_GID=0 -DSUDOERS_MODE=0440 -D_PATH_MV='"/gnu/store/mnwjrkbfzkb5ifhqf8hssf3cxfvg11l6-coreutils-8.24/bin/mv"' -D_FORTIFY_SOURCE=2 -g -O2 -fvisibility=hidden -fPIE -fstack-protector-strong ./sudo_printf.c
 gcc -std=gnu99 -c -I../../include -I../.. -I. -I. -I../.. -DLIBDIR=\"/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/lib\" -DLOCALEDIR=\"/gnu/store/5hvzy6kmr60m1psgz5m8ggw6w3y1xljf-sudo-1.8.15/share/locale\" -D_PATH_SUDOERS=\"/etc/sudoers\" -DSUDOERS_UID=0 -DSUDOERS_GID=0 -DSUDOERS_MODE=0440 -D_PATH_MV='"/gnu/store/mnwjrkbfzkb5ifhqf8hssf3cxfvg11l6-coreutils-8.24/bin/mv"' -D_FORTIFY_SOURCE=2 -g -O2 -fvisibility=hidden -fPIE -fstack-protector-strong ./visudo.c
[Message part 3 (text/plain, inline)]
The file ‘editor.c’ is compiled several times.  It looks as if whether
that extra compilation step (in plugins/sudoers/) was made was based on
a non-deterministic choice.

Ludo’.

Reply sent to Leo Famulari <leo <at> famulari.name>:
You have taken responsibility. (Sun, 22 Mar 2020 21:18:02 GMT) Full text and rfc822 format available.

Notification sent to ludo <at> gnu.org (Ludovic Courtès):
bug acknowledged by developer. (Sun, 22 Mar 2020 21:18:02 GMT) Full text and rfc822 format available.

Message #13 received at 21918-done <at> debbugs.gnu.org (full text, mbox):

From: Leo Famulari <leo <at> famulari.name>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 21918-done <at> debbugs.gnu.org
Subject: Re: bug#21918: 'visudo' non-deterministic (sudo 1.8.15)
Date: Sun, 22 Mar 2020 17:17:34 -0400
Building sudo with --rounds=5 is working now. Closing the bug




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 20 Apr 2020 11:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 7 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.