Re: [OpenWrt-Devel] [Bug: Busybox 1.22.1] false return 0 instead of 1 with '--help' switch.

2014-09-02 Thread Alive4Ever
On Friday, August 29, 2014 02:08:56 PM Bastian Bittorf wrote:
 * Alive4ever alive4e...@live.com [29.08.2014 14:03]:
  I'm using an embedded system with busybox v1.22.1, running Openwrt Chaos 
  Chalmer r42321, mips24k AR9330
  
  When I call 'busybox false --help', the return status is zero. I think it 
  has nothing todo with openwrt, because it's the output of busybox, not the 
  problem on openwrt performance. I feel it's strange, because GNU coreutils 
  false binary gives return status 1, even when invoked with '--help' switch. 
  I also notice that Ubuntu busybox false, which is version 1.21.1 performs 
  the same behaviour as GNU coreutils.
  
 
 i cannot see a bug here on OpenWrt:
 
 root@box:~ busybox false --help
 BusyBox v1.22.1 (2014-08-28 18:55:30 EDT) multi-call binary.
 
 Usage: false 
 
 Return an exit code of FALSE (1)
 
 root@box:~ echo $?
 0
 root@box:~ false --help
 root@box:~ echo $?
 1
 root@box:~ false bla
 root@box:~ echo $?
 1
 
 bye, bastian

Hi bastian,
If you are just typing false on openwrt shell, it uses false in the 
built in shell.

root@OpenWrt:~# type false
false is a shell builtin
root@OpenWrt:~# false --help
root@OpenWrt:~# echo $?
1
root@OpenWrt:~#

There is no problem with ash built in false. The problem is busybox 
false applet.
To invoke busybox false, either call '/bin/false' or '/bin/busybox false'

root@OpenWrt:~# /bin/false --help ; echo $?
BusyBox v1.22.1 (2014-08-28 15:20:07 WIB) multi-call binary.

Usage: false 

Return an exit code of FALSE (1)

0

root@OpenWrt:~# busybox false --help ; echo $?
BusyBox v1.22.1 (2014-08-28 15:20:07 WIB) multi-call binary.

Usage: false 

Return an exit code of FALSE (1)

0

That's the unexpected behavior from busybox false applet.
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [Bug: Busybox 1.22.1] false return 0 instead of 1 with '--help' switch.

2014-08-30 Thread Alive4ever
I'm using an embedded system with busybox v1.22.1, running Openwrt Chaos 
Chalmer r42321, mips24k AR9330

When I call 'busybox false --help', the return status is zero. I think it has 
nothing todo with openwrt, because it's the output of busybox, not the problem 
on openwrt performance. I feel it's strange, because GNU coreutils false binary 
gives return status 1, even when invoked with '--help' switch. I also notice 
that Ubuntu busybox false, which is version 1.21.1 performs the same behaviour 
as GNU coreutils.

Since /bin/false is linked to busybox and configured to disable login for 
daemon users, it will pose s security hole if this zero return status is 
exploited. I mark this as bug  because busybox false doesn't return 'false'.

Is this behaviour intended with busybox false implementation?

Thanks.
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [Bug: Busybox 1.22.1] false return 0 instead of 1 with '--help' switch.

2014-08-30 Thread Bastian Bittorf
* Alive4ever alive4e...@live.com [29.08.2014 14:03]:
 I'm using an embedded system with busybox v1.22.1, running Openwrt Chaos 
 Chalmer r42321, mips24k AR9330
 
 When I call 'busybox false --help', the return status is zero. I think it has 
 nothing todo with openwrt, because it's the output of busybox, not the 
 problem on openwrt performance. I feel it's strange, because GNU coreutils 
 false binary gives return status 1, even when invoked with '--help' switch. I 
 also notice that Ubuntu busybox false, which is version 1.21.1 performs the 
 same behaviour as GNU coreutils.
 

i cannot see a bug here on OpenWrt:

root@box:~ busybox false --help
BusyBox v1.22.1 (2014-08-28 18:55:30 EDT) multi-call binary.

Usage: false 

Return an exit code of FALSE (1)

root@box:~ echo $?
0
root@box:~ false --help
root@box:~ echo $?
1
root@box:~ false bla
root@box:~ echo $?
1

bye, bastian
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [Bug: Busybox 1.22.1] false return 0 instead of 1 with '--help' switch.

2014-08-29 Thread Alive4ever
I'm using an embedded system with busybox v1.22.1, running Openwrt Chaos 
Chalmer r42321, mips24k AR9330

When I call 'busybox false --help', the return status is zero. I think it has 
nothing todo with openwrt, because it's the output of busybox, not the problem 
on openwrt performance. I feel it's strange, because GNU coreutils false binary 
gives return status 1, even when invoked with '--help' switch. I also notice 
that Ubuntu busybox false, which is version 1.21.1 performs the same behaviour 
as GNU coreutils.

Since /bin/false is linked to busybox and configured to disable login for 
daemon users, it will pose s security hole if this zero return status is 
exploited. I mark this as bug  because busybox false doesn't return 'false'.

Is this behaviour intended with busybox false implementation?

Thanks.
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel