Back to skill

Security audit

At Email Cli

Security checks for vulnerabilities and agentic risk

Overview

This email skill is mostly coherent, but it gives an agent mailbox mutation and sending ability while also recommending unpinned package execution, so users should review it before installing.

Install only if you trust the AgentTeam email package and are comfortable giving the agent access to the configured mailbox. Prefer a pinned, reviewed package version or checksum-verified binary, and require explicit confirmation before sending, replying, archiving, marking messages read, installing globally, or updating the CLI.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T08 · Insecure Dependencies

Warning
Location
SKILL.md:190
Finding

Unpinned Third-Party Package Is Downloaded and Executed Automatically

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 190-196
Vulnerability Type: Unpinned and automatically executed npm dependency
Risk Level: Medium

Vulnerable code:

bash
npx --yes @agentteamhq/email@latest --version
markdown
For one-off use, prefix the intended command with `npx --yes`:
bash
npx --yes @agentteamhq/email@latest inbox --unseen

Technical Analysis

The Skill directs the Agent to use npx --yes with the mutable latest tag. This downloads and executes whichever package release currently resolves as @agentteamhq/email@latest, without interactive confirmation, an exact version pin, or an integrity constraint.

Consequently, the code executed at runtime can differ from the code that existed when the Skill was reviewed. The mailbox command may run with inherited environment variables, including the configured WildDuck access token, user identifier, message-read token, and API endpoints. Although retrieving the legitimate package is consistent with the Skill's purpose, relying on an unpinned release creates a supply-chain trust boundary.

Attack Path

  1. An attacker compromises the npm publisher account, package release process, or another relevant supply-chain component.
  2. The attacker publishes a malicious version that becomes the target of the latest tag.
  3. A user requests an email operation while the local at-email command is unavailable.
  4. Following the Skill, the Agent executes:
    bash
    npx --yes @agentteamhq/email@latest inbox --unseen
    
  5. npx downloads and executes the changed package without asking for confirmation.
  6. The malicious package runs with the Agent process's local privileges and inherited environment, potentially accessing mailbox credentials and performing actions under the user's mailbox authority.

Impact Assessment

Successful exploitation could permit arbitrary code execution with the privi ...[truncated 475 chars]

Remediation
View remediation

Remediation Suggestions

  1. Replace @latest with an exact, reviewed package version:
    bash
    npx --yes @agentteamhq/email@1.2.3 --version
    npx --yes @agentteamhq/email@1.2.3 inbox --unseen
    
  2. Document a controlled process for reviewing and updating the pinned version.
  3. Verify npm provenance and package integrity before execution where supported.
  4. Require explicit user approval before downloading and executing the package for the first time, rather than relying solely on --yes.
  5. Perform installation or bootstrap checks in an environment that does not expose mailbox credentials. Provide secrets only to the reviewed command performing the requested mailbox operation.
  6. Prefer a checksum-verified standalone binary or a dependency installed from a lockfile-controlled deployment process.
  7. Pin the persistent global installation command at line 202 to the same reviewed version instead of installing the registry's current default release.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Rogue AgentSelf-Modification, Session Persistence
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (6)

Credential Access

High
Category
Privilege Escalation
Confidence
70% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · SKILL.md (reported line 18)May include surrounding context.

md
description: WildDuck API base URL for mailbox commands.
      - name: AT_EMAIL_WILDDUCK_ACCESS_TOKEN
        required: false
        description: WildDuck API access token for mailbox commands.
      - name: AT_EMAIL_WILDDUCK_USER_ID
        required: false
        description: WildDuck user ID for mailbox commands.

Self-Modification

High
Category
Rogue Agent
Confidence
90% confidence
Finding

Documenting at-email self-update encourages the agent to modify executable code on the system at runtime. Self-updating tooling can bypass normal package-management controls, change behavior unexpectedly, and introduce unreviewed code from remote sources, especially risky in automated environments.

Content

Scanner excerpt · SKILL.md (reported line 151)May include surrounding context.

bash
at-email version
at-email self-update

When installed through npm, self-update is disabled because npm owns the

Self-Modification

High
Category
Rogue Agent
Confidence
90% confidence
Finding

Skill modifies its own code, configuration, or behavior at runtime. Self-modification enables an agent to escalate privileges, disable safety constraints, or install persistent backdoors.

Content

Scanner excerpt · SKILL.md (reported line 154)May include surrounding context.

at-email self-update

text

When installed through npm, `self-update` is disabled because npm owns the
installed package version. Update notices still tell the user how to update the
npm package.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The skill documents commands that send email and modify mailbox state (mark-read, archive, send, reply) without explicitly warning that they have external side effects or requiring confirmation before use. In an agent setting, this increases the risk of unintended actions such as sending messages, altering evidence, or changing mailbox state based on ambiguous prompts.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
97% confidence
Finding

The skill instructs use of npx --yes @agentteamhq/email@latest, which fetches and executes whatever package version is current at runtime. That creates a supply-chain risk: a compromised publisher account, malicious dependency, or unexpected breaking release could cause arbitrary code execution on the host when the skill is followed.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
97% confidence
Finding

The one-off command npx --yes @agentteamhq/email@latest inbox --unseen executes a remote package without version pinning, exposing the user to arbitrary code execution if the published package or dependency chain is compromised. Because npx both downloads and runs the code immediately, the blast radius is greater than a passive dependency reference.

Content

No source excerpt is available for this finding.