to make Discourse a bit more alive and not bother the mailing list, I start with a question — trying to test the configuration of our XRootD instance in Bonn, I want to fetch a token with a storage.read:/somewhere scope, to then test access. But it seems I can’t get an access token with this scope from the IAM.
As you can see, the scopes claim for storage.read:/ is missing. For reference, specifying something else such as -s wlcg.groups works fine, as shown above.
What am I doing wrong? Am I missing a step in IAM registration?
I can even add additional components to the scope, for example storage.create:/subdir and the token comes back with that.
I do have “token exchange” enabled on my client, but I don’t think oidc-agent uses that. I had to ask the administrator to enable that feature so I could use it from vault.
thanks, then at least it seems I’m not something blatantly wrong in terms of commands. I did now also exclude the more obscure possibilities by trying it out not only with my own build of oidc-agent, but also with the packages from http://repo.data.kit.edu/ on CentOS 7 and CentOS 8 Stream, and results are consistent.
I currently only have the wlcg group in the IAM. Is it possible the storage.read:/ claims are only granted when also requesting wlcg.xfers, or another group?
I have now requested access to wlcg/test (as seems to be used by the JWT Compliance Tests), wlcg/xfers and wlcg/pilots. I would not expect the groups to have an effect on storage.xyz:/ claims, but this is the only idea I could come up with by now.
that did the trick! So it seems the storage.xyz:/ claims are coupled to IAM group memberships. Since I registered with wlcg.test, wlcg.pilots and wlcg.xfers in one go, I don’t know which group did the trick (I’d guess it was wlcg.xfers), but now it works for me like a charm, i.e. I can request storage.read:/ or also storage.read:/somedir and get the scopes into my token.
Interestingly, wlcg.test does not show up in the wlcg.groups array by default. But it seems I can request it with -s wlcg.groups:/wlcg/test now, so that’s probably to be expected (and simplifies tests actually). So now I can continue to find out why our XRootD does not yet grant permissions as expected when storage.xyz:/ claims are present in the token, to get the JWT compliance tests all green.
For those who want to follow along, I now have all JWT Compliance tests against an XRootD redirector setup “green” apart from storage.xyz:/ path authorization tests. Now that I can get an appropriate claim into my tokens, I’ve pinned down the issue:
With this, I’ll mark this thread as resolved and things can continue in the linked issue :-).