-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
ODIC + CLI Secret mismatch #20822
Comments
Is your OIDC server just a proxy? and does it proxy the request to a backend OIDC server? |
It's a full OIDC + OAuth 2 server, I don't believe there is a proxy as it's OAuth! |
@stonezdj is it possible that this is an issue with the headers from the request not being set on response / being stripped? Not sure what the 401 error would be coming from since it doesn't show up as a log in the core. |
This error message indicate that the input secret is different with the secret stored in the database.
code: Lines 103 to 105 in ebac530
|
Is there any special character in your secret? |
@stonezdj I tried no special characters in the secrets, no change. I do notice a strange pattern tho. There is a difference between the errors. This is the output in the CLI when the correct password/token is entered but it fails:
This is the output when the incorrect password is entered:
It looks different, which makes me think that maybe it is something else that is floating up an exception. These are the logs in the NGINX node when the password is correct:
And when the password is incorrect:
Along with an entry in the
Based on this, looks like it's succeeding to hit the auth endpoint but 401's on |
@stonezdj So reading through the docs, I have the ingress set up properly, so I don't think that's an issue. If you route the This would explain why the login request resulted in a failure, as the user is logged in and the credentials have been found correct. So this is not a credentials issue but rather an issue on the backend with This issue appears to be very similar, but has been closed without resolution. #11935 |
Please check if there is any |
@stonezdj I checked the key path, all are set to the default. All keys are configured from the values chart as provided here: https://github.com/goharbor/harbor-helm/blob/main/values.yaml and are pulled from secrets. I deleted everything, re-created, tested it without OIDC too just to check. Everything is fresh but the issue persists. What is the KEY_PATH for the helm chart? I don't see any option in either the helm chart and no config is set for this in the config of the |
If Looks like this is the error during the OAuth process:
|
@stonezdj is there anything else I should check? :) I looked into the ingress to be sure that the headers were being passed along, tested this with both |
@Nathan-Nesbitt Did you get anywhere with this? I'm running into this exact same issue and I'm having no luck. |
This issue is being marked stale due to a period of inactivity. If this issue is still relevant, please comment or remove the stale label. Otherwise, this issue will close in 30 days. |
Not stale |
I am facing the same issue you describe @Nathan-Nesbitt. I'm seeing the same differences between the error messages when the username / password are wrong in Actually I just read goharbor/harbor-helm#1830 . Interestingly after removing the |
This is a continuation of #20729 as I cannot reopen it 😄
I am trying to log into Harbor via CLI using the username + CLI secret. I am using the username for the user and the CLI secret as found here:
I have followed these instructions: https://goharbor.io/docs/2.10.0/administration/configure-authentication/oidc-auth/
But I continue to get the following error when I attempt to log in:
Along with the logs on the server:
I know that the username is correct, as changing the username to anything else and looking at the logs the error changes to
Is there any advice on how to debug this? Where does the secret validation happen? Is there another secret that I should be using?
Thanks in advance!
The text was updated successfully, but these errors were encountered: