Commit 6f2c6b8e authored by Philipp Schafft's avatar Philipp Schafft 🦁

Fix: Use ADMIN_COMMAND_ERROR not -1

parent 0af45ebf
Pipeline #302 failed with stage
in 13 seconds
......@@ -1348,7 +1348,7 @@ static void _handle_authentication_global(client_t *client, void *uri, auth_resu
client->authstack = NULL;
if (result != AUTH_NOMATCH &&
!(result == AUTH_OK && client->admin_command != -1 && acl_test_admin(client->acl, client->admin_command) == ACL_POLICY_DENY)) {
!(result == AUTH_OK && client->admin_command != ADMIN_COMMAND_ERROR && acl_test_admin(client->acl, client->admin_command) == ACL_POLICY_DENY)) {
_handle_authed_client(client, uri, result);
return;
}
......@@ -1402,7 +1402,7 @@ static void _handle_authentication_mount_default(client_t *client, void *uri, au
client->authstack = NULL;
if (result != AUTH_NOMATCH &&
!(result == AUTH_OK && client->admin_command != -1 && acl_test_admin(client->acl, client->admin_command) == ACL_POLICY_DENY)) {
!(result == AUTH_OK && client->admin_command != ADMIN_COMMAND_ERROR && acl_test_admin(client->acl, client->admin_command) == ACL_POLICY_DENY)) {
_handle_authed_client(client, uri, result);
return;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment