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 158850 Details for
Bug 247610
CIFS should honor umask
[?]
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]
patch -- make cifsd honor umask when unix extensions are enabled
0012-BZ-239339-CIFS-should-honour-umask.patch (text/plain), 2.56 KB, created by
Jeff Layton
on 2007-07-10 11:04:33 UTC
(
hide
)
Description:
patch -- make cifsd honor umask when unix extensions are enabled
Filename:
MIME Type:
Creator:
Jeff Layton
Created:
2007-07-10 11:04:33 UTC
Size:
2.56 KB
patch
obsolete
>From d7a4129ce483b7dce163c1e2dc7cd4351f2db165 Mon Sep 17 00:00:00 2001 >From: Jeff Layton <jlayton@redhat.com> >Date: Tue, 3 Jul 2007 15:04:30 -0400 >Subject: [PATCH] BZ#239339: CIFS should honour umask > >--- > fs/cifs/dir.c | 6 ++++-- > fs/cifs/inode.c | 5 +++-- > 2 files changed, 7 insertions(+), 4 deletions(-) > >diff --git a/fs/cifs/dir.c b/fs/cifs/dir.c >index 7be188c..0037dea 100644 >--- a/fs/cifs/dir.c >+++ b/fs/cifs/dir.c >@@ -226,7 +226,8 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode) > /* If Open reported that we actually created a file > then we now have to set the mode if possible */ > if ((cifs_sb->tcon->ses->capabilities & CAP_UNIX) && >- (oplock & CIFS_CREATE_ACTION)) >+ (oplock & CIFS_CREATE_ACTION)) { >+ mode &= ~current->fs->umask; > if(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SET_UID) { > CIFSSMBUnixSetPerms(xid, pTcon, full_path, mode, > (__u64)current->fsuid, >@@ -244,7 +245,7 @@ cifs_create(struct inode *inode, struct dentry *direntry, int mode) > cifs_sb->mnt_cifs_flags & > CIFS_MOUNT_MAP_SPECIAL_CHR); > } >- else { >+ } else { > /* BB implement mode setting via Windows security descriptors */ > /* eg CIFSSMBWinSetPerms(xid,pTcon,full_path,mode,-1,-1,local_nls);*/ > /* could set r/o dos attribute if mode & 0222 == 0 */ >@@ -363,6 +364,7 @@ int cifs_mknod(struct inode *inode, struct dentry *direntry, int mode, int devic > if(full_path == NULL) > rc = -ENOMEM; > else if (pTcon->ses->capabilities & CAP_UNIX) { >+ mode &= ~current->fs->umask; > if(cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SET_UID) { > rc = CIFSSMBUnixSetPerms(xid, pTcon, full_path, > mode,(__u64)current->fsuid,(__u64)current->fsgid, >diff --git a/fs/cifs/inode.c b/fs/cifs/inode.c >index df0e3fd..f889f9f 100644 >--- a/fs/cifs/inode.c >+++ b/fs/cifs/inode.c >@@ -782,7 +782,8 @@ int cifs_mkdir(struct inode *inode, struct dentry *direntry, int mode) > d_instantiate(direntry, newinode); > if (direntry->d_inode) > direntry->d_inode->i_nlink = 2; >- if (cifs_sb->tcon->ses->capabilities & CAP_UNIX) >+ if (cifs_sb->tcon->ses->capabilities & CAP_UNIX) { >+ mode &= ~current->fs->umask; > if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_SET_UID) { > CIFSSMBUnixSetPerms(xid, pTcon, full_path, > mode, >@@ -800,7 +801,7 @@ int cifs_mkdir(struct inode *inode, struct dentry *direntry, int mode) > cifs_sb->mnt_cifs_flags & > CIFS_MOUNT_MAP_SPECIAL_CHR); > } >- else { >+ } else { > /* BB to be implemented via Windows secrty descriptors > eg CIFSSMBWinSetPerms(xid, pTcon, full_path, mode, > -1, -1, local_nls); */ >-- >1.5.2.2 >
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 247610
: 158850