From 84a91c108455cb256639ff50f95606b3c1009b27 Mon Sep 17 00:00:00 2001 From: yuliyang Date: Sat, 22 Jun 2019 14:58:31 +0800 Subject: [PATCH] rgw, Policy should be url_decode when assume_role Signed-off-by: yuliyang (cherry picked from commit ba5caffb1c3b406934992dcaa70da882d4d99b13) --- src/rgw/rgw_rest_sts.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rgw/rgw_rest_sts.cc b/src/rgw/rgw_rest_sts.cc index 072ee9c25c59..3791ef0f1ade 100644 --- a/src/rgw/rgw_rest_sts.cc +++ b/src/rgw/rgw_rest_sts.cc @@ -362,7 +362,7 @@ void RGWHandler_REST_STS::rgw_sts_parse_input() if (pos != string::npos) { std::string key = t.substr(0, pos); std::string value = t.substr(pos + 1, t.size() - 1); - if (key == "RoleArn") { + if (key == "RoleArn" || key == "Policy") { value = url_decode(value); } ldout(s->cct, 10) << "Key: " << key << "Value: " << value << dendl; -- 2.47.3