-
Notifications
You must be signed in to change notification settings - Fork 39
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
Token Auth Backend: Token request function didn`t set Authorization Header #153
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Signed-off-by: Marius Bertram <[email protected]>
Signed-off-by: Marius Bertram <[email protected]>
Signed-off-by: Marius Bertram <[email protected]>
Signed-off-by: Marius Bertram <[email protected]>
vsoch
requested changes
Sep 6, 2024
Signed-off-by: Marius Bertram <[email protected]>
vsoch
reviewed
Sep 6, 2024
Signed-off-by: Marius Bertram <[email protected]>
vsoch
approved these changes
Sep 6, 2024
tarilabs
added a commit
to tarilabs/oras-py
that referenced
this pull request
Sep 23, 2024
…ect#153 this was taken care in oras-project#153 This reverts commit 10e010b.
tarilabs
added a commit
to tarilabs/oras-py
that referenced
this pull request
Sep 23, 2024
…ect#153 this was taken care in oras-project#153 This reverts commit 10e010b. Signed-off-by: tarilabs <[email protected]>
vsoch
pushed a commit
that referenced
this pull request
Sep 24, 2024
* core: TokenAuth request_token fix missing auth the method is intended to request authenticated token, per pydocs, but was passing an headers which was always missing Authorization. * core: use token in auth in subsequent requests if a token was saved in auth, it shall be used in subsequent requests. This avoid a situation where: to upload a blob, first is done anonymously, then retry with token then upload a manifest, avoid the attempt to upload anonymously if a token was present in the previous flow * core: if 401 on 2nd attempt, avoid anon tokens in the first flow using auth backend for token: 1. try do_request with no auths at all 2. the attempt to gain an anon token is success, but then the request fails with 401 3. at this point, in the third attempt, give chance to the flow to request a token but avoid any anon tokens. Please note: this happens effectively only on the first run of the flow. Subsequent do_request flow invocations should just succeed now on the 1st request by re-using the token --simplified behaviour introduced with this proposal * guard as headers is Optional * implement review request * Revert "implement review request" This reverts commit 102381c. This reverts commit 1e891d2. This reverts commit 6e22667. this was taken care in #153 This reverts commit 10e010b. * implement review comment about anon/req token from: #148 (comment) > And if the basic auth is there, skip over asking for an anon token as it stands, in case the basic auth are present, these are exchanged for the request token. Signed-off-by: tarilabs <[email protected]> --------- Signed-off-by: tarilabs <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In the Token Auth Backend the functin request_token were missing the Authorization Header which failed in not receiving a Bearer Token.