Tainted flow: 'OUTPUT' from os.environ.get (line 31, credential/environment) → open (file write)
Medium
- Category
- Data Flow
- Content
sys.exit(2) # 保存 with open(OUTPUT, 'w', encoding='utf-8') as f: json.dump(all_data, f, ensure_ascii=False, indent=2) sycm_list = all_data.get('data', {}).get('sycm', [])- Confidence
- 90% confidence
- Finding
- The output path is influenced by environment variables and optionally by argv, then used directly in a file write. In an agent or shared execution environment, this can cause unintended overwrite of attacker-chosen files, especially if the process runs with elevated privileges or in a sensitive workspace.
