Skip to content

Wildcard global scopes#36

Merged
cavis merged 4 commits intomasterfrom
fix/wildcard_global_scopes
Mar 19, 2025
Merged

Wildcard global scopes#36
cavis merged 4 commits intomasterfrom
fix/wildcard_global_scopes

Conversation

@cavis
Copy link
Member

@cavis cavis commented Mar 19, 2025

Hit an issue in ID, when requesting a wildcard token for just feeder:* scopes.

The ResourceMap & operator was dropping some scopes:

m1 = PrxAuth::ResourceMap.new("*" => "read-private feeder:read-private")
m2 = PrxAuth::ResourceMap.new("*" => "feeder:read-private")

# before, it was dropping the global read-private entirely!
(m1 & m2).as_json
{}

# after this PR, it correctly intersects them
(m1 & m2).as_json
{"*" => "feeder:read-private"}

@cavis cavis merged commit 58e41cb into master Mar 19, 2025
1 check passed
@cavis cavis deleted the fix/wildcard_global_scopes branch March 19, 2025 17:28
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.

1 participant