In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.
Test your applicationsLearn about Arbitrary Code Injection vulnerabilities in an interactive lesson.
Start learningThis was deemed not a vulnerability.
torch is a Tensors and Dynamic neural networks in Python with strong GPU acceleration
Affected versions of this package are vulnerable to Arbitrary Code Injection through filter-test-configs
in the pull_request_target-triggered
workflow, allowing an attacker to use a malicious branch name to gain command execution and potentially leak secrets.
Mitigation:
Use an intermediate environment variable for potentially attacker-controlled values such as github.event.workflow_run.head_branch
:
- name: Select all requested test configurations
shell: bash
env:
GITHUB_TOKEN: ${{ inputs.github-token }}
JOB_NAME: ${{ steps.get-job-name.outputs.job-name }}
HEAD_BRANCH: ${{ github.event.workflow_run.head_branch }}
id: filter
run: |
...
python3 "${GITHUB_ACTION_PATH}/../../scripts/filter_test_configs.py" \
...
--branch "$HEAD_BRANCH"