feat(caddy): add caddy_list_certs whitelist entry and cert parser
- Extend commands.yml.example with caddy_list_certs (sh loop over /data/caddy/certificates/*/*.crt using openssl) - Add lib/parse-caddy.ts: parseCertList() parses CERTFILE/CERTEND delimited openssl output - Add shiki ^1.29.2 dependency for server-side Caddyfile syntax highlighting Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
c12e36e0a4
commit
1c51a0868f
3 changed files with 62 additions and 0 deletions
|
|
@ -63,3 +63,10 @@ commands:
|
|||
caddy_show_config:
|
||||
cmd: ["caddy", "fmt", "/etc/caddy/Caddyfile"]
|
||||
description: "Print the formatted Caddy config"
|
||||
|
||||
caddy_list_certs:
|
||||
cmd:
|
||||
- sh
|
||||
- -c
|
||||
- "for f in /data/caddy/certificates/*/*.crt; do [ -f \"$f\" ] || continue; echo \"CERTFILE:$f\"; openssl x509 -noout -subject -issuer -dates -in \"$f\" 2>&1; echo \"CERTEND\"; done"
|
||||
description: "List TLS cert info (subject, issuer, validity dates) from Caddy certificate store"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue