Re: Kernelsources writeable for everyone?!



Daniel schrieb:
Hi,
may be this was reported/asked 999999999 times, but here ist the 1000000000th:

You're close. :-P

I have downloaded linux-2.6.17.1 10 min ago and I noticed that every file is
writeable by everyone. What's going on there?

coffee src # tar -jtvf linux-2.6.17.1.tar.bz2
drwxrwxrwx git/git 0 2006-06-20 11:31:55 linux-2.6.17.1/

This is intentional. You can set the permissions to anything you want
by making tar honor the umask setting -- without needing to run chmod
after extracting.

So either use the --no-same-permissions option of GNU tar, or simply
don't run tar as root (then this option is on by default), which is a
good idea anyway.

René
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: World writable tarballs
    ... It's a big security hole deliberately caused by the kernel people (files ... in the tar ball have og+w, so it's not problem in roots umask or tar). ... untarring files as root. ...
    (Linux-Kernel)
  • Re: Converting ext3->XFS
    ... >>with odd permissions, tar it, untar it, and see what happens. ... > Ahh, i had tried this already, but i just did the untar as root and it works. ...
    (Debian-User)
  • Re: tar preserves setuid bit
    ... > the file to root. ... However owner information is extracted from the tar ... > extracted files is the root user. ... > the root user if the root user extracts the files from a malliciously ...
    (Bugtraq)
  • Re: [PHP] including files outside of document root
    ... I tend to keep the directories in the document root, ... via an .htaccess file. ... tar -cvf moving.tar httpdocs ...
    (php.general)
  • Re: taring a entire system to a file
    ... >files to tar rather than attempt to tar from root. ... difficult to avoid as time passes and archives are sent around. ... I clobbered a couple of root file systems in exactly this fashion myself. ... These are my opinions not Raytheon Company. ...
    (comp.os.linux.misc)