Repository navigation
[18.0][FIX] auth_api_key: revoke keys immediately and do not leak them in errors - #1086
Merged
OCA-git-bot merged 1 commit intoDec 1, 2026
Merged
Conversation
…rrors * Clear the key cache on unlink and when a key is (un)archived, so a deleted or archived key stops working right away instead of when the cache happens to be cleared. * The error for an unknown key no longer contains the submitted key (it ended up in logs and error pages) and the message is translatable. * An unknown key now answers 401, like a missing one, instead of a user error, and the failure log reports the caller address.
This was referenced Dec 1, 2026
ivantodorovich
approved these changes
Dec 1, 2026
henrybackman
approved these changes
Dec 1, 2026
Contributor
Author
|
/ocabot merge patch |
Contributor
|
Hey, thanks for contributing! Proceeding to merge this for you. |
Contributor
|
Congratulations, your PR was merged at dc31a0c. Thanks a lot for contributing to OCA. ❤️ |
This file contains hidden or 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
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.
Hardening of
auth_api_key, first of three independent-in-scope steps.key/user_id). The cache is now also cleared on unlink and when a key is (un)archived._()).ValidationErrorout of the auth method instead of answering 401 like a missing key. It now answers 401 and the log reports the caller address (not the key).