diff options
author | Jeremy Allison <jra@samba.org> | 2010-10-22 10:31:06 -0700 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2010-10-22 18:15:48 +0000 |
commit | a8b95686a7bde3f96f141b6938e24e101567ef54 (patch) | |
tree | c5bdfbfc2fb1acb0c211d9941bc0fd321b3a6d9a /source3/rpc_server/srv_spoolss_nt.c | |
parent | 3e79cd6856e5c76cc39ad2be68b40534a524cecd (diff) | |
download | samba-a8b95686a7bde3f96f141b6938e24e101567ef54.tar.gz samba-a8b95686a7bde3f96f141b6938e24e101567ef54.tar.bz2 samba-a8b95686a7bde3f96f141b6938e24e101567ef54.zip |
Wrap security_token_has_privilege() with a check for lp_enable_privileges(). Needed
to maintain compatibility with smb.conf manpage.
Jeremy.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Oct 22 18:15:48 UTC 2010 on sn-devel-104
Diffstat (limited to 'source3/rpc_server/srv_spoolss_nt.c')
-rw-r--r-- | source3/rpc_server/srv_spoolss_nt.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/source3/rpc_server/srv_spoolss_nt.c b/source3/rpc_server/srv_spoolss_nt.c index 62725ee95a..a409a75855 100644 --- a/source3/rpc_server/srv_spoolss_nt.c +++ b/source3/rpc_server/srv_spoolss_nt.c @@ -379,7 +379,7 @@ static WERROR delete_printer_hook(TALLOC_CTX *ctx, struct security_token *token, return WERR_NOMEM; } if ( token ) - is_print_op = security_token_has_privilege(token, SEC_PRIV_PRINT_OPERATOR); + is_print_op = s3_security_token_has_privilege(token, SEC_PRIV_PRINT_OPERATOR); DEBUG(10,("Running [%s]\n", command)); @@ -1790,7 +1790,7 @@ WERROR _spoolss_OpenPrinterEx(struct pipes_struct *p, and not a printer admin, then fail */ if ((p->server_info->utok.uid != sec_initial_uid()) && - !security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && + !s3_security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && !token_contains_name_in_list( uidtoname(p->server_info->utok.uid), p->server_info->info3->base.domain.string, @@ -2033,7 +2033,7 @@ WERROR _spoolss_DeletePrinterDriver(struct pipes_struct *p, and not a printer admin, then fail */ if ( (p->server_info->utok.uid != sec_initial_uid()) - && !security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) + && !s3_security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && !token_contains_name_in_list( uidtoname(p->server_info->utok.uid), p->server_info->info3->base.domain.string, @@ -2138,7 +2138,7 @@ WERROR _spoolss_DeletePrinterDriverEx(struct pipes_struct *p, and not a printer admin, then fail */ if ( (p->server_info->utok.uid != sec_initial_uid()) - && !security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) + && !s3_security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && !token_contains_name_in_list( uidtoname(p->server_info->utok.uid), p->server_info->info3->base.domain.string, @@ -6023,7 +6023,7 @@ static WERROR add_port_hook(TALLOC_CTX *ctx, struct security_token *token, const } if ( token ) - is_print_op = security_token_has_privilege(token, SEC_PRIV_PRINT_OPERATOR); + is_print_op = s3_security_token_has_privilege(token, SEC_PRIV_PRINT_OPERATOR); DEBUG(10,("Running [%s]\n", command)); @@ -6080,7 +6080,7 @@ static bool add_printer_hook(TALLOC_CTX *ctx, struct security_token *token, } if ( token ) - is_print_op = security_token_has_privilege(token, SEC_PRIV_PRINT_OPERATOR); + is_print_op = s3_security_token_has_privilege(token, SEC_PRIV_PRINT_OPERATOR); DEBUG(10,("Running [%s]\n", command)); @@ -8406,7 +8406,7 @@ WERROR _spoolss_AddForm(struct pipes_struct *p, and not a printer admin, then fail */ if ((p->server_info->utok.uid != sec_initial_uid()) && - !security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && + !s3_security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && !token_contains_name_in_list(uidtoname(p->server_info->utok.uid), p->server_info->info3->base.domain.string, NULL, @@ -8474,7 +8474,7 @@ WERROR _spoolss_DeleteForm(struct pipes_struct *p, } if ((p->server_info->utok.uid != sec_initial_uid()) && - !security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && + !s3_security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && !token_contains_name_in_list(uidtoname(p->server_info->utok.uid), p->server_info->info3->base.domain.string, NULL, @@ -8538,7 +8538,7 @@ WERROR _spoolss_SetForm(struct pipes_struct *p, and not a printer admin, then fail */ if ((p->server_info->utok.uid != sec_initial_uid()) && - !security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && + !s3_security_token_has_privilege(p->server_info->ptok, SEC_PRIV_PRINT_OPERATOR) && !token_contains_name_in_list(uidtoname(p->server_info->utok.uid), p->server_info->info3->base.domain.string, NULL, |