Skip to content

v1.0.2

Latest

Choose a tag to compare

@morsymohtech morsymohtech released this 01 Dec 10:31
· 10 commits to main since this release
cb9d799

[1.0.2] - 2026-12-01

Security release. No database schema changes. Check these before upgrading from 1.0.1:

  • Evidence encryption key: production now refuses to start with an
    EVIDENCE_ENCRYPTION_KEY shorter than 32 characters. If yours is shorter, set the old key as
    EVIDENCE_ENCRYPTION_KEY_PREVIOUS and a new 32+ character key as EVIDENCE_ENCRYPTION_KEY
    (see docs/deployment/docker.md, "Rotate the encryption key").
  • Cookie sessions: clients that authenticate with the session cookie alone
    (AUTH_SET_COOKIES=true, no Authorization header) must send X-CSRF-Token on
    state-changing requests. The console is unaffected.
  • CORS: the default allowed origin is http://localhost:3000 instead of *. Deployments
    that relied on the default must set CORS_ALLOWED_ORIGINS (production already required it).

Security

  • The backend image runs Python 3.13 (python:3.13-slim) instead of 3.12, which includes
    the fix for CVE-2025-13836 in the interpreter. It also no longer ships the base image's
    pip, whose bundled msgpack, urllib3 and setuptools were reported by image scans.
    The app runs from the uv-managed /app/.venv and never used it.
  • Upgraded mako to 1.4.3 (CVE-2026-102991).
  • cross-spawn 7.0.6 -> 7.1.2 in UI lint tooling (GHSA-ghv9-86vm-4v8m, critical; dev only,
    through ESLint).
  • OIDC verification refuses identity-provider keys weaker than RSA 2048 bits or EC P-256.
    PyJWT alone accepted them.
  • Production startup refuses an evidence encryption key shorter than 32 characters (was a
    warning). Upgrade note: if your key is shorter, set the old key as
    EVIDENCE_ENCRYPTION_KEY_PREVIOUS and a new 32+ character key as EVIDENCE_ENCRYPTION_KEY,
    so stored webhook secrets stay readable (docs/deployment/docker.md, "Rotate the encryption
    key"). CSRF tokens carry a 128-bit HMAC tag instead of 64 bits.
  • Cookie-authenticated requests that change state must carry the CSRF token
    (X-CSRF-Token matching the rai_csrf cookie). The check was defined but never applied, so
    these requests were protected only by SameSite=Lax. An Authorization header now takes
    precedence over the session cookie and, when present, is the only credential considered;
    the refresh endpoint prefers a refresh token in the request body over the cookie. The
    console, which sends both, is unaffected.
  • The default CORS origin is the local console (http://localhost:3000) instead of *.
  • Content-evaluator endpoints must be http or https.
  • Assistant API errors return fixed messages (CodeQL py/stack-trace-exposure); invalid
    actions are logged as an event without the caller-supplied text.
  • The example Nginx configuration allows only TLS 1.2/1.3 with (EC)DHE key exchange, so every
    connection has forward secrecy, and sets HSTS.

Fixed

  • Semgrep was not scanning: the pinned semgrep-action crashed on the current rules without
    failing CI. CI now runs a pinned Semgrep CLI that fails on any finding (on pull requests, on
    findings the pull request introduces); the 20 findings it reported were fixed or triaged (see
    docs/security/SECURITY_ASSURANCE.md).
  • Running Alembic migrations in-process no longer disables the application's existing loggers.

Added

  • docs/security/SECURITY_ASSURANCE.md: secure design principles, vulnerability classes and
    mitigations, cryptography and TLS, and the vulnerability and static-analysis records.

Changed

  • CI tests the backend on Python 3.12 (the minimum supported) and 3.13 (what the image
    runs), and reports branch coverage. CodeQL also runs daily.
  • Dependabot waits 7 days before proposing a new version (security updates are not delayed).