Skip to content

fix(web): API key settings follow-ups (error handling, CSRF origin check, empty scopes label) #79

Closed

Description

@mrgoonie

Follow-up from the independent review of #77 (scoped publishing keys in Settings). All low severity; none block.

  • apps/web/app/routes/api.user-api-keys.ts DELETE with a malformed JSON body returns 500 instead of 400 (POST got the guard).
  • apps/web/app/routes/settings.tsx the create dialog closes before the server responds; on 400/403 the user loses the name and selected publishers.
  • apps/web/app/components/settings/api-keys-table.tsx a key whose stored scopes parse to [] shows an empty Access cell instead of "No access".
  • api.user-api-keys.ts scopes: null returns 400 while docs only describe omitting the field (fails safe; document or accept null as omitted).
  • The route has no Origin/CSRF check and relies on the session cookie's default SameSite=Lax; a sibling subdomain could send cookie-bearing requests. Pre-existing; consider an Origin check on mutating auth routes.
  • settings.tsx after Done the plaintext key stays in the in-memory action result until the next navigation (not re-shown).
  • Separate: the api.skill-favorite client chunk contains the key_hash column name (no data); check that no server-only module is imported client-side there.

Activity

  1. self-assigned this
    on Oct 14, 2026
  2. added and removed on Oct 19, 2026
  3. added a commit that references this issue on Oct 20, 2026
    a55dc0c
  4. mrgoonie commented on Oct 20, 2026

    @mrgoonie
    ContributorAuthor

    Shipped: fixed by #96 (squash fbd0333, merged 2026-10-20 after 6 isolated review rounds). Deployed to production skillx-web (worker version 27d34bce at fbd0333; current 7d29ff0a at 79f98fb). Smoke 2026-10-20: /, /api/search and registry keys 200.

  5. added
    shippedMerged/deployed
    and removed on Oct 20, 2026
  6. added a commit that references this issue on Oct 20, 2026
    fbd0333
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

shippedMerged/deployed

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions