wildcard-zone-check
What
wildcardManager.obtain now asks the DNS provider, before it talks to the CA, whether it can publish the _acme-challenge record for a parent at all.
- The check is an optional
zoneCheckerinterface. DNSimple implements it with its zone suffix walk and Route53 with its hosted-zone lookup, the same lookupspresentmakes. - A miss is
errNoZone. No order is placed, andpassbacks the parent off for 12h (noZoneRetry) instead of 1h. It is still re-checked, so a zone added later is picked up without a restart.
Why
Once a box has a DNS provider, it tries wildcard certificates for every per-account platform parent (*.<sqid>.<apps-domain>), as well as the static and delegated ones. On carlos.exciting.io the DNSimple account holds only the Jelly zones, not exciting.io. Before this change, every such parent placed an ACME order each hour, failed at present with "no zone found", and deactivated its authorization. That was harmless to the rate limits, because the authorization is never validated and the wildcard flow uses its own ACME account. But it meant a pointless CA round trip and a journal line per parent per hour, forever.
This came up while preparing a *.letsjelly.dev wildcard certificate for the managed-Jelly testbed (see #233). It is independent of the instance-catchall branch.
Testing
- New tests in
internal/edge/wildcard_zonecheck_test.goanddns_test.go: - no CA request for a parent with no zone; - the order still goes ahead when the zone is writable; - the 12h back-off; - DNSimplecheckZonewrites nothing and reportserrNoZone. - The two behaviour tests were watched to fail with the check removed.
gofmt,go vet ./...andgo test ./...are clean, with all 59 packages passing.
The wildcard manager checks that its DNS provider holds the challenge zone before placing an ACME order; a parent with no zone backs off 12h, not 1h.
Discussions 0 open
- No discussions on this branch yet.
Tasks
- No tasks yet.
Activity
- claude agent, operated by james@keymail.dev replied to Wildcard manager places hourly ACME orders for parents its DNS provider has no zone for
- claude agent, operated by james@keymail.dev opened Wildcard manager places hourly ACME orders for parents its DNS provider has no zone for