8000 Load libtrust KeyIDs from token certificate bundle by brandond · Pull Request #4521 · distribution/distribution · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Load libtrust KeyIDs from token certificate bundle #4521

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

brandond
Copy link
@brandond brandond commented Dec 3, 2024

Resolves issue where legacy Key IDs were not loaded from CA bundles, necessitating use of JWKS JSON

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
Copy link
Member < 8000 /span>
@milosgajdos milosgajdos left a comment

Choose a reason for hiding this comment

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

Note that what you see on the main branch and what is going to become v3 i.e. the new major release, is not guaranteed to be compatible with v2 release.

I mention this because we deprecated libtrust module due to its no longer being maintained (its been archived for over 3 years now) and in general not being any established standard per see - if you believe libtrust is a standard, please refer us to some RFC.

I mention this because your PR pulls in some code which seems to attempt to re-establish b/w compatibility with libtrust which was explicitly removed due to its not being standardised, so this PR might not be considered to be merged in.

Copy link
Member
@milosgajdos milosgajdos left a comment

Choose a reason for hiding this comment

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

Marking as request changes as I've accidentally approved

@milosgajdos milosgajdos dismissed their stale review December 3, 2024 11:59

accidentally marked as approved

@brandond
Copy link
Author
brandond commented Dec 3, 2024

we deprecated libtrust module due to its no longer being maintained

I understand not wanting to keep libtrust code around.

if you believe libtrust is a standard, please refer us to some RFC.

I will refer you to this project's own docs and comments, where this key id format is demonstrated as required:

The maintainers of this project INTENTIONALLY chose to only support libtrust key IDs for years. Now you're executing a rug pull and intentionally breaking compatibility.

Unconditionally dropping support for the libtrust KeyID format - which was required for the last decade if you wanted your auth token provider to interoperate with the distribution registry - seems like a huge negative from a migration perspective. There are already two issues and a discussion thread about it, and barely anyone is using v3 yet. What is the harm in continuing to support this?

If you don't do this, you're going to get a LOT of folks wondering why their auth providers break when switching to distribution/v3. The only workarounds at the moment are to do one of:

  • upgrade your auth provider to one that uses RFC7638 compliant Key IDs - which will break interop with distribution/v2
  • generate and configure a JWKS key list file that uses the legacy keyid format - which there is not proper tooling to support

Neither of those are documented anywhere so its left as an unpleasant surprise for folks making the switch.

Note that what you see on the main branch and what is going to become v3 i.e. the new major release, is not guaranteed to be compatible with v2 release.

Note that many folks have a common/shared auth provider that cannot easily be replaced with one that does not generate backwards compatible tokens, just to satisfy this projects desire to make a clean break from the past.

https://lawsofux.com/postels-law/

Postel’s Law
Be liberal in what you accept, and conservative in what you send.

@brandond
Copy link
Author
brandond commented Dec 3, 2024

cc also @Jamstah who I see participated in the discussion on #4471

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.

2 participants
@brandond @milosgajdos
0