pub fn validate_dockerfile_safe(
s: impl AsRef<[u8]>,
label: &str,
) -> Result<(), String>Expand description
Rejects ", `, \, every C0 control byte and invalid
UTF-8, so a value embedded in a generated Dockerfile’s exec-form CMD keeps the line a
valid JSON array and reaches the container unchanged. The weaker of the two checks; a value
that reaches a RUN line needs validate_shell_arg_safe.