Skip to content

fix(ingress): accept dash-leading challenges; redact secrets in certbot logs - #168

Merged
kvinwang merged 1 commit into
mainfrom
fix/ingress-hook-arg-and-log-redaction
Oct 19, 2026
Merged

kvinwang merged 1 commit into
mainfrom
fix/ingress-hook-arg-and-log-redaction

Conversation

@kvinwang

Copy link
Copy Markdown
Collaborator

Two findings from a security pass over dstack-ingress:

  • Delegation hook: the ACME challenge value starts with - about 1 time in 64, and dnsman.py then rejects it with argument --content: expected one argument, so the issuance or renewal fails. The hook now passes it as --content=<value>.
  • Credential leak in logs: certman prints certbot's stderr/stdout on failure. lexicon's Namecheap client puts ApiKey in the request URL, so a network error can write the key to the container log. Values of CLOUDFLARE_API_TOKEN, LINODE_API_TOKEN and NAMECHEAP_API_KEY are now replaced with *** before printing.

…ot logs

- acme-dns-alias-hook.sh: the ACME validation value is base64url and starts
  with "-" about once in 64; argparse then treats it as an option and the
  delegated auth hook fails. Pass it as --content=<value>.
- certman.py: certbot output is printed on failure. lexicon's Namecheap
  client sends ApiKey in the query string, so a network error can put the
  key in the container log. Mask DNS provider credentials before printing.

Signed-off-by: Kevin Wang <wy721@qq.com>
@kvinwang
kvinwang merged commit f2932c6 into main Oct 19, 2026
6 checks passed
@kvinwang
kvinwang deleted the fix/ingress-hook-arg-and-log-redaction branch October 19, 2026 14:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant