Back to skill

Security audit

FluxA Agent Wallet for x402 Resources Payment

Security checks for vulnerabilities and agentic risk

Overview

This payment skill is not proven malicious, but its bundled wallet CLI includes under-disclosed direct fund-transfer capability and stores wallet credentials in ways users should review carefully.

Install only if you are comfortable giving this skill wallet/payment authority beyond x402 paid API calls. Review or remove the payout commands, restrict API endpoint overrides, protect or avoid plaintext stored credentials, and require explicit user approval for each payment or transfer before use.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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
Findings (3)

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/fluxa-cli.bundle.js:544
Finding

Undocumented Direct-Payout Capability Exceeds the Skill's Declared Privileges

Content
View full analysis
Recipient address (required) --amount Amount in smallest units (required) --id Unique payout ID (required) --network Network (default: base) --asset Asset contract address (default: USDC) ``` ```javascript async function cmdPayout(options) { const toAddress = options.to; const amount = options.amount; const payoutId = options.id; const network = options.network || DEFAULT_NETWORK; const assetAddress = options.asset || DEFAULT_ASSET; if (!toAddress || !amount || !payoutId) { return { success: false, error: "Missing required parameters: --to, --amount, --id" }; } if (!/^0x[a-fA-F0-9]{40}$/.test(toAddress)) { return { success: false, error: "Invalid recipient address format" }; } if (!/^\d+$/.test(amount)) { return { success: false, error: "Amount must be a positive integer (smallest units)" }; } const auth = await ensureValidJWT(); if (!auth) { return { success: false, error: 'FluxA Agent ID not initialized. Run "init" first.' }; } const currency = getCurrencyFromAsset(assetAddress, network); try { const result = await createPayout( { agentId: auth.agent_id, toAddress, amount, currency, network, assetAddress, payoutId }, auth.jwt ); await recordAudit({ event: "payout_request", payout_id: payoutId, to: toAddress, amount, status: result.status }); return { success: true, dat ...[truncated 2356 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/fluxa-cli.bundle.js:231
Finding

Agent Tokens and JWTs Are Persisted in Plaintext Without Explicitly Restrictive Permissions

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/fluxa-cli.bundle.js:4
Finding

Environment-Controlled API Endpoints Can Redirect Wallet Credentials and Payment Data

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (12)

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node ./scripts/fluxa-cli.bundle.js mandate-create --desc "{what task}" --amount 50000

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node ./scripts/fluxa-cli.bundle.js mandate-create --desc "{what task}" --amount 50000

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node ./scripts/fluxa-cli.bundle.js mandate-create --desc "{what task}" --amount 50000

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
node ./scripts/fluxa-cli.bundle.js mandate-create --desc "{what task}" --amount 50000

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

The CLI exposes a direct payout path that can transfer funds to an arbitrary address using only CLI arguments and the stored agent credentials. In the context of an autonomous payment skill, this is materially more dangerous than normal x402 signing because it enables general outbound transfers rather than narrowly scoped payment settlement for a specific paid resource.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The payout command performs a real funds-transfer operation immediately after basic argument validation, with no explicit confirmation, warning, dry-run mode, or secondary approval step. In an agent-wallet skill, this substantially raises the risk of accidental or malicious invocation causing irreversible asset movement.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
95% confidence
Finding

The skill demonstrates use of network access and likely environment-backed credentials via the CLI, but it does not declare any explicit tool scope or allowed tools. This weakens sandboxing and review because an agent may invoke broader capabilities than a user or platform expects when performing wallet and payment operations.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The payment-signing step shows how to generate a payment mandate and immediately send it to a paid endpoint, but it does not require an explicit user confirmation at that point. In an autonomous agent context, this omission is dangerous because the skill enables actual spending and transmission of a signed payment artifact without a fresh approval reminder tied to the concrete payment action.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
91% confidence
Finding

The skill instructs sending a base64-encoded payment token in an X-PAYMENT header to an external endpoint. Even though the example domain is illustrative, the documented behavior is to transmit a signed payment credential off-box; if reused against real endpoints, this can expose payment artifacts to unintended recipients or facilitate unauthorized chargeable requests.

Content

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

Get data.xPaymentB64 from response as PAYMENT_MANDATE

This PAYMENT_MANDATE is sent to the server via the X-Payment HTTP header to complete the payment.

curl -H "X-PAYMENT: $PAYMENT_MANDATE" https://api.example.com/paid-endpoint

text

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
94% confidence
Finding

The instruction explicitly tells the agent to generate identity-related registration parameters itself and not ask the user to provide them. That encourages autonomous creation of email/name/client information for an external registration flow, which can lead to fabricated identity data, unauthorized account creation, and actions taken without user consent or verification. In a payment-enablement skill, this is more dangerous because the generated Agent ID is a prerequisite for budget requests and payment execution.

Content

Scanner excerpt · initialize-agent-id.md (reported line 8)May include surrounding context.

bash
node ./scripts/fluxa-cli.bundle.js init --email <email> --name <agent_name> --client <client_info>

# Generate these parameters yourself to represent your real information. Do not ask the user to fill them in.
# - email: Email address for the agent
# - name: A descriptive name for the agent (it's your nick name)
# - client: Client/environment information (eg. Claude Code)

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file implements payout creation and payout-status API helpers, which extends the capability of the skill beyond the stated purpose of budget requests, x402 signing, and paid endpoint execution. Scope expansion is dangerous in an autonomous agent wallet because it introduces direct money-movement functionality that a caller may not expect or authorize under the published skill description.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The code persists agent_id, token, and JWT to a plaintext local config file under the user's home directory without permission hardening, encryption, or prominent disclosure. If the host is multi-user, backed up, or otherwise accessible, these credentials could be recovered and used to impersonate the agent or authorize wallet actions.

Content

No source excerpt is available for this finding.

Static analysis

Detected: suspicious.env_credential_access

Environment variable access combined with network send.

Critical
Code
suspicious.env_credential_access
Location
scripts/fluxa-cli.bundle.js:4