Merge pull request #40031 from pritha-srivastava/wip-sts-get-session-ldap

rgw/sts: fixes getsessiontoken authenticated with LDAP,
This commit is contained in:
Harish Munjulur 2021-06-23 07:25:18 -07:00 committed by GitHub
commit 9c25c6c879
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6052,7 +6052,7 @@ rgw::auth::s3::STSEngine::authenticate(
if (token.acct_type == TYPE_KEYSTONE || token.acct_type == TYPE_LDAP) {
auto apl = remote_apl_factory->create_apl_remote(cct, s, get_acl_strategy(),
get_creds_info(token));
return result_t::grant(std::move(apl), completer_factory(boost::none));
return result_t::grant(std::move(apl), completer_factory(token.secret_access_key));
} else if (token.acct_type == TYPE_ROLE) {
auto apl = role_apl_factory->create_apl_role(cct, s, r, user_id, token.policy, token.role_session, token.token_claims, token.issued_at);
return result_t::grant(std::move(apl), completer_factory(token.secret_access_key));