caduceusmail
Fail
Audited by Gen Agent Trust Hub on Mar 17, 2026
Risk Level: HIGHCOMMAND_EXECUTIONREMOTE_CODE_EXECUTIONEXTERNAL_DOWNLOADSCREDENTIALS_UNSAFE
Full Analysis
- [COMMAND_EXECUTION]: The skill makes extensive use of dynamically generated PowerShell code. In
scripts/email_alias_fabric_ops.py, therun_pwshfunction constructs a script as a string—incorporating variables such as mailboxes and alias names—writes it to a temporary file, and executes it viasubprocess.run(['pwsh', ...]). While variable quoting is applied, this pattern of dynamic execution of shell commands is a significant security vector. - [REMOTE_CODE_EXECUTION]: Automated scanners identified a pattern in
scripts/email_alias_fabric_ops.pywhere data retrieved from external APIs (Microsoft Graph and Cloudflare) viaurllib.request.urlopenis parsed and subsequently used in logic that drives command construction and execution. - [EXTERNAL_DOWNLOADS]: The PowerShell bootstrap logic in
scripts/caduceusmail-bootstrap.ps1.txtautomatically installs missing dependencies (Microsoft.GraphandExchangeOnlineManagementmodules) from the PowerShell Gallery (PSGallery) using theInstall-Modulecommand. Although these are official Microsoft modules, downloading and executing code from external repositories at runtime is a notable behavior. - [CREDENTIALS_UNSAFE]: The skill is designed to manage high-entropy secrets, including Microsoft Entra client secrets and Cloudflare API tokens. It provides options (
--persist-env,--persist-secrets) to save these credentials into a plaintext environment file at~/.caduceusmail/.env, which could lead to exposure if the system is compromised. - [COMMAND_EXECUTION]: In
scripts/email_alias_fabric_ops.py, theresolve_entra_exchange_scriptfunction can be configured (viaCADUCEUSMAIL_ALLOW_EXTERNAL_SCRIPT_RESOLUTION) to search parent directories for an executable script namedentra-exchange.sh, introducing a risk of executing an unintended or malicious file if the workspace environment is not strictly controlled.
Recommendations
- HIGH: Downloads and executes remote code from: unknown (check file) - DO NOT USE without thorough review
Audit Metadata