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

fix: allow BASIC authentication (all caps) #3471

Merged
merged 1 commit into from Aug 10, 2023

Conversation

cdrage
Copy link
Contributor

@cdrage cdrage commented Aug 9, 2023

fix: allow BASIC authentication (all caps)

What does this PR do?

Allows registries that have BASIC in the header instead of Basic to be
extractable using the extractAuthData function.

Screenshot/screencast of this PR

What issues does this PR fix or reference?

Closes #3470

How to test this PR?

BEFORE TESTING:

Patch in #3468 to remove the invalid The format of the Registry Location is incorrect. Or remove the line https://github.com/containers/podman-desktop/pull/3468/files#diff-18bc4f2318c7a0814b55328a4186d337972e6bcdd4c09b33d9b9353c47c2c5ffL713 before running.

  1. Deploy a Sonatype Nexus registry using:
    podman run -d -p 8081:8081 -p 8082:8082 -p 443:443 --name nexus sonatype/nexus3 and setup an accesible docker registry
  2. OR run a fake registry using this python script: https://gist.github.com/cdrage/07220d49e99ed54e0f5f0e3e6ab74758
  3. Add the registry (example: localhost:8000)
  4. You should now receive a timeout / authentication error rather than
    "Invalid URL"

Signed-off-by: Charlie Drage charlie@charliedrage.com

### What does this PR do?

Allows registries that have BASIC in the header instead of Basic to be
extractable using the extractAuthData function.

### Screenshot/screencast of this PR

<!-- Please include a screenshot or a screencast
explaining what is doing this PR -->

### What issues does this PR fix or reference?

<!-- Include any related issues from Podman Desktop
repository (or from another issue tracker). -->

Closes containers#3470

### How to test this PR?

1. Deploy a Sonatype Nexus registry using:
`podman run -d -p 8081:8081 -p 8082:8082 -p 443:443 --name nexus sonatype/nexus3` and setup an accesible docker registry
2. OR run a fake registry using this python script: https://gist.github.com/cdrage/07220d49e99ed54e0f5f0e3e6ab74758
3. Add the registry (example: localhost:8000)
4. You should now receive a timeout / authentication error rather than
   "Invalid URL"

<!-- Please explain steps to reproduce -->

Signed-off-by: Charlie Drage <charlie@charliedrage.com>
@cdrage cdrage requested review from benoitf and a team as code owners August 9, 2023 16:50
@cdrage cdrage requested review from dgolovin and jeffmaury and removed request for a team August 9, 2023 16:50
Copy link
Collaborator

@benoitf benoitf left a comment

Choose a reason for hiding this comment

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

image didn't started with 4GB or memory and 4CPus
I think emulation of amd64 image on arm64 failed
I switched to klo2k/nexus3 image

@cdrage cdrage merged commit 6788c3d into containers:main Aug 10, 2023
8 checks passed
@podman-desktop-bot podman-desktop-bot added this to the 1.3.0 milestone Aug 10, 2023
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.

Allow BASIC (all caps) authentication
3 participants