Skip to content

Custom DNS from SSM silently falls back to spore.host when the caller can't read /spawn/dns/* #1121

Closed

Description

@scttfrdmn

Found in the documentation audit (spore-host/spore-host#585), while rebuilding the IAM permissions page from the code.

Behaviour: pkg/config/config.go, ResolveDNSTarget:

ssmClient may be nil to skip SSM; a missing parameter, or any SSM error, means "not set there".

ParameterNotFound and AccessDeniedException are treated the same way. Picture an institution that sets /spawn/dns/domain and /spawn/dns/api_endpoint in SSM, as docs/custom-dns.md recommends ("the way to set it once for everyone launching in an account"), and a researcher whose policy lacks ssm:GetParameter on those paths. That researcher's launches then fall through to the default, spore.host's updater, with no warning. Their instance names are registered under spore.host, and DNS traffic goes to an endpoint outside the institution, which is exactly what the SSM setting existed to prevent.

The docs site's IAM page (reference/iam-permissions.md) has never listed ssm:GetParameter, so this is the likely state for anyone following it. It's being added in the docs sweep.

Suggested fix: distinguish the two cases.

  • ParameterNotFound → not set; continue to the default, as now.
  • Any other error (AccessDenied, throttling, network) → refuse the launch, naming the parameter and the error. If that's too strict, at least warn loudly and record the fallback in DomainSource/EndpointSource, so spawn launch prints "DNS: spore.host (SSM /spawn/dns/domain unreadable: AccessDenied)".

A test should pin that an AccessDenied from the SSM getter never resolves to the spore.host default silently.

Activity

  1. added this to the v0.137.0 milestone on Oct 19, 2026
  2. scttfrdmn commented on Oct 19, 2026

    @scttfrdmn
    ContributorAuthor

    Decision needed (milestone planning, 2026-10-18): when reading /spawn/dns/* fails with anything other than ParameterNotFound, should the launch refuse or just warn?

    Default if there's no objection: refuse, naming the parameter and the missing permission. A silent fallback to spore.host's updater is the bug.

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions