fix(local-auth): persist apps row for /local/generate_uri#382
Open
DevDesai444 wants to merge 1 commit intomorphik-org:mainfrom
Open
fix(local-auth): persist apps row for /local/generate_uri#382DevDesai444 wants to merge 1 commit intomorphik-org:mainfrom
DevDesai444 wants to merge 1 commit intomorphik-org:mainfrom
Conversation
- persist app record before returning URI so auth can validate app_id\n- store UUID-safe user_id plus created_by_user_id for non-UUID local names\n- mark generated local app token as active in redis cache\n- add unit tests for local app record persistence\n\nRefs: morphik-org#380
|
I reviewed this against the current This looks correct:
This should resolve #380 because Nice fix! |
|
Just a note: the root cause analysis and fix for this issue were already provided in #380 by me (@Tyrannius). It would be appreciated if that contribution is acknowledged. |
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.
Summary
appstable row in/local/generate_uribefore returning a URIcreated_by_user_idwhile keepingapps.user_idUUID-safeWhy
/local/generate_urigenerated JWTs but did not persist matchingappsrows, causing auth middleware to reject tokens as invalid/revoked.Closes #380
Issue: #380