Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DM-42626: Document the special CADC route #24

Merged
merged 1 commit into from
Feb 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .gitattributes

This file was deleted.

13 changes: 13 additions & 0 deletions index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -754,6 +754,19 @@ The Portal Aspect wants several scopes for its delegated token so that it can pe
It therefore takes advantage of Gafaelfawr's support for requesting delegated scopes that may or may not be available.
If the user's authenticating token has the scopes it prefers, it gets an internal token with those scopes; otherwise, it gets an internal token with whatever subset of the scopes the user has, but the authentication still succeeds as long as the user has ``exec:portal`` access (the scope used to control all access to the Portal Aspect).

CADC services
-------------

IVOA services maintained by the Canadian Astronomy Data Center (CADC) use a standard authentication system that presents a token to a user information endpoint and expects a JSON object of OpenID Connect claims in response.
The username of the authenticated user is retrieved from the ``preferred_username`` key.

This poses two challenges: this format does not match the normal format of the Gafaelfawr userinfo endpoint, which uses a ``username`` key rather than the OpenID Connect ``preferred_username`` claim name; and the current implementation of that shared authentication code requires that the ``sub`` key hold a UUID.

Currently, Gafaelfawr provides a separate endpoint specifically for CADC software (``/auth/cadc/userinfo``) that returns user metadata in the expected format.
The ``sub`` value returned by that endpoint is set to a v5 UUID derived from a namespace (which is a random v4 UUID per Science Platform deployment) and the numeric UID of the user.

Hopefully in the future the CADC requirement for a UUID will be relaxed and some of the pecularities of this implementation can be retired.

Storage
=======

Expand Down
Loading