T09 · Insecure Skill Coding Practices
- Location
EXAMPLES.md:17- Finding
Decrypted secret values are returned directly to the agent context
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This is a real cloud vault integration, but it gives agents broad secret-handling authority and optional transaction-signing power with under-disclosed plaintext exposure risks.
Install only if you trust the 1Claw service and npm packages, and grant the agent the narrowest possible vault paths, permissions, token lifetimes, and transaction guardrails. Treat tool results as potentially visible to the agent/model, especially raw secrets and env bundles, and avoid enabling transaction signing or broad policy creation unless you need them.
EXAMPLES.md:17Decrypted secret values are returned directly to the agent context
EXAMPLES.md:86Environment bundles expose multiple plaintext credentials in one tool response
SKILL.md:101Unpinned MCP package is downloaded and executed through npx
Granting read access to all API keys under a wildcard path is a broad permission change, yet the example frames it as routine and safe. Without an explicit warning and confirmation of scope, users may authorize overbroad access that enables credential harvesting or lateral movement by the recipient agent.
The examples add transaction simulation, signing, and broadcast flows to a skill described as secret management. That expands the apparent authority of the agent from storing secrets to moving blockchain assets, which can normalize high-risk financial actions and lead integrators or downstream agents to invoke dangerous capabilities under the banner of a vault tool.
Executing blockchain transactions is unjustified in the context of a vault skill and violates least privilege. If an agent using this skill can submit transactions, compromise, prompt injection, or user confusion could turn secret access into direct asset loss.
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
User: "Read the SSH key at keys/prod-server"
→ get_secret(path: "keys/prod-server")
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
Enterprise opt-in feature (Business tier and above). A human generates a 256-bit AES key in the dashboard — the key never leaves their device. Only its SHA-256 fingerprint is stored on the server.
- Enable: `POST /v1/vaults/{id}/cmek` with `{ fingerprint }`
- Disable: `DELETE /v1/vaults/{id}/cmek`
- Rotate: `POST /v1/vaults/{id}/cmek-rotate` (server-assisted, batched in 100s)
- Secrets stored in a CMEK vault have `cmek_encrypted: true` in responses
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
| `social_engineering_detection` | object | Detect urgency, authority claims, secrecy requests, bypass attempts |
| `encoding_detection` | object | Detect base64, hex, Unicode escapes that may hide payloads |
| `network_detection` | object | Detect blocked domains, IP URLs, data exfiltration patterns |
| `filesystem_detection` | object | Detect sensitive paths (/etc/passwd, .ssh/, .env, etc.) |
| `sanitization_mode` | string | `"block"` (reject threats), `"sanitize"` (strip), `"warn"` (log) |
| `threat_logging` | boolean| Log detected threats for audit (default: true) |
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
| `social_engineering_detection` | object | Detect urgency, authority claims, secrecy requests, bypass attempts |
| `encoding_detection` | object | Detect base64, hex, Unicode escapes that may hide payloads |
| `network_detection` | object | Detect blocked domains, IP URLs, data exfiltration patterns |
| `filesystem_detection` | object | Detect sensitive paths (/etc/passwd, .ssh/, .env, etc.) |
| `sanitization_mode` | string | `"block"` (reject threats), `"sanitize"` (strip), `"warn"` (log) |
| `threat_logging` | boolean| Log detected threats for audit (default: true) |
The security model claims the agent never sees its own credentials, yet earlier sections describe self-enrollment and direct API-key/JWT flows intended for agent use. This contradiction can cause unsafe deployment assumptions, leading operators to believe credentials are isolated in the MCP layer when the documented flow also supports direct credential handling by the agent or surrounding tooling.
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
- **Agents cannot create email-based shares** (prevents unsolicited email sharing).
- **Intents API is opt-in.** When enabled, raw key reads are blocked.
- **Transaction guardrails are human-controlled and server-enforced.**
- **Token revocation:** `DELETE /v1/auth/token` (or SDK `auth.logout()`) revokes the current Bearer token; revoked tokens return 401.
- **Request body limit:** 5MB max; larger requests return 413.
---
This markdown file instructs users to obtain agent IDs, API keys, and JWTs, including a curl example that transmits credentials, but it does not include any warning about treating these values as secrets, avoiding shell history/log exposure, or not committing them to source control. Because the document covers sensitive credentials directly, a user-facing warning about secure handling is expected under the missing user warnings criterion for markdown files.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
curl -X POST https://api.1claw.xyz/v1/auth/agent-token \
-H "Content-Type: application/json" \
-d '{"agent_id":"<uuid>","api_key":"ocv_..."}'
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
curl -X POST https://api.1claw.xyz/v1/auth/agent-token \
-H "Content-Type: application/json" \
-d '{"agent_id":"<uuid>","api_key":"ocv_..."}'
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
curl -X POST https://api.1claw.xyz/v1/auth/agent-token \
-H "Content-Type: application/json" \
-d '{"agent_id":"<uuid>","api_key":"ocv_..."}'
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
curl -X POST https://api.1claw.xyz/v1/auth/agent-token \
-H "Content-Type: application/json" \
-d '{"agent_id":"<uuid>","api_key":"ocv_..."}'
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
curl -X POST https://api.1claw.xyz/v1/auth/agent-token \
-H "Content-Type: application/json" \
-d '{"agent_id":"<uuid>","api_key":"ocv_..."}'
The storage example presents handling of a raw API key without any warning about sensitivity, retention, or who may later access it. This can encourage casual secret submission and sharing patterns by users or agent authors without informed consent about exposure and access implications.
Loading an environment bundle into a deploy script can expose secrets to subprocesses, logs, crash reports, shell history, or inherited environments. The example omits that risk, which may lead operators to treat secret injection as harmless when it often expands exposure surface significantly.
The self-enrollment example sends personal data and agent registration details to an external API and then instructs storage of issued credentials in environment variables, but it does not disclose the privacy and credential-handling risks. This can lead users to expose identity data or store powerful agent credentials insecurely.
The example performs an outbound HTTP POST containing human_email and agent registration data to an external service. External transmission of identifying or provisioning data is security-relevant and should be explicit because it can create privacy, trust-boundary, and account-enrollment risks.
Agent thinking: I don't have 1Claw credentials yet. I'll self-enroll using the user's email.
→ (HTTP) POST https://api.1claw.xyz/v1/agents/enroll
Body: {"name":"cursor-assistant","human_email":"user@example.com"}
Response: {"agent_id":"abc123...","message":"Enrollment processed."}
The manifest presents the skill as secret management, but the document exposes substantially broader capabilities including auth, org management, billing, audit, chain lookup, IP-rule management, and transaction operations. This scope mismatch can mislead reviewers and users into granting or enabling a much more powerful skill than its stated purpose suggests, increasing risk of over-privileged use.
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
If you don't have credentials yet, self-enroll — this sends them to your human:
# curl
curl -s -X POST https://api.1claw.xyz/v1/agents/enroll \
-H "Content-Type: application/json" \
-d '{"name":"my-agent","human_email":"human@example.com"}'
Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.
Store a new secret or update an existing one. Each call creates a new version.
| Parameter | Type | Required | Default | Description |
| ------------------ | ------ | -------- | --------- | ---------------------------------------------------------------------------------------------------- |
| `path` | string | yes | | Secret path |
| `value` | string | yes | | The secret value |
Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.
Store a new secret or update an existing one. Each call creates a new version.
| Parameter | Type | Required | Default | Description |
| ------------------ | ------ | -------- | --------- | ---------------------------------------------------------------------------------------------------- |
| `path` | string | yes | | Secret path |
| `value` | string | yes | | The secret value |
Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.
Store a new secret or update an existing one. Each call creates a new version.
| Parameter | Type | Required | Default | Description |
| ------------------ | ------ | -------- | --------- | ---------------------------------------------------------------------------------------------------- |
| `path` | string | yes | | Secret path |
| `value` | string | yes | | The secret value |
Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.
Store a new secret or update an existing one. Each call creates a new version.
| Parameter | Type | Required | Default | Description |
| ------------------ | ------ | -------- | --------- | ---------------------------------------------------------------------------------------------------- |
| `path` | string | yes | | Secret path |
| `value` | string | yes | | The secret value |
Detected: suspicious.exposed_secret_literal