Back to skill

Security audit

Simplelogin Cli

Security checks for vulnerabilities and agentic risk

Overview

This skill is mostly a disclosed SimpleLogin alias-management helper, but it gives agents account-changing and deletion authority without enough safety guidance and includes an unsafe authenticated test script.

Install only if you are comfortable giving the agent SimpleLogin API-key access that can create contacts and enable, disable, or delete aliases. Treat delete as destructive, prefer disabling aliases first, and avoid running the included test script with untrusted alias or contact values until its jq and JSON handling are hardened.

Vulnerability Patterns
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • 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 (2)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/test-reverse-alias.sh:30
Finding

jq Expression Injection Through Untrusted Alias Input

Content
View full analysis

Vulnerability Details

File Location: scripts/test-reverse-alias.sh, lines 30–31
Vulnerability Type: Untrusted input embedded in dynamically constructed jq source code
Risk Level: Medium

bash
ALIAS_ID=$(curl -s "https://app.simplelogin.io/api/aliases?page_id=0" \
  -H "Authentication: $API_KEY" | jq -r ".aliases[] | select(.email==\"$ALIAS_EMAIL\") | .id")

Technical Analysis

ALIAS_EMAIL is inserted directly into a double-quoted jq program. Shell quoting prevents direct shell command injection, but it does not ensure that the value remains a jq string literal. An argument containing jq metacharacters and escaped quotation marks can terminate the intended comparison and inject additional jq filter expressions.

Because jq exposes operations such as environment access through env, injected expressions may read environment variables available to the script. An attacker can also manipulate the resulting ALIAS_ID, potentially causing the subsequent authenticated request to operate on a different alias belonging to the same SimpleLogin account.

No validation is performed to ensure that the extracted identifier is a single numeric value before it is inserted into the API URL.

Attack Path

  1. An attacker obtains the ability to control the first command-line argument passed to test-reverse-alias.sh.
  2. The attacker supplies an alias containing quotation marks and jq syntax that terminates the intended .email comparison.
  3. The script interpolates that value into the jq program.
  4. jq evaluates the injected expression rather than treating the entire argument as inert email-address data.
  5. The expression can alter the selected alias identifier or access environment values.
  6. The resulting output is assigned to ALIAS_ID and used in the authenticated contact-creation request.

Impact Assessment

Exploitation occurs with the privileges and environment of the user running the script. I ...[truncated 527 chars]

Remediation
View remediation

Remediation Suggestions

Pass the alias as jq data through --arg instead of constructing jq source code dynamically:

bash
ALIAS_ID=$(
  curl --fail-with-body --silent --show-error \
    "https://app.simplelogin.io/api/aliases?page_id=0" \
    -H "Authentication: $API_KEY" |
  jq -r --arg alias "$ALIAS_EMAIL" \
    '.aliases[] | select(.email == $alias) | .id'
)

Apply the following additional controls:

  1. Validate ALIAS_EMAIL as an email address before using it.
  2. Require ALIAS_ID to match ^[0-9]+$.
  3. Reject output containing multiple identifiers.
  4. Use curl --fail-with-body --silent --show-error so HTTP failures are not processed as valid API responses.
  5. Handle jq parse failures explicitly rather than relying only on an empty-result check.

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/test-reverse-alias.sh:43
Finding

JSON Injection Through Manually Constructed Contact Payload

Content
View full analysis

Vulnerability Details

File Location: scripts/test-reverse-alias.sh, lines 43–47
Vulnerability Type: Untrusted input embedded in manually constructed JSON
Risk Level: Medium

bash
RESPONSE=$(curl -s -X POST "https://app.simplelogin.io/api/aliases/$ALIAS_ID/contacts" \
  -H "Authentication: $API_KEY" \
  -H "Content-Type: application/json" \
  -d "{\"contact\": \"$CONTACT_EMAIL\"}")

Technical Analysis

CONTACT_EMAIL is inserted directly into a JSON string without JSON-aware escaping. Shell quoting prevents ordinary shell expansion inside the variable's value, but it does not escape JSON quotation marks, backslashes, control characters, or structural tokens.

A crafted contact value can therefore terminate the intended JSON string and append or replace JSON properties. At minimum, this permits malformed-request injection and disruption of the authenticated API operation. If the endpoint accepts additional properties, the attacker may influence those properties as well. The exact effect of injected fields depends on SimpleLogin's server-side schema and validation.

Attack Path

  1. An attacker controls the second argument supplied to test-reverse-alias.sh.
  2. The attacker provides a value containing a quotation mark followed by JSON syntax.
  3. The script concatenates that value into the request body without escaping it.
  4. curl sends the attacker-modified body with the victim's SimpleLogin API key.
  5. The API either rejects the malformed payload or interprets injected fields according to its server-side request schema.
  6. The script prints the response, which may expose additional API details to the invoking context.

Impact Assessment

The request is restricted to the fixed https://app.simplelogin.io origin and uses the permissions of the configured API key. This flaw does not establish direct local code execution or privilege escalation.

An attacker can reliably corrupt the JSON ...[truncated 324 chars]

Remediation
View remediation

Remediation Suggestions

Construct the request with jq or another JSON-aware serializer:

bash
PAYLOAD=$(jq -n --arg contact "$CONTACT_EMAIL" '{contact: $contact}')

RESPONSE=$(
  curl --fail-with-body --silent --show-error -X POST \
    "https://app.simplelogin.io/api/aliases/$ALIAS_ID/contacts" \
    -H "Authentication: $API_KEY" \
    -H "Content-Type: application/json" \
    --data-binary "$PAYLOAD"
)

Additional hardening should include:

  1. Validate CONTACT_EMAIL before constructing the request.
  2. Reject control characters and invalid email-address forms.
  3. Validate that ALIAS_ID is numeric before inserting it into the URL.
  4. Check the HTTP status and stop on non-success responses.
  5. Avoid printing complete API error bodies if they may contain sensitive account information.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Rogue AgentSelf-Modification, Session Persistence
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (7)

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · README.md (reported line 3)May include surrounding context.

md
# SimpleLogin CLI

Create and manage privacy-focused email aliases with SimpleLogin. Protect your real email address when signing up for services, newsletters, or online shopping.

## What is SimpleLogin?

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The README documents a destructive delete operation without any warning that alias deletion may be irreversible or disruptive if the alias is still in use. In a CLI intended for automation and agent use, missing cautionary guidance increases the chance of accidental data loss or service disruption through operator error.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
89% confidence
Finding

The skill documents shell-based CLI operations and requires external binaries (curl, jq), but it does not declare an explicit tool scope such as permissions or allowed-tools. In agent environments, missing tool restrictions can cause the runtime to grant broader shell access than intended, increasing the blast radius if the skill is misused or prompt-injected.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

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

md
---
name: simplelogin-cli
description: Create and manage SimpleLogin email aliases from the command line. Protect your real email with secure, private aliases.
license: MIT
metadata:
  clawdbot:

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The documentation includes a destructive delete operation for aliases without warning about permanence, confirmation, or safe usage guidance. In an agent or automation context, this can lead to accidental deletion of active aliases, disrupting email flows and potentially breaking account recovery or communications.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
86% confidence
Finding

The skill is described as a CLI for creating and managing SimpleLogin aliases, where network interaction with the SimpleLogin API is expected. However, this test script also pulls credentials from a specific local secrets file path, which is a separate sensitive-capability choice not justified by the manifest description itself.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · scripts/test-reverse-alias.sh (reported line 42)May include surrounding context.

sh
# Create contact (which returns reverse_alias)
echo "📧 Creating contact: $CONTACT_EMAIL"
RESPONSE=$(curl -s -X POST "https://app.simplelogin.io/api/aliases/$ALIAS_ID/contacts" \
  -H "Authentication: $API_KEY" \
  -H "Content-Type: application/json" \
  -d "{\"contact\": \"$CONTACT_EMAIL\"}")