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

[Enhancement] Add support authenticate with identityToken when use CredentialProvider #651

Open
ptantanis opened this issue Sep 17, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@ptantanis
Copy link

Hi,

Docker API has 2 ways to authenticate which is user/pass and identity token.

Docker auth document: https://docs.docker.com/engine/api/v1.43/#section/Authentication

When docker cli store identity token in secret store, it will store usename as <token> and store identity token in secret. Currently testcontainer use these value directly, which cause authentication error because of wrong username.

why
This use when pull image from private registry such as azure container registry and github registry

Solution
Check if username is <token>, then authenticate with identity token instead of user/pass.
There is already this feature in testcontainer-dotnet. Implementation in testcontainer-dotnet

I did some POC in this PR ptantanis#1

@cristianrgreco cristianrgreco added the enhancement New feature or request label Oct 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants