Back to skill

Security audit

counterfactual-decision

Security checks for vulnerabilities and agentic risk

Overview

The counterfactual calculator is local and simple, but the skill also includes automatic local learning memory that stores usage, errors, notes, and preferences without clear consent or limits.

Install only if you are comfortable with this skill keeping a local memory file about usage, errors, notes, and preferences. Avoid using it with confidential decisions unless persistence is removed or made opt-in, and treat anything stored in learned_patterns.json as untrusted data rather than instructions.

Vulnerability Patterns
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • 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
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Findings (1)

T02 · Agent Memory Poisoning

Warning
Location
scripts/learner.py:36
Finding

Unvalidated Persistent Preferences and Notes Can Poison Future Agent State

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • 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
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (13)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The declared purpose is a local counterfactual calculator, but the skill also advertises persistent self-learning, usage logging, error tracking, and user-preference storage. This mismatch is dangerous because it hides materially different behavior from reviewers and users, increasing the chance of undisclosed data collection and unauthorized persistence under the guise of a simple analysis tool.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The file implements a generic cross-skill telemetry and self-learning subsystem that is unrelated to the declared counterfactual-decision purpose. This expands the skill’s capability boundary to collect and persist usage data for arbitrary skills, increasing privacy and supply-chain risk because a seemingly narrow analytical skill now includes reusable tracking functionality.

Content

No source excerpt is available for this finding.

Ae4

Medium
Category
analysis-evasion
Confidence
80% confidence
Finding

Suspicious Unicode normalization or mixed-script content

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
88% confidence
Finding

The skill declares no explicit tool scope or permissions, yet the documentation instructs use of a learning module that writes to a local file (learned_patterns.json). Missing permission disclosure weakens reviewability and consent boundaries: an agent or user may invoke the skill expecting pure local computation, while it also performs stateful writes and retention.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The documentation expands the skill from deterministic local computation into persistent self-learning and preference memory, creating a broader trust and data-handling surface than the core function requires. In this context, the extra persistence is not necessary to compute counterfactuals and therefore increases risk without clear justification.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

Persistent collection of user preferences and usage history is not justified by a counterfactual decision calculator's stated purpose. This creates unnecessary privacy exposure and can accumulate sensitive behavioral data over time, especially if the skill is used on confidential business or personal decision scenarios.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill states that usage automatically records learning data and user preferences but does not present a clear privacy warning, consent flow, or confirmation step. Silent persistence is risky because users may provide sensitive inputs assuming ephemeral processing, while the skill retains them or derivative preference data locally.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill explicitly directs persistent storage of user preferences and usage history in a local memory file. Even if stored locally, this can expose sensitive operational patterns, personal preferences, or confidential decision context to other local users, backups, logs, or later workflows, especially because the storage is framed as routine rather than exceptional.

Content

No source excerpt is available for this finding.

Ae4

Medium
Category
analysis-evasion
Confidence
80% confidence
Finding

Suspicious Unicode normalization or mixed-script content

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This Python file includes its primary module docstring, CLI description, and user-facing status messages entirely in Chinese, which imposes a specific language/locale on users. The policy allows locale constraints only when they are clearly justified or when the user is offered a choice, neither of which is present here.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The script writes persistent operation history and preferences to a JSON file without any explicit privacy notice, consent flow, or retention policy. Even if stored locally, these records can expose behavioral data, error context, or notes to other local users, backup systems, or downstream tooling, especially because the persistence is silent.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The code records arbitrary capabilities, error notes, recent operations, and user preferences to disk for any referenced skill directory. In the context of a decision-analysis skill, this is unnecessary data collection that can capture sensitive workflow metadata or free-form notes without a clear need, creating privacy and unintended profiling risk.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
80% confidence
Finding

The manifest description and the rest of the skill instructions are presented entirely in Chinese, and the usage examples and capability labels assume Chinese-language interaction. Under the policy, forcing a specific language without user opt-in can be a natural-language policy issue unless the locale constraint is explicitly justified.

Content

No source excerpt is available for this finding.