bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

coreutils-5.2.1 build/check: rm failed test fail-eperm


From: anirkko
Subject: coreutils-5.2.1 build/check: rm failed test fail-eperm
Date: Tue, 1 May 2007 10:04:01 +0200 (MET DST)

Hi
coreutils-5.2.1 build/check: rm failed test fail-eperm
by removing one of my system files in /tmp (!) which I believe
is a fault in the test itself, not the rm program.

The reason seems to be that if a file can be found in a directory
with the sticky bit set, and the directory is world-writeable, the
file is NOT owned by user, but in the same group and file group-writeable,
or in a different group but file world-writeable, then the remove succeeds!

See man-page of (2)chmod (on Solaris, excerpt attached below).

Could you be a bit more careful with randomly removing my system files
without any preceding warnings...?  ;-)  ;-)

All other tests pass with 'gmake check' and also, when
running as root, with 'gmake check-root'.

Greetings,
Arto

System:    sparc-sun-solaris2.6
----------------------------------------------------------
...
...
Making check in rm
gmake[2]: Entering directory 
`/build/coreutils-5.2.1_static-obj9_g412-b2175020070420-O3-mcpu=supersparc/tests/rm'
gmake  check-TESTS
gmake[3]: Entering directory 
`/build/coreutils-5.2.1_static-obj9_g412-b2175020070420-O3-mcpu=supersparc/tests/rm'
PASS: dir-no-w
***************************
NOTICE:
/build/coreutils-5.2.1/tests/rm/fail-2eperm: This test is being skipped, since 
it works only
when run as root.
***************************
SKIP: fail-2eperm
PASS: cycle
PASS: i-no-r
fail-eperm: unexpected exit status from `rm -f /tmp/ContentManager.lock';
  got 0, expected 1
FAIL: fail-eperm
PASS: dangling-symlink
PASS: rm1
PASS: rm2
PASS: rm3
PASS: rm4
PASS: rm5
PASS: unread2
PASS: r-1
PASS: r-2
PASS: r-3
PASS: i-1
PASS: ir-1
PASS: f-1
PASS: sunos-1
PASS: deep-1
/build/coreutils-5.2.1/tests/rm/hash: This test is relatively expensive, so it 
is disabled by default.
To run it anyway, rerun make check with the RUN_EXPENSIVE_TESTS
environment variable set to yes.  E.g.,

  env RUN_EXPENSIVE_TESTS=yes make check

SKIP: hash
PASS: isatty
======================================
1 of 20 tests failed
(2 tests were not run)
Please report to address@hidden
======================================
gmake[3]: *** [check-TESTS] Error 1
...
...



MAN-PAGE (man -s 2 chmod)
----------------------------------------------------------
System Calls                                             chmod(2)

     If a directory is writable and has S_ISVTX (the sticky  bit)
     set,  files  within that directory can be removed or renamed
     only if one or more of the following is true (see  unlink(2)
     and rename(2)):

               o    the user owns the file

               o    the user owns the directory

               o    the file is writable by the user

               o    the user is a privileged user




reply via email to

[Prev in Thread] Current Thread [Next in Thread]