[jira] [Issue Comment Edited] (DAEMON-178) jsvc process does not take the umask of the running user. It is always 077

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[jira] [Issue Comment Edited] (DAEMON-178) jsvc process does not take the umask of the running user. It is always 077

ASF GitHub Bot (Jira)

    [ https://issues.apache.org/jira/browse/DAEMON-178?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13086236#comment-13086236 ]

Jose D. Benavent edited comment on DAEMON-178 at 8/17/11 10:53 AM:
-------------------------------------------------------------------

Thank you, J Miller(y).

I had turned mad wondering why the TOMCAT_USER (off) was not granted read permission to the *catalina.out* log file.
It is required, for example, to check error messages when an app is deployed.

I downloaded release 6.0.29 which includes *commons-daemon-1.0.2-native-src*, i.e, version 1.0.2 is affected too.

      was (Author: jdbenavent):
    Thank you, J Miller(y).

I had turned mad wondering why the TOMCAT_USER (off) was not granted read permission to the catalina.out log file.
It is required, for example, to check error messages when an app is deployed.

I downloaded release 6.0.29 which includes *commons-daemon-1.0.2-native-src*, i.e, version 1.0.2 is affected too.
 

> jsvc process does not take the umask of the running user. It is always 077
> --------------------------------------------------------------------------
>
>                 Key: DAEMON-178
>                 URL: https://issues.apache.org/jira/browse/DAEMON-178
>             Project: Commons Daemon
>          Issue Type: Bug
>          Components: Jsvc
>    Affects Versions: 1.0.3
>         Environment: Ubuntu Hardy 8.0.4, jdk1.6.2
>            Reporter: J Miller
>             Fix For: 1.0.4
>
>
> 1) create a simple implementation of the Daemon interface that writes "hello world" log files
> 2) compile jsvc as described in the documentation
> 3) verify that your linux user has umask != 077, by typing "umask"
> 4) start jsvc with all the required CP args as described in the documentation
> 5) look the log file permissions
> Expected: The permissions are not 700.
> Actual: They are 700.
> 6) Modify commons-daemon/src/native/unix/native/jsvc-unix.c, replacing 077 with 022
> 7) recompile jsvc
> 8) repeat 4-5
> Expected: The permissions are 755.
> Actual: The permissions are 755.
> Conclusion: The jsvc process uses a hard-coded value, instead of adopting the running user's umask, as expected.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira