[Bug 607] "test -r" does not work properly with pipe files
bugzilla at busybox.net
bugzilla at busybox.net
Sat Sep 12 20:06:58 UTC 2009
https://bugs.busybox.net/show_bug.cgi?id=607
--- Comment #3 from Denys Vlasenko <vda.linux at googlemail.com> 2009-09-12 20:06:57 UTC ---
You see it because you run as root.
I see the same with both busybox and with bash:
# mkfifo busybox_TST
# chmod a=r busybox_TST
# bash -c 'test -r busybox_TST; echo $?'
0
# bash -c 'test -w busybox_TST; echo $?'
0
# bash -c './busybox test -r busybox_TST; echo $?'
0
# bash -c './busybox test -w busybox_TST; echo $?'
0
But under non-root, test -w returns "false":
# bash -c 'setuidgid 1:1 ./busybox test -r busybox_TST; echo $?'
0
# bash -c 'setuidgid 1:1 ./busybox test -w busybox_TST; echo $?'
1
# setuidgid 1:1 bash -c 'test -r busybox_TST; echo $?'
0
# setuidgid 1:1 bash -c 'test -w busybox_TST; echo $?'
1
Again, we are bash-compatible here. Looks like it is not a bug.
--
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the busybox-cvs
mailing list