Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 258510 - =sys-apps/openrc-0.4* has umask option that doesn't work
Summary: =sys-apps/openrc-0.4* has umask option that doesn't work
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] baselayout (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-02-10 21:45 UTC by Douglas Mayle
Modified: 2009-02-11 14:57 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
files/openrc-0.4.1-umask.patch fixes the umask bug (openrc-0.4.1-umask.patch,602 bytes, patch)
2009-02-10 21:50 UTC, Douglas Mayle
Details | Diff
openrc-0.4.1-r2.ebuild updated ebuild that uses the patch (openrc-0.4.1-r2.ebuild,10.05 KB, text/plain)
2009-02-10 21:51 UTC, Douglas Mayle
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Douglas Mayle 2009-02-10 21:45:42 UTC
If you try to use the -k or --umask option of start-stop-daemon in openrc-0.4.1 or greater, it does not actually work due to a bug in the code.

Reproducible: Always

Steps to Reproduce:
1. start-stop-daemon --umask 077 touch test.file
2. ls -l test.file

Actual Results:  
-rw-r--r-- 1 root root 0 Feb 10 16:44 test.file

Expected Results:  
-rw------- 1 root root 0 Feb 10 16:44 test.file

I'm including an updated ebuild with a patch, and submitting the fix upstream...
Comment 1 Douglas Mayle 2009-02-10 21:50:02 UTC
Created attachment 181572 [details, diff]
files/openrc-0.4.1-umask.patch fixes the umask bug

This is a patch that prevents the code from shooting itself in the foot.
Comment 2 Douglas Mayle 2009-02-10 21:51:11 UTC
Created attachment 181574 [details]
openrc-0.4.1-r2.ebuild updated ebuild that uses the patch

updated ebuild file that calls epatch to fix the umask bug
Comment 3 Douglas Mayle 2009-02-10 22:03:11 UTC
I've filed this upstream as well at http://roy.marples.name/projects/openrc/ticket/146  I'm not sure what the protocol is on patches and making sure they apply to all affected version.  I've only patched 0.4.1 even though 0.4.2 is affected as well...
Comment 4 Douglas Mayle 2009-02-10 23:17:17 UTC
This has now been fixed upstream, but it would still be nice to see this fix while we're waiting on a new release...
Comment 5 Roy Marples 2009-02-11 07:34:50 UTC
(In reply to comment #4)
> This has now been fixed upstream, but it would still be nice to see this fix
> while we're waiting on a new release...

openrc-0.4.3 has now been released
Comment 6 Doug Goldstein (RETIRED) gentoo-dev 2009-02-11 14:57:32 UTC
Fixed in OpenRC 0.4.3.