Re: umask problem with yum/rpm?

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

 



On Tue, Oct 07, 2008 at 11:24:44AM +0200, Michael Schwendt wrote:
> On Tue, 7 Oct 2008 10:55:35 +0200, David Jansen wrote:
> 
> > Am I missing something, or is this a bug in either yum or rpm (on Fedora
> > 8):
> > 
> > Root's umask is set to 077, so files created by root are by default only
> > readable by root. Safest setting, so quite ok.
> > Now root runs an rpm or yum command to install or update files. Umask
> > setting is not used for the files extracted from the rpm, those get the
> > permissions as stored inside the package.
> 
> Or not -- in case of unowned directories, which are not listed in a
> package's files list. These will be unreadable by normal users because of
> your restrictive umask.

Good point about the unowned directories, these too get created with
root's umask at the time the yum or rpm command is run.
To clarify: it isn't my restrictive umask, it is the umask as set in
/etc/bashrc for all users. So I guess every Fedora (8) user will run
into this problem from time to time.

> 
> > But root's umask appears to be
> > in effect for the scripts that run from the rpm.
> [...]
> > So, should I report this as a bug, or is it known, or perhaps already
> > solved somehow?
> 
> If there isn't an open ticket anymore, open a new one:
> http://bugz.fedoraproject.org/rpm

Yes I will do that. Searched bugzilla already without finding a relevant
issue, so I thought I'd better ask first, just in case I was looking in
the wrong place.

> 
> It has been discussed years ago, and as a result some packagers
> run "umask 022" at the beginning of their scriptlets as a work-around.

Sounds like a good workaround. perhaps that should be suggested in the
packaging guidelines? It's probably always good for scripts such as
these to not depend on any previous environment setting, to make sure
the script will have the desired results on any Fedora system, even if
local modifications have been made.

David

-- 
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
Guidelines: http://fedoraproject.org/wiki/Communicate/MailingListGuidelines

[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux