K-114: address cross-review findings
CI / Shell-Lint (bash -n, source-check, Validierungs-Tests) (pull_request) Has been cancelled

- CTID prompt re-prompts on invalid interactive input (was: abort)
- env-provided NAMESERVER is validated when non-empty ('' stays inherit)
- prompt_validated handles EOF (no infinite loop, clean abort under -e)
- 10# base forcing in vlan/cidr/ipv4 arithmetic (leading zeros are not
  octal errors); is_clean_ascii rejects embedded newline/tab explicitly
  (command substitution strips trailing newlines); is_ipv4_list checks
  the whole string before word splitting
- nameref guard against reserved variable names in prompt_validated/
  require_valid; source-check pattern documented as the repo contract
- 8 new test cases (41 total)
This commit is contained in:
2026-06-12 03:20:11 +02:00
parent 80e2ec04ff
commit 490fda2ed1
3 changed files with 80 additions and 10 deletions
+4
View File
@@ -3,6 +3,10 @@
# gesourct, Skript stirbt erst mitten im Lauf" ist zweimal real passiert
# (nexus-db: im Review gefangen; authentik: erst in Produktion).
# Aufruf: tests/check_ct_source.sh [verzeichnis] (Default: ct/)
#
# Bewusst eng: akzeptiert wird NUR die curl-Prozesssubstitutions-Form
# `source <(curl ... build.func)` — das ist der Repo-Vertrag für ct/-Scripts
# (Review-Triage K-114). Lokales Sourcen gehört nicht in ct/*.sh.
set -euo pipefail
DIR="${1:-$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)/ct}"