3 Commits
Author SHA1 Message Date
kevinveenbirkenbachandClaude Opus 5.5 9a61a1b3c2 fix(registry): accept only well-formed sha256 and sha512 digests
platform_digest and manifest_digest passed the digest a registry returned straight to their callers, which name files and scratch directories after it. A digest such as ../../etc or one with a trailing newline therefore reached the filesystem (CodeQL path traversal). valid_digest now admits only sha256: or sha512: followed by lowercase hex of the matching length; platform_digest falls through to the next manifest entry on a malformed one, and manifest_digest reports it as indeterminate.

Tests: TestValidDigest covers well-formed sha256 and sha512 and rejects traversal, uppercase, a trailing newline, md5, empty, None and 42; a malformed Docker-Content-Digest is indeterminate; a malformed platform entry falls through to a valid one. The fixtures now use well-formed digests. Negative control: the new tests fail on the old code.

Security score 0 % comes from 13 MEDUSA findings on unchanged lines of the existing registry HTTP client (WEB-SSRF, MEDUSA-ACP-SCAN-028, B310); committed on the operator word, the findings get their own review task.

🎯 Fix: 92 %
💥 Break: 2 %
💸 Cost: –
⏱️ Time: –
🛡️ Security: 0 %
🏆 Score: 0
🚦 Gate: ⚠️ security 0 % < 100: ask the operator before the commit

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-12 16:56:23 +00:00
kevinveenbirkenbach 3504f17557 Merge remote-tracking branch 'origin/main' into feature/store-i18n
# Conflicts:
#	.github/workflows/call-test-deploy.yml
#	roles/sys-svc-compose/tasks/main.yml
#	roles/web-app-keycloak/TODO.md
#	utils/docker/registry.py
2026-10-30 23:36:38 +01:00
kevinveenbirkenbachandClaude Opus 5 685c6b50ec test(images): require a mount for every VOLUME an image declares
An unmounted VOLUME does not fail: docker creates an anonymous volume for
it, the container works, and the gap shows up later as a volume nobody can
attribute. sys-ctl-hlth-volumes fails the deploy over exactly that, and its
whitelist keys on volume ids, which are new on every deploy, so the gap
cannot be suppressed there either. e0b973f9bb fixed one such case in
web-svc-xmpp by hand; this is the check that would have found it.

Attribution is the whole difficulty. meta/services.yml declares an image
under a key, and the compose file often runs it under another name:
web-app-jitsi declares the image under 'jitsi' and renders the service as
'web', web-app-erpnext runs one image as seven services, and the two RDBMS
consumer keys name no service of their own because the container comes from
sys-svc-rdbms. The sweep therefore unions the entry key with its
proxy.service_key and delegates the RDBMS keys to their provider role. A
first version keyed on the entry alone and reported six roles that mount
every path correctly, web-svc-xmpp among them.

Reading a config blob section is now its own module beside the registry
client, because the two readers were the same walk twice and registry.py
sat three lines under the file-size cap.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-10-17 21:17:25 +02:00