Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 281471 Details for
Bug 246681
umask not honored in mkhomedir
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
current proposed patch
oddjob-0.27-sigpipe-umask.patch (text/plain), 2.52 KB, created by
Nalin Dahyabhai
on 2007-12-07 18:43:31 UTC
(
hide
)
Description:
current proposed patch
Filename:
MIME Type:
Creator:
Nalin Dahyabhai
Created:
2007-12-07 18:43:31 UTC
Size:
2.52 KB
patch
obsolete
>--- src/mkhomedir.c 5 Apr 2006 22:44:37 -0000 1.10 >+++ src/mkhomedir.c 5 Sep 2007 21:18:30 -0000 1.13 >@@ -37,6 +37,7 @@ > #include <getopt.h> > #include <limits.h> > #include <stdio.h> >+#include <stdlib.h> > #include <string.h> > #include <unistd.h> > #include <pwd.h> >@@ -246,7 +247,7 @@ > int > main(int argc, char **argv) > { >- char **args; >+ char **args, *p; > int i, flags = FLAG_POPULATE; > > openlog(PACKAGE "-mkhomedir", LOG_PID, LOG_DAEMON); >@@ -266,7 +267,12 @@ > skel_dir = optarg; > break; > case 'u': >- override_umask = atoi(optarg); >+ override_umask = strtol(optarg, &p, 0); >+ if ((p == NULL) || (*p != '\0')) { >+ fprintf(stderr, "Invalid umask \"%s\".\n", >+ optarg); >+ return 1; >+ } > break; > default: > fprintf(stderr, "Valid options:\n" >@@ -275,8 +281,9 @@ > "-q\tDo not print messages when creating " > "a directory.\n" > "-s PATH\tOverride the skeleton directory " >- "path.\n" >- "-u MASK\tOverride the default umask.\n"); >+ "path (\"%s\").\n" >+ "-u MASK\tOverride the default umask (0%03o).\n", >+ skel_dir, override_umask); > return 1; > } > } >--- src/oddjobd.c 19 Jul 2006 20:08:02 -0000 1.44 >+++ src/oddjobd.c 5 Sep 2007 21:43:43 -0000 1.46 >@@ -2827,9 +2827,11 @@ > } > > static void >-sighup_handler(int signum) >+signal_handler(int signum) > { >- globals.reload++; >+ if (signum == SIGHUP) { >+ globals.reload++; >+ } > } > > int >@@ -2968,9 +2970,14 @@ > /* Prepare for reload signals. */ > memset(&action, 0, sizeof(action)); > sigemptyset(&action.sa_mask); >- action.sa_handler = sighup_handler; >+ action.sa_handler = signal_handler; > if (sigaction(SIGHUP, &action, NULL) != 0) { > fprintf(stderr, "Error setting SIGHUP handler (%s)\n", >+ strerror(errno)); >+ return 1; >+ } >+ if (sigaction(SIGPIPE, &action, NULL) != 0) { >+ fprintf(stderr, "Error setting SIGPIPE handler (%s)\n", > strerror(errno)); > return 1; > } >--- src/pam_oddjob_mkhomedir.8.in 19 Jul 2006 20:08:02 -0000 1.5 >+++ src/pam_oddjob_mkhomedir.8.in 5 Sep 2007 21:16:13 -0000 1.7 >@@ -11,6 +11,10 @@ > method of the \fI@NAMESPACE@.oddjob\fR service for the \fBPAM_USER\fR if > the module is running with superuser privileges. Otherwise, it invokes > the \fImkmyhomedir\fR method. >+ >+The location of the skeleton directory and the default umask are determined by >+the configuration for the corresponding service in \fBoddjobd.conf\fR, >+so they can not be specified as arguments to this module. > > If \fID-Bus\fR has not been configured to allow the calling application to > invoke these methods provided as part of the \fI@NAMESPACE@.oddjob\fR interface
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 246681
:
158482
| 281471