Wrapper hardening: TLS validation, cred-path fallback, no-CI fast-exit (framework/tools) #550
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Wrapper hardening — three authorized defects in
packages/mosaic/framework/tools/Authorized by repo owner. One PR fixing three defects in the Mosaic framework tool wrappers.
F-03 — TLS validation disabled for all hosts (
-kblanket)The generic HTTP helpers (
mosaic_http,mosaic_http_post,mosaic_http_patch) and the Woodpecker scripts usedcurl -sk, disabling TLS verification for every service — including public WAN hosts where MITM matters.Fix: validate by default; pass
-konly for private-network IP literals (trusted LAN) or an explicitMOSAIC_INSECURE_TLSopt-in, via a new_mosaic_tls_opthelper. Woodpecker scripts talk only to the two public/valid CI hosts, so-kis removed outright there (-sk→-sS).F-02 — hardcoded credentials path
credentials.shhardcoded the jarvis-brain legacy path as the only default. Fix: fallback chain — env first, then standard config path (~/.config/mosaic/credentials.json), then the legacy path retained as final fallback so the running fleet keeps working.F-06 —
pr-ci-wait.shburns full timeout on no-CI reposRepos with no CI configured (device-imaging class) loop to timeout because empty status was treated as
unknown/pending. Fix: a distinctno-statusstate plus a consecutive-empty counter (N=3) that fast-exits 0 with a clear "no CI configured" message. Repos that DO have pipelines are unaffected — any pipeline signal resets the streak andpendingstill waits.Not in scope
F-04 was deliberately NOT swept in this PR.