Ensure images only carry labels defined in the expected schema when strict validation is enabled.
Evaluates every LABEL instruction when a label schema is configured and strict mode is active.
Emit DL3050 when a LABEL instruction includes a key not present in the configured label schema while strict mode is enabled.
Message: Superfluous label(s) present.
Restricting labels to a known set prevents typos and unauthorized metadata from entering images.
Provide a label schema and enable strict validation. Without strict mode, this rule is silent.
LABEL instruction, extract key/value pairs.info
Schema: { "org.opencontainers.image.source": string }
Dockerfile
LABEL org.opencontainers.image.revision="abcd1234"
Dockerfile
LABEL org.opencontainers.image.source="https://github.com/acme/project"
(c) 2025 Asymmetric Effort, LLC. scaldwell@asymmetric-effort.com
