Warn about Code Execution in Arithmetic Expressions for Bash [[ $1 -eq 42 ]]
#3088
Open
2 tasks done
[[ $1 -eq 42 ]]
#3088
Blog posts discussing this issue:
For new checks and feature suggestions
Here's a snippet or screenshot that shows the problem:
Also affected
foo="${untrusted_input}"; (( foo > 10 ))
Here's what shellcheck currently says:
"$?"
= 0 aka no issuesHere's what I wanted or expected to see:
[[ ]]
with Arithmetic Expressions is insecure and can yield to code execution, use[ ]
instead.The text was updated successfully, but these errors were encountered: