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...
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.
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
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...
This has now been fixed upstream, but it would still be nice to see this fix while we're waiting on a new release...
(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
Fixed in OpenRC 0.4.3.