Skip to content

chore(apps): gate the app UI dev preview at build time and contain installer URLs #665

Backlog

Description

@RentnerKev

Defense in depth; neither item is reachable in a default production image.

Dev preview

  • The server gate is a runtime NODE_ENV check (web/src/server.ts:22, web/src/server/AppRuntime/ui/dev-preview.server.ts:52-54), while the route uses import.meta.env.DEV (web/src/routes/_authenticated/dev.app-ui.tsx:10). Production forces NODE_ENV=production (docker/production/Dockerfile:200, docker/production/entrypoint.sh:511) and the preview also needs APP_UI_DEV_DIR.
  • Only call and index.html require the Owner (dev-preview.server.ts:205-206); other files in the preview directory are served without authentication.
  • Proposal: gate with import.meta.env.DEV so production builds drop the code, and require the Owner for every preview file.

Installer transport

  • metadata() joins paths onto the catalog root without a containment check (core/src/app_install/transport.rs:125-129). archive() checks redirect targets but not the initial asset URL (:107-114, :194-208). There is no private-address block. Both clients are HTTPS-only, and URLs come from signed metadata.
  • Proposal: require joined metadata URLs to stay under the catalog root, apply the redirect allowlist to the initial archive URL, and refuse private and loopback addresses.

Found in the app platform audit of 2026-11-30.

Activity

  1. added
    enhancement
    security
    area: runtime
    on Nov 30, 2026
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

    area: runtimeenhancementsecurity

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions