summaryrefslogtreecommitdiff
path: root/source3/include
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2001-02-15 19:56:10 +0000
committerJeremy Allison <jra@samba.org>2001-02-15 19:56:10 +0000
commitddfac242e3c6b16b93a6fabf73f837cd5ffe216a (patch)
tree6fd48f44c4cc5a1772afef2b1ce8e03c22a965f0 /source3/include
parenta82df9c67367e0828afcc65b0635187c73e2813a (diff)
downloadsamba-ddfac242e3c6b16b93a6fabf73f837cd5ffe216a.tar.gz
samba-ddfac242e3c6b16b93a6fabf73f837cd5ffe216a.tar.bz2
samba-ddfac242e3c6b16b93a6fabf73f837cd5ffe216a.zip
Patch to add UnixWare ACLs from Michael Davidson <md@sco.COM>. With some
small modifications, this code may also work on Solaris, as they are derived from the same SVR4 codebase. When the Samba Solaris box is up and running again I will test this. Jeremy. (This used to be commit f8db87b0978be981448eafd57163703e3aeec2cb)
Diffstat (limited to 'source3/include')
-rw-r--r--source3/include/smb_acls.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/source3/include/smb_acls.h b/source3/include/smb_acls.h
index 944baaa4e5..578e9f2751 100644
--- a/source3/include/smb_acls.h
+++ b/source3/include/smb_acls.h
@@ -54,6 +54,45 @@
#define SMB_ACL_TYPE_ACCESS ACL_TYPE_ACCESS
#define SMB_ACL_TYPE_DEFAULT ACL_TYPE_DEFAULT
+#elif defined(HAVE_UNIXWARE_ACLS)
+
+/*
+ * Donated by Michael Davidson <md@sco.COM> for UnixWare.
+ * As this is generic SVR4.x code, it may also work for Solaris !
+ */
+
+/* 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 S_IRUSR
+#define SMB_ACL_WRITE S_IWUSR
+#define SMB_ACL_EXECUTE S_IXUSR
+
+/* 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_SOLARIS_ACLS)
#elif defined(HAVE_IRIX_ACLS)