From 226227cf2d825b3414b7522a9f738180142f3956 Mon Sep 17 00:00:00 2001 From: Matt Benjamin Date: Wed, 11 Sep 2019 13:22:26 -0400 Subject: [PATCH] rgw: ldap auth: S3 auth failure should return InvalidAccessKeyId LDAP was out of sync with the other auth modules, and the default error code is not correct for S3. Fixes: https://tracker.ceph.com/issues/41760 Signed-off-by: Matt Benjamin --- src/rgw/rgw_rest_s3.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rgw/rgw_rest_s3.cc b/src/rgw/rgw_rest_s3.cc index 917a6a399b450..b4b7554df35e4 100644 --- a/src/rgw/rgw_rest_s3.cc +++ b/src/rgw/rgw_rest_s3.cc @@ -4926,7 +4926,7 @@ rgw::auth::s3::LDAPEngine::authenticate( }*/ if (ldh->auth(base64_token.id, base64_token.key) != 0) { - return result_t::deny(); + return result_t::deny(-ERR_INVALID_ACCESS_KEY); } auto apl = apl_factory->create_apl_remote(cct, s, get_acl_strategy(), -- 2.39.5