Skip to content

[tracking] frontend low-severity hygiene #70

Description

@tkowalczyk

Grouped low-severity findings in apps/user-application.

  1. parseAcceptLanguage ignores RFC q=0 and uppercase Q=lib/parse-accept-language.ts:14-23. en;q=0 returns "en" (should be default); pl;Q=0.2,en;q=0.9 returns "pl". Tests: both cases.
  2. Turnstile test-sitekey fallback masks prod misconfigroutes/index.tsx:13,47-48. Missing VITE_TURNSTILE_SITE_KEY in a prod build silently renders the always-pass test widget; siteverify response hostname is unchecked (stage tokens valid for prod). Test: loader throws when key missing in PROD.
  3. checkSession/requireSession return the full session (incl. session.token) over the wirecore/functions/session.ts:10-33. JS-readable; an XSS gains a token it could not otherwise read. Return {user} only.
  4. Theme anti-FOUC script runs in useEffect (post-hydration)components/.../theme-provider.tsx:147-173. Cannot prevent the dark-mode flash; emit it in <head> via the root head().
  5. detectInitialLanguage is called per client navigation__root.tsx:22-25. An HTTP round trip each navigation for a value that cannot change mid-session.
  6. Stale detail-key cache invalidationcomponents/sources/source-form.tsx:232-238. Update invalidates ["notification-sources"] but not ["notification-source", id]; re-entering Edit within the preload window shows pre-edit data.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    audit/2026-06Filed from June 2026 deep auditseverity/lowHygiene / latent risk

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions