Skip to content

Support configurable trusted setup/control UI origins for remote access #232

Description

@jamesachurchill

Summary

ClawBox should provide a supported way to add operator-approved remote setup/control UI origins, such as VPN or MagicDNS hostnames, without hard-coding local hostnames in generated gateway config.

Problem

The setup/control UI needs a strict allowed-origin boundary, but real deployments may legitimately access the device through more than the default LAN names/IPs. Examples include VPN overlay DNS names, stable local DNS names, or deployment-specific HTTPS origins.

Without a supported configuration hook, operators are pushed toward local patches to generated or pre-start-managed allowed-origin lists. Those local patches are fragile across updates and can drift from upstream behavior.

Proposed shape

  • Add a documented config key for extra trusted setup/control UI origins.
  • Validate entries as full origins, not arbitrary strings.
  • Merge configured extra origins with the existing default local/LAN origins.
  • Keep defaults conservative; do not add broad wildcard origins.
  • Surface invalid configured origins clearly during pre-start or setup status checks.

Acceptance criteria

  • Operators can add a specific trusted origin through supported config.
  • Invalid origins are rejected or reported clearly.
  • Generated gateway/control UI config includes configured extra origins.
  • The implementation does not require source patches for deployment-specific hostnames.
  • Tests cover valid origin, invalid origin, and default behavior.

Security note

This should remain an explicit allowlist. The goal is to avoid brittle local patches, not to loosen cross-origin restrictions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions