Fix/legacy api key auth v2#2077
Conversation
|
@Bhavy12-cell is attempting to deploy a commit to the PRIYANSHU DOSHI's projects Team on Vercel. A member of the Team first needs to authorize it. |
GSSoC Label Checklist 🏷️@Priyanshu-byte-coder — please apply the appropriate labels before merging: Difficulty (pick one):
Quality (optional):
Validation (required to score):
|
|
This PR has conflicts with main. Please rebase on main and resolve conflicts, then we can review. |
|
Rebased on latest main and force-pushed. No conflicts remaining. Ready for review! |
|
This PR has merge conflicts with git fetch origin
git rebase origin/main |
|
Hi @Priyanshu-byte-coder! |
Closes #1635
Fixed legacy API key authentication failure after hash migration.
Root cause:
authenticateApiKey() compared hash against api_key column for legacy
rows, but legacy rows contain plaintext — so the comparison always failed.
Fix:
(where api_key_hash IS NULL)
last_used_at in one update