exec() call detected
High
- Category
- Dangerous Code Execution
- Content
# 执行脚本获取命名空间 qieman_ns = {} with open(scripts_path / "qieman-mcp-query.py", 'r', encoding='utf-8') as f: exec(f.read(), qieman_ns) encrypt_ns = {} with open(scripts_path / "encrypt-holdings.py", 'r', encoding='utf-8') as f:- Confidence
- 95% confidence
- Finding
- The test file executes the full contents of another Python file with exec(), which will run arbitrary top-level code from that file during testing. If the referenced script is modified, compromised, or contains unexpected side effects, running the tests can trigger arbitrary code execution in the tester's environment.
