Skip to content

rgw/rest: fix url decode of post params for iam/sts/sns - #55329

Merged
cbodley merged 1 commit into
ceph:mainfrom
cbodley:wip-64189
Jan 29, 2024
Merged

cbodley merged 1 commit into
ceph:mainfrom
cbodley:wip-64189

Conversation

@cbodley

@cbodley cbodley commented Jan 26, 2024

Copy link
Copy Markdown
Contributor

add the in_query=true argument to url_decode() to replace '+' with ' '

Fixes: https://tracker.ceph.com/issues/64189

Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox
  • jenkins test windows
  • jenkins test rook e2e

@cbodley
cbodley requested a review from a team as a code owner January 26, 2024 14:56
@github-actions github-actions Bot added the rgw label Jan 26, 2024
@cbodley

cbodley commented Jan 26, 2024

Copy link
Copy Markdown
Contributor Author

@pritha-srivastava @TRYTOBE8TME i noticed this when adding s3test cases for account roles; if the AssumeRolePolicyDocument has any spaces in it, rgw failed with MalformedPolicyDocument because it tried to parse a string like {"Version":+"2012-10-17",+"Statement":+...

the existing role tests pass because they all send policies without any spaces:

policy_document = "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Effect\":\"Allow\",\"Principal\":{\"AWS\":[\"arn:aws:iam:::user/"+sts_user_id+"\"]},\"Action\":[\"sts:AssumeRole\"]}]}"

@cbodley

cbodley commented Jan 28, 2024

Copy link
Copy Markdown
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants