Skip to content

Backport/squid 19.2.6 cobaltcore storage/keystone iam policy - #16

Merged
uw-sc merged 4 commits into
squid-19.2.6-cobaltcore-storagefrom
backport/squid-19.2.6-cobaltcore-storage/keystone-iam-policy
Sep 24, 2026
Merged

uw-sc merged 4 commits into
squid-19.2.6-cobaltcore-storagefrom
backport/squid-19.2.6-cobaltcore-storage/keystone-iam-policy

Conversation

@supriti

@supriti supriti commented Sep 23, 2026

Copy link
Copy Markdown

Closes cobaltcore-dev/cloud-storage#466
Closes cobaltcore-dev/cloud-storage#467

Backport file

  • release-management/backports/<uuid>.md added (or updated) by this PR
  • id in frontmatter matches the filename stem
  • provenance.upstream_prs set (or provenance.type: other with an other: block)

Stage-B risk (filled per release-management/backports/RISK-RUBRIC.md)

  • blast — cosmetic
  • conflict — substantive
  • coverage — partial
  • Risk-notes paragraph in the prose section (required for high band)

Merge

Land this via just merge-backport PR=<N> — do not click the green merge button.
The just recipe constructs the merge commit's Backport-Id trailer.

@uw-sc uw-sc left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please

  • add the Backport ticket number in the PR description. might be 466 or 467 (both reference the same upstream pr)
  • rebase onto squid-19.2.6-cobaltcore-storage to get the tests runnning.

thank you

Keystone roles are injected into the IAM policy evaluation
environment as "keystone:role" condition keys. This enables
bucket policies to grant or deny access based on Keystone roles.
It bridges the gap between Openstack RBAC and S3 IAM policy.

Document keystone:role in bukcet policy and Keystone S3
integration

Signed-off-by: Supriti Singh <supriti.singh@clyso.com>
Signed-off-by: Marcel Lauhoff <marcel.lauhoff@clyso.com>
On-behalf-of: SAP <supriti.singh@clyso.com>
On-behalf-of: SAP <marcel.lauhoff@sap.com>
(cherry picked from commit 1e6e393)
Expose the Keystone token user UUID as condition key "keystone:userid"
so IAM and bucket policies can restrict access by user (e.g. per-user
buckets or user-specific allow/deny).

On-behalf-of: SAP <supriti.singh@clyso.com>
Signed-off-by: Supriti Singh <supriti.singh@clyso.com>
(cherry picked from commit b06b7a8)
Signed-off-by: Supriti Singh <supriti.singh@clyso.com>
@supriti
supriti force-pushed the backport/squid-19.2.6-cobaltcore-storage/keystone-iam-policy branch from a46fad6 to 998123c Compare September 24, 2026 08:13
@supriti
supriti requested review from uw-sc and a lite review from Copilot September 24, 2026 08:14

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Keystone documentation presents an unsafe NotEquals use case, and additional documentation and naming corrections remain.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 1 Medium severity · 2 Low severity

Open (3)
What changed in this PR

This backport adds Keystone role and user-ID condition support to RGW IAM policies, with tests, documentation, and provenance metadata.

Changes:

  • Propagates Keystone identity attributes through authentication and policy evaluation.
  • Adds IAM condition tests.
  • Documents supported condition keys and backport limitations.
File Summary
src/​test/​rgw/​test_rgw_iam_policy.cc Adds Keystone IAM condition tests.
src/​rgw/​rgw_auth.h Stores Keystone identity data.
src/​rgw/​rgw_auth.cc Injects identity data into policy environments.
src/​rgw/​rgw_auth_keystone.cc Extracts roles and user IDs from tokens.
release-management/​backports/​01a0cdb3-3f84-74ab-9403-c7638a039697.md Records backport provenance and limitations.
doc/​radosgw/​keystone.rst Documents Keystone condition keys and usage.
doc/​radosgw/​bucketpolicy.rst Lists supported condition keys.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread doc/radosgw/keystone.rst Outdated
Comment thread doc/radosgw/keystone.rst Outdated
Comment thread src/test/rgw/test_rgw_iam_policy.cc
Upstream fixed the NotEquals operators in 225241d (ceph#65606),
which is not on squid. Without it they return wrong results when
keystone:role holds several values, which is the normal case.

That fix is not included here: it changes evaluation of every condition
key, so it needs its own backport and review. The upstream squid
backport is ceph#67213. Until one of those lands, document
StringEquals only and warn against the NotEquals variants.

Signed-off-by: Supriti Singh <supriti.singh@clyso.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Moderate spelling/consistency findings and a documentation grammar nit remain unresolved.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 3 Low severity

Open (3)
Resolved since last review (1)

Comment thread doc/radosgw/bucketpolicy.rst
@uw-sc
uw-sc merged commit 76c8948 into squid-19.2.6-cobaltcore-storage Sep 24, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants