1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-12 09:18:10 +03:00

smbd: enable unit-testing of NT_TRANSACT_GET_USER_QUOTA

Processing of NT_TRANSACT_GET_USER_QUOTA involves a security check to
see the user is an admin, allow this check to run in unit-testing mode.

Signed-off-by: Uri Simchoni <uri@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
This commit is contained in:
Uri Simchoni 2016-01-09 21:24:10 +02:00 committed by Michael Adam
parent 17c9b8d2d0
commit 345f0849de

View File

@ -2310,7 +2310,7 @@ static void call_nt_transact_get_user_quota(connection_struct *conn,
ZERO_STRUCT(qt);
/* access check */
if (get_current_uid(conn) != 0) {
if (get_current_uid(conn) != sec_initial_uid()) {
DEBUG(1,("get_user_quota: access_denied service [%s] user "
"[%s]\n", lp_servicename(talloc_tos(), SNUM(conn)),
conn->session_info->unix_info->unix_name));