summaryrefslogtreecommitdiff
path: root/libcli/security
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2010-08-27 11:52:51 +1000
committerAndrew Bartlett <abartlet@samba.org>2010-09-11 18:46:08 +1000
commitd2e41105e2caab83251d54c3fde72971038dd5df (patch)
tree3e6f1ee0ab41884b3d736bd2cc3132d4f384de56 /libcli/security
parenteb8e3155dee3e4258a603da61a9e7822503cd8dd (diff)
downloadsamba-d2e41105e2caab83251d54c3fde72971038dd5df.tar.gz
samba-d2e41105e2caab83251d54c3fde72971038dd5df.tar.bz2
samba-d2e41105e2caab83251d54c3fde72971038dd5df.zip
libcli/security Return number of entries in the old source3 list
This ensures there isn't a behaviour change when the source3 list is combined with the longer source4 list. Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
Diffstat (limited to 'libcli/security')
-rw-r--r--libcli/security/privileges.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/libcli/security/privileges.c b/libcli/security/privileges.c
index 4815d1837c..bf623e0ad6 100644
--- a/libcli/security/privileges.c
+++ b/libcli/security/privileges.c
@@ -53,6 +53,8 @@ const uint64_t se_remote_shutdown = SE_REMOTE_SHUTDOWN;
const uint64_t se_restore = SE_RESTORE;
const uint64_t se_take_ownership = SE_TAKE_OWNERSHIP;
+#define NUM_SHORT_LIST_PRIVS 8
+
PRIVS privs[] = {
#if 0 /* usrmgr will display these twice if you include them. We don't
use them but we'll keep the bitmasks reserved in privileges.h anyways */
@@ -304,12 +306,11 @@ bool user_has_any_privilege(struct security_token *token, const uint64_t *privil
return the number of elements in the privlege array
*******************************************************************/
-int count_all_privileges( void )
+int num_privileges_in_short_list( void )
{
- return ARRAY_SIZE(privs);
+ return NUM_SHORT_LIST_PRIVS;
}
-
/*********************************************************************
Generate the struct lsa_LUIDAttribute structure based on a bitmask
The assumption here is that the privilege has already been validated