Skip to content

fix: treat wildcard IAM actions as sts:AssumeRole - #670

Open
anandhx wants to merge 1 commit into
salesforce:masterfrom
anandhx:fix/wildcard-assume-role-actions
Open

anandhx wants to merge 1 commit into
salesforce:masterfrom
anandhx:fix/wildcard-assume-role-actions

Conversation

@anandhx

@anandhx anandhx commented Nov 7, 2026

Copy link
Copy Markdown

Summary

Trust-policy checks only matched the exact action sts:AssumeRole. A statement with sts:*, sts:AssumeRole*, or * and Principal: * was reported as not assumable.

The four checks now use the same wildcard match IAM uses for those patterns. sts:AssumeRoleWithSAML does not match.

Test plan

  • test/scanning/test_trust_policies.py (6 passed), including wildcard actions for any principal, cross-account, compute services, and the condition variant

Fixes #645

Trust-policy checks only matched the exact action, so sts:*, sts:AssumeRole*, and * with Principal * were reported as not assumable.

Co-authored-by: Cursor <cursoragent@cursor.com>
@salesforce-cla

salesforce-cla Bot commented Nov 7, 2026

Copy link
Copy Markdown

Thanks for the contribution! Before we can merge this, we need @anandhx to sign the Salesforce Inc. Contributor License Agreement.

This branch has not been deployed

No deployments
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.

1 participant