Subject: coreutils: test doesn't work properly with ACL permissions Package: coreutils Version: 5.94-1 Severity: important
NOTE: I have only confirmed this behavior in the version in testing. The test -r command doesn't seem to work with ACL contolled permissions. wtynthes:/var/log$ ls -ld debsync/ drwxrwx---+ 2 root adm 30 2006-06-22 11:47 debsync/ [EMAIL PROTECTED]:/var/log$ getfacl debsync/ # file: debsync # owner: root # group: adm user::rwx user:debmirror:rwx group::rwx mask::rwx other::--- Notice that the debsync has an ACL to allow the debmirror user rwx. [EMAIL PROTECTED]:/var/log$ test -r debsync [EMAIL PROTECTED]:/var/log$ echo $? 1 This behavior is correct. My normal user doesn't have read access. [EMAIL PROTECTED]:/var/log$ sudo su Password: coryanthes:/var/log# test -r debsync coryanthes:/var/log# echo $? 0 Again, this behavior is correct. Root has read access. coryanthes:/var/log# su -s /bin/bash debmirror [EMAIL PROTECTED]:/var/log$ test -r debsync/ [EMAIL PROTECTED]:/var/log$ echo $? 1 This behavior is incorrect. The debmirror user should have read access granted by the ACL. Here is the how the volume is mounted. [EMAIL PROTECTED]:/var/log$ mount | grep '\/var\/log' /dev/mapper/vg0-var--log on /var/log type xfs (rw) Similar behavior is observed with 'test -w' leading me to believe that test has no support for ACLs. Here is evidence to support that hypothesis. [EMAIL PROTECTED]:/var/log$ ldd /usr/bin/test linux-gate.so.1 => (0xffffe000) libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0xb7e80000) /lib/ld-linux.so.2 (0xb7fbe000) The test binary is clearly not linked to the libacl. I guess it could be statically linked, but even /bin/ls links to libacl. Therefore, it seems test was never compiled with support for ACLs. However, I guess it could just be testing for write access with the standard C lib. In that case, I don't have any idea what the root cause is. Please don't hesitate to ask for more info. I will provide it if possible. Thanks, wt -- System Information: Debian Release: testing/unstable APT prefers testing APT policy: (500, 'testing') Architecture: i386 (i686) Shell: /bin/sh linked to /bin/bash Kernel: Linux 2.6.15-1-686 Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1) Versions of packages coreutils depends on: ii libacl1 2.2.37-1 Access control list shared library ii libc6 2.3.6-13 GNU C Library: Shared libraries ii libselinux1 1.30-1 SELinux shared libraries coreutils recommends no packages. -- no debconf information -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]