diff options
author | Jeremy Allison <jra@samba.org> | 2001-12-15 02:40:16 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-12-15 02:40:16 +0000 |
commit | ce1b141ec0ae3004f9ef94bbfd26ecf4510d6b4a (patch) | |
tree | 0f2f296cb2a5a93b76be6d38b64ce81416811d0c /source3/include | |
parent | 43e325d99167179cb7000451e252dcde7f0eb1a0 (diff) | |
download | samba-ce1b141ec0ae3004f9ef94bbfd26ecf4510d6b4a.tar.gz samba-ce1b141ec0ae3004f9ef94bbfd26ecf4510d6b4a.tar.bz2 samba-ce1b141ec0ae3004f9ef94bbfd26ecf4510d6b4a.zip |
Added HPUX ACL code.
Jeremy.
(This used to be commit 6d03184f8c039ad81de47b5f3bde7dac5b2815ad)
Diffstat (limited to 'source3/include')
-rw-r--r-- | source3/include/config.h.in | 1 | ||||
-rw-r--r-- | source3/include/smb_acls.h | 41 |
2 files changed, 42 insertions, 0 deletions
diff --git a/source3/include/config.h.in b/source3/include/config.h.in index 791892efdf..89798e4fcc 100644 --- a/source3/include/config.h.in +++ b/source3/include/config.h.in @@ -217,6 +217,7 @@ #undef HAVE_ACL_GET_PERM_NP #undef HAVE_UNIXWARE_ACLS #undef HAVE_SOLARIS_ACLS +#undef HAVE_HPUX_ACLS #undef HAVE_IRIX_ACLS #undef HAVE_AIX_ACLS #undef HAVE_TRU64_ACLS diff --git a/source3/include/smb_acls.h b/source3/include/smb_acls.h index 37aa7cb65c..53adf39dbc 100644 --- a/source3/include/smb_acls.h +++ b/source3/include/smb_acls.h @@ -122,6 +122,47 @@ typedef struct acl *SMB_ACL_ENTRY_T; #define SMB_ACL_TYPE_ACCESS 0 #define SMB_ACL_TYPE_DEFAULT 1 +#elif defined(HAVE_HPUX_ACLS) + +/* + * Based on the Solaris & UnixWare code. + */ + +#undef GROUP +#include <sys/aclv.h> + +/* SVR4.2 ES/MP ACLs */ +typedef int SMB_ACL_TAG_T; +typedef int SMB_ACL_TYPE_T; +typedef ushort *SMB_ACL_PERMSET_T; +typedef ushort SMB_ACL_PERM_T; +#define SMB_ACL_READ 4 +#define SMB_ACL_WRITE 2 +#define SMB_ACL_EXECUTE 1 + +/* Types of ACLs. */ +#define SMB_ACL_USER USER +#define SMB_ACL_USER_OBJ USER_OBJ +#define SMB_ACL_GROUP GROUP +#define SMB_ACL_GROUP_OBJ GROUP_OBJ +#define SMB_ACL_OTHER OTHER_OBJ +#define SMB_ACL_MASK CLASS_OBJ + +typedef struct SMB_ACL_T { + int size; + int count; + int next; + struct acl acl[1]; +} *SMB_ACL_T; + +typedef struct acl *SMB_ACL_ENTRY_T; + +#define SMB_ACL_FIRST_ENTRY 0 +#define SMB_ACL_NEXT_ENTRY 1 + +#define SMB_ACL_TYPE_ACCESS 0 +#define SMB_ACL_TYPE_DEFAULT 1 + #elif defined(HAVE_IRIX_ACLS) #define SMB_ACL_TAG_T acl_tag_t |