numba / numba/llvmlite

Static analysis flags command injection vulnerability in build.py

Open
#508 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
2.3k
Forks
372
Avg merge
3d 2h
Merged PRs (30d)
10

Description

Static analysis is flagging this code section as being vulnerable to command injection:

build.py (101-105):

llvm_config = os.environ.get('LLVM_CONFIG', 'llvm-config')
print("LLVM version... ", end='')
sys.stdout.flush()
try:
out = subprocess.check_output([llvm_config, '--version'])

The value of the env variable LLVM_CONFIG is directly used for an executable.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reviewing build.py lines 101-105 and the surrounding LLVM version-check path, then determine how LLVM_CONFIG is handled and whether existing build tests cover it. Done means the version check still works with supported configurations and the reported command-injection warning is resolved or clearly addressed.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
build-system, security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.