summaryrefslogtreecommitdiff
path: root/source3/include
diff options
context:
space:
mode:
Diffstat (limited to 'source3/include')
-rw-r--r--source3/include/privileges.h30
-rw-r--r--source3/include/smb.h2
2 files changed, 19 insertions, 13 deletions
diff --git a/source3/include/privileges.h b/source3/include/privileges.h
index cdf62b7f85..b4972c7a60 100644
--- a/source3/include/privileges.h
+++ b/source3/include/privileges.h
@@ -27,24 +27,24 @@
/* common privilege defines */
-#define SE_END 0x00000000
-#define SE_NONE 0x00000000
-#define SE_ALL_PRIVS 0xFFFFFFFF
+#define SE_END { { 0x00000000, 0x00000000, 0x00000000, 0x00000000 } }
+#define SE_NONE { { 0x00000000, 0x00000000, 0x00000000, 0x00000000 } }
+#define SE_ALL_PRIVS { { 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF } }
/*
* We will use our own set of privileges since it makes no sense
* to implement all of the Windows set when only a portion will
- * be used.
+ * be used. Use 128-bit mask to give room to grow.
*/
-#define SE_NETWORK_LOGON 0x00000001
-#define SE_INTERACTIVE_LOGON 0x00000002
-#define SE_BATCH_LOGON 0x00000004
-#define SE_SERVICE_LOGON 0x00000008
-#define SE_MACHINE_ACCOUNT 0x00000010
-#define SE_PRINT_OPERATOR 0x00000020
-#define SE_ADD_USERS 0x00000040
+#define SE_NETWORK_LOGON { { 0x00000001, 0x00000000, 0x00000000, 0x00000000 } }
+#define SE_INTERACTIVE_LOGON { { 0x00000002, 0x00000000, 0x00000000, 0x00000000 } }
+#define SE_BATCH_LOGON { { 0x00000004, 0x00000000, 0x00000000, 0x00000000 } }
+#define SE_SERVICE_LOGON { { 0x00000008, 0x00000000, 0x00000000, 0x00000000 } }
+#define SE_MACHINE_ACCOUNT { { 0x00000010, 0x00000000, 0x00000000, 0x00000000 } }
+#define SE_PRINT_OPERATOR { { 0x00000020, 0x00000000, 0x00000000, 0x00000000 } }
+#define SE_ADD_USERS { { 0x00000040, 0x00000000, 0x00000000, 0x00000000 } }
#if 0 /* not needed currently */
@@ -113,8 +113,14 @@ typedef struct privilege_set
LUID_ATTR *set;
} PRIVILEGE_SET;
+#define SE_PRIV_MASKSIZE 4
+
+typedef struct {
+ uint32 mask[SE_PRIV_MASKSIZE];
+} SE_PRIV;
+
typedef struct _PRIVS {
- uint32 se_priv;
+ SE_PRIV se_priv;
const char *name;
const char *description;
} PRIVS;
diff --git a/source3/include/smb.h b/source3/include/smb.h
index 1cf5aac0c5..913061014d 100644
--- a/source3/include/smb.h
+++ b/source3/include/smb.h
@@ -302,7 +302,7 @@ typedef struct sid_list {
typedef struct _nt_user_token {
size_t num_sids;
DOM_SID *user_sids;
- PRIVILEGE_SET privileges;
+ SE_PRIV privileges;
} NT_USER_TOKEN;
/*** query a local group, get a list of these: shows who is in that group ***/