Skip to content
vetkitChecksChangelogDocumentation

vetkit.shell.injection.shell-c-arguments

A sh -c / bash -c command string interpolates the script's arguments inside double quotes. The inner shell re-parses the argument, so metacharacters in it run as commands.

Last updated:

Suite: Security

bash

A sh -c / bash -c command string interpolates the script's arguments inside double quotes. The inner shell re-parses the argument, so metacharacters in it run as commands.

Category: SECURITY · Engine rule severity: WARNING

How to fix it

Pass arguments separately and reference them inside a single-quoted script: sh -c 'printf "%s\n" "$1"' _ "$1".

References

Source: packages/engine/rules/sast/shell.yml.

Generated from shipped rule definitions at build time. Matching is a review signal, not proof of exploitability. “generic” denotes text matching, not complete language or framework coverage. Runtime configuration and available tools affect whether a rule runs.