s3-privs Rename structure elements for greater clarity
[Samba/vl.git] / source3 / include / privileges.h
blob0bc085c16620cb62b3e0b45655e51cd625119d88
2 /*
3 Unix SMB/CIFS implementation.
4 SMB parameters and setup
5 Copyright (C) Andrew Tridgell 1992-1997
6 Copyright (C) Luke Kenneth Casson Leighton 1996-1997
7 Copyright (C) Paul Ashton 1997
8 Copyright (C) Simo Sorce 2003
9 Copyright (C) Gerald (Jerry) Carter 2005
10 Copyright (C) Andrew Bartlett 2010
12 This program is free software; you can redistribute it and/or modify
13 it under the terms of the GNU General Public License as published by
14 the Free Software Foundation; either version 3 of the License, or
15 (at your option) any later version.
17 This program is distributed in the hope that it will be useful,
18 but WITHOUT ANY WARRANTY; without even the implied warranty of
19 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 GNU General Public License for more details.
22 You should have received a copy of the GNU General Public License
23 along with this program. If not, see <http://www.gnu.org/licenses/>.
26 #ifndef PRIVILEGES_H
27 #define PRIVILEGES_H
29 #include "../librpc/gen_ndr/lsa.h"
30 #include "../librpc/gen_ndr/security.h"
32 /* privilege bitmask */
34 /* common privilege defines */
36 #define SE_END 0x0
37 #define SE_NONE 0x0
38 #define SE_ALL_PRIVS (uint64_t)-1
41 /* defined in lib/privilegs_basic.c */
43 extern const uint64_t se_priv_all;
45 extern const uint64_t se_priv_none;
46 extern const uint64_t se_machine_account;
47 extern const uint64_t se_print_operator;
48 extern const uint64_t se_add_users;
49 extern const uint64_t se_disk_operators;
50 extern const uint64_t se_remote_shutdown;
51 extern const uint64_t se_restore;
52 extern const uint64_t se_take_ownership;
56 * These are used in Lsa replies (srv_lsa_nt.c)
59 typedef struct {
60 TALLOC_CTX *mem_ctx;
61 bool ext_ctx;
62 uint32 count;
63 uint32 control;
64 struct lsa_LUIDAttribute *set;
65 } PRIVILEGE_SET;
67 typedef struct {
68 uint64_t privilege_mask;
69 const char *name;
70 const char *description;
71 enum sec_privilege luid;
72 } PRIVS;
74 #endif /* PRIVILEGES_H */