Skip to content

fix(crypto): reject blank public key user ids - #168

Closed
aiirvizionz wants to merge 1 commit into
profullstack:masterfrom
aiirvizionz:clientkit/public-key-user-id-trim
Closed

fix(crypto): reject blank public key user ids#168
aiirvizionz wants to merge 1 commit into
profullstack:masterfrom
aiirvizionz:clientkit/public-key-user-id-trim

Conversation

@aiirvizionz

Copy link
Copy Markdown
Contributor

Summary

  • Normalize the public-key user_id query parameter before validation.
  • Return the existing missing-parameter 400 response for whitespace-only ids instead of doing a target lookup.
  • Add regression coverage to ensure blank ids do not call the public-key RPC.

Validation

  • git diff --check
  • node node_modules\vitest\vitest.mjs run --config %TEMP%\qryptchat-vitest-minimal.config.mjs "src/app/api/crypto/public-keys/route.test.js" (2 tests passed)

I used the same temporary minimal Vitest config needed locally because the repo's default Vitest config currently fails to load through the installed Vite/plugin combination; no dependency files were modified.

@ralyodio ralyodio closed this Jul 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants