summaryrefslogtreecommitdiff
path: root/cifsacl.h
AgeCommit message (Collapse)AuthorFilesLines
2020-12-16Extend cifs acl utilities to handle SACLsBoris Protopopov1-15/+42
Extend getcifsacl/setcifsacl utilities to handle System ACLs (SACLs) in addition to Discretionary ACLs (DACLs). The SACL extensions depend on CIFS client support for system.cifs_ntsd_full extended attribute. Signed-off-by: Boris Protopopov <pboris@amazon.com>
2020-09-03Add support for setting owner and group in ntsdBoris Protopopov1-1/+3
Extend setcifsacl utility to allow setting owner and group SIDs in the security descriptor in addition to setting ACLs. This is a user-friendly intefrace for setting owner and group SIDs that takes advantage of the recent extensions in the CIFS kernel client, and it complements setting raw values via setfattr. Signed-off-by: Boris Protopopov <boris.v.protopopov@gmail.com>
2012-12-19cifs-utils: struct cifs_sid definition to new cifsidmap.h headerJeff Layton1-10/+2
People who want to build a plugin for the idmapping routines will need a header to describe the data types that they need. Add a cifsidmap.h file and move the struct cifs_sid definition into it, along with the constants needed to describe it. Signed-off-by: Jeff Layton <jlayton@samba.org>
2012-11-07cifsacl: header file cleanupJeff Layton1-11/+10
Remove the unused ace_action enum, and express mask values by or'ing what they represent. Add a comment about the endianness of these values in the packed structs too. Signed-off-by: Jeff Layton <jlayton@samba.org>
2012-11-07setcifsacl: clean up sizing of cifs_sidJeff Layton1-2/+5
The max number of subauthorities on windows and in winbind is generally 15, not 5. If winbind sends more than 5, then this code may end up overrunning the buffer. Also, define some preprocessor constants and use those instead of hardcoding '5' and '6' all over the place. Signed-off-by: Jeff Layton <jlayton@samba.org>
2012-10-29cifs.idmap: make sure cifsacl structs are packedJeff Layton1-4/+4
The kernel equivalent definitions are defined with __attribute__((packed)), and the code seems to assume the userspace and kernel ones will be properly aligned. Fix the userspace definitions in a similar fashion. Given the way these structs are, there is probably not any padding between fields on most arches, but it's best to be safe here. Reviewed-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com> Signed-off-by: Jeff Layton <jlayton@samba.org>
2011-08-25cifsacl: Add file cifsacl.h (try #2)Shirish Pargaonkar1-0/+136
Add defines and structures related to security descriptor, ACL, ACE, various fields within an ACE, and SID. Also define various file permissions and acess types. Signed-off-by: Shirish Pargaonkar <shirishpargaonkar@gmail.com>