[BusyBox] Possible tar bug in 1.0.0-rc3

Nathan Angelacos nangel at nothome.org
Fri Oct 8 15:57:06 UTC 2004


busybox tar doesn't seem to honor umask when creating directories needed to 
extract a file. (e.g. when the dir entry is not explicity in the tar archive)

Here's a test script:

echo umask is $( umask )
mkdir testcase
touch testcase/afile
echo  testcase dir permissions are:
ls -ld testcase
tar cf test.tar testcase/afile
rm -rf testcase
tar xf test.tar
ls -ld testcase
rm test.tar
rm -rf testcase


The output from tar (GNU tar) 1.14
umask is 0022
testcase dir permissions are:
drwxr-xr-x  2 root root 72 Oct  8 11:51 testcase
drwxr-xr-x  2 root root 72 Oct  8 11:51 testcase

This is the output from busybox 1.0rc3 tar
umask is 0022
testcase dir permissions are:
drwxr-xr-x    2 root     root           60 Oct  8 15:50 testcase
drwxrwxr-x    2 root     root           60 Oct  8 15:50 testcase

The tar tvf test.tar:
-rw-r--r-- root/root         0 2004-10-08 11:52:21 testcase/afile

If testcase is explicitly in the tar archive (e.g. tar cf test.tar testcase ) 
then the permissions are set according to the archive.

Is there something I'm missing?   Thanks!



More information about the busybox mailing list