RockteMQ-AI commented on issue #2206:
URL: 
https://github.com/apache/rocketmq-dashboard/issues/2206#issuecomment-5295486700

   **Issue Evaluation**
   
   Category: `bug` | Status: **Confirmed**
   
   The reported issue has been verified against the current codebase.
   
   **Root Cause:** `CliAgentProvider` (line 75) and `ClaudeCodeAgentProvider` 
(line 97) create `ProcessBuilder` instances without calling 
`environment().clear()` or applying any allowlist filtering. The 
`StudioProcessGuardrails` class referenced in the issue does not yet exist. CLI 
subprocesses inherit the full JVM process environment, including 
`STUDIO_ADMIN_PASSWORD`, `STUDIO_DATASOURCE_PASSWORD`, 
`SPRING_DATASOURCE_PASSWORD`, and any `AI_*` API keys.
   
   **Impact:** Any vulnerability in a CLI agent or its dependency chain can 
exfiltrate Studio admin credentials, database passwords, and AI provider API 
keys through the environment. This violates the principle of least privilege 
and creates a credential-exposure path that is independent of the AI prompt 
layer.
   
   **Severity:** High — direct credential exposure to subprocess environment
   
   The proposed `StudioProcessGuardrails.environmentForCliAgent()` with an 
explicit allowlist (`PATH`, `HOME`, `JAVA_HOME`, `LANG`, locale vars, `TMPDIR`, 
proxy vars, timezone, `STUDIO_HOME`, `STUDIO_LOG_DIR`, `STUDIO_AI_*` 
session-scoped overrides) is the correct approach. The `STRICT_MODE` / 
`LEGACY_MODE` toggle with audit logging provides a safe migration path.
   
   An automated fix proposal will be generated. Reply `/approve` to proceed 
with PR generation.
   
   ---
   *Automated evaluation by github-manager*


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to