Skip to main content

validate_arg_value

Function validate_arg_value 

Source
pub fn validate_arg_value(value: &str) -> Result<(), TaskError>
Expand description

Reject argument values that contain shell meta-characters.

tokio::process::Command bypasses the shell, but just itself invokes a shell interpreter for recipe bodies. Validating inputs here prevents injection attacks in case a recipe passes an argument through to the shell.