Back to skill

Security audit

Self improving

Security checks for vulnerabilities and agentic risk

Overview

This skill is not clearly malicious, but it persistently changes agent memory and workspace behavior in ways users should review before installing.

Install only if you intentionally want a persistent local memory system that can change future agent behavior. Before enabling setup, review proposed edits to `AGENTS.md`, `SOUL.md`, and `HEARTBEAT.md`, decline the companion skill unless you separately trust its exact version, and periodically inspect or delete `~/self-improving/` if it stores more than you intended.

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

T05 · Unauthorized Access and Privilege Escalation

Warning
Location
setup.md:75
Finding
Persistent Workspace Control-File Modification Exceeds the Declared Filesystem Scope<![CDATA[ ## Vulnerability Details **File Location**: `setup.md:75-85`, `setup.md:108-160`, `setup.md:183-196`; conflicting scope declaration at `SKILL.md:221-227` **Vulnerability Type**: Persistent modification of agent control files outside the declared storage boundary **Risk Level**: Medium ### Vulnerable Code `setup.md:75-85`: ```markdown ### 4. Add SOUL.md Steering Add this section to your `SOUL.md`: ```markdown **Self-Improving** Compounding execution quality is part of the job. Before non-trivial work, load `~/self-improving/memory.md` and only the smallest relevant domain or project files. After corrections, failed attempts, or reusable lessons, write one concise entry to the correct self-improving file immediately. Prefer learned rules when relevant, but keep self-inferred rules revisable. Do not skip retrieval just because the task feels familiar. ``` ``` `setup.md:108-110`: ```markdown ### 6. Refine AGENTS.md Memory Section (Non-Destructive) Update `AGENTS.md` by complementing the existing `## Memory` section. Do not replace the whole section and do not remove existing lines. ``` `setup.md:183-196`: ```markdown ### 7. Add HEARTBEAT.md Steering Add this section to your `HEARTBEAT.md`: ```markdown ## Self-Improving Check - Read `./skills/self-improving/heartbeat-rules.md` - Use `~/self-improving/heartbeat-state.md` for last-run markers and action notes - If no file inside `~/self-improving/` changed since the last reviewed change, return `HEARTBEAT_OK` ``` Keep this in the same default setup flow as the AGENTS and SOUL additions so recurring maintenance is installed consistently. If your installed skills path differs, keep the same three lines but point the first line at the installed copy of `heartbeat-rules.md`. ``` This conflicts with `SKILL.md:221-227`: ```markdown This skill NEVER: - Accesses calendar, email, or contacts - Makes network requests - Reads files outside `~/self-improving/` - Infers preferences from silence or observat ...[truncated 2668 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Correct the declared scope in `SKILL.md` so it explicitly identifies `AGENTS.md`, `SOUL.md`, and `HEARTBEAT.md` as optional setup targets. 2. Require explicit, informed confirmation before modifying each workspace control file. 3. Present the exact proposed diff before writing it and allow the user to reject individual changes. 4. Create a backup before every modification and perform atomic writes to avoid partial-file corruption. 5. Place all inserted content inside uniquely marked, versioned boundaries so it can be safely updated or removed. 6. Validate that an existing block is not duplicated and preserve all unrelated instructions. 7. Provide an uninstall procedure that removes only the Skill-managed blocks and optionally deletes `~/self-improving/`. 8. Do not install heartbeat integration by default. Make recurring maintenance a separately disclosed and separately approved option. 9. Treat stored memory as untrusted data: do not execute commands or follow policy-changing instructions found inside memory entries. ]]>

T08 · Insecure Dependencies

Warning
Location
setup.md:89
Finding
Unpinned Companion Skill Is Installed Before Security Review<![CDATA[ ## Vulnerability Details **File Location**: `setup.md:89-104` **Vulnerability Type**: Mutable third-party dependency installation without version or integrity pinning **Risk Level**: Medium ### Vulnerable Code ```markdown ### 5. Add the Proactivity Companion as Part of Setup At the end of setup, briefly tell the user that you are going to add characteristics so the agent is more proactive: - noticing missing next steps - verifying outcomes instead of assuming they landed - recovering context better after long or interrupted threads - keeping the right level of initiative Then say that, for this, you are going to install the `Proactivity` skill. Only install it after the user explicitly agrees. If the user agrees: 1. Run `clawhub install proactivity` 2. Read the installed `proactivity` skill 3. Continue into its setup flow immediately so the skill is active for this workspace If the user says no, skip it cleanly and continue with self-improving only. ``` ### Technical Analysis The Skill instructs the agent to install `proactivity` by a mutable package name without specifying an audited version, source revision, or integrity digest. User consent reduces unauthorized-installation risk, but it does not address supply-chain integrity. The instructions install the dependency before reading it and direct the agent to continue into the dependency's setup flow immediately. Consequently, security review happens only after package contents have been placed in the environment, and there is no requirement to stop for a second approval after reviewing those contents. A compromised registry entry, package-owner account, or newly published release could therefore supply behavior different from the version originally reviewed with this Skill. ### Attack Path 1. An attacker compromises the `proactivity` package, its publisher account, or the package-resolution infrastructure. 2. The attacker publishes a modified release under the same unversioned Skill nam ...[truncated 1025 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Pin the companion Skill to a specific audited version or immutable revision. 2. Verify a publisher signature or cryptographic integrity digest before installation. 3. Resolve packages only from an explicitly trusted registry. 4. Download or inspect the dependency in a non-active quarantine location before installation. 5. Audit its manifest, instructions, scripts, requested capabilities, and setup flow before activation. 6. Present the dependency version, publisher, integrity information, permissions, and audit summary to the user. 7. Require a second explicit confirmation after review and before executing the dependency's setup instructions. 8. Do not automatically continue into the companion's setup flow. 9. Keep the companion optional and ensure declining it does not reduce the safety or correctness of the primary Skill. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (14)

Missing User Warnings

High
Confidence
98% confidence
Finding
The workflow performs export and wiping immediately after a single phrase, without warning the user about the consequences or confirming the destructive action. This increases the chance of accidental deletion and can also be abused through prompt injection or ambiguous language to cause denial of service against the agent's memory state.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The skill instructs the agent to automatically persist user corrections, preferences, and behavioral patterns into local memory files, but it does not require clear upfront user notice or explicit consent before storing that data. Even if storage is local, this can create privacy and trust issues because sensitive personal preferences or repeated behavioral signals may be retained longer than the user expects.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
- Pattern used 3x in 7 days → promote to HOT
- Pattern unused 30 days → demote to WARM
- Pattern unused 90 days → archive to COLD
- Never delete without asking

### 4. Namespace Isolation
- Project patterns stay in `projects/{name}.md`
Confidence
75% confidence
Finding
Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
| Financial | Card numbers, bank accounts, crypto seeds | Fraud risk |
| Medical | Diagnoses, medications, conditions | Privacy, HIPAA |
| Biometric | Voice patterns, behavioral fingerprints | Identity theft |
| Third parties | Info about other people | No consent obtained |
| Location patterns | Home/work addresses, routines | Physical safety |
| Access patterns | What systems user has access to | Privilege escalation |
Confidence
75% confidence
Finding
Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Vague Triggers

Medium
Confidence
95% confidence
Finding
The phrase "what do you know about me?" is a natural conversational utterance and could be used in exploratory or hypothetical discussion rather than as an authenticated export command. In a memory-bearing self-improving agent, accidental activation could expose accumulated personal context, making the broad trigger materially risky.

Vague Triggers

Medium
Confidence
97% confidence
Finding
The kill-switch trigger "forget everything" is common enough to appear in ordinary conversation, examples, or quoted text, yet it initiates destructive state changes. In a self-learning agent with persistent memory, accidental or adversarial prompting could erase memory unexpectedly and disrupt safety, auditability, or user data integrity.

Missing User Warnings

Medium
Confidence
93% confidence
Finding
The skill explicitly instructs the agent to log corrections, promote them to preferences, and make them permanent, but it does not require clear user notice or consent for retention and persistence. In a self-improving memory skill, this creates a privacy and data-governance risk because users may unknowingly have behavioral preferences and project-specific information stored across sessions or contexts.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The reversal flow says old patterns are archived, history is kept, and reversals are logged with timestamps, but users are not warned that superseded preferences and related metadata will continue to be retained. Keeping historical preference data without transparent notice or deletion controls increases privacy exposure and can preserve sensitive behavioral profiles longer than users expect.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The file explicitly says the agent will add, demote, and compact entries in a persistent user memory file on its own. Even though this appears intended as a productivity feature, silent persistent modification of user-owned memory can change future agent behavior without clear consent, transparency, or review, creating integrity and privacy risks.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The skill defines automatic loading, writing, retention, and maintenance of persistent memory across sessions without any explicit user consent, notice, or control at the point of collection. This creates a privacy and safety risk because user-provided preferences, corrections, and contextual data may be silently stored, retained, and later reused or exposed in ways the user did not expect.

Ssd 3

Medium
Confidence
96% confidence
Finding
The correction workflow persistently logs user corrections, timestamps, contexts, counters, and namespace placement into memory files, which can accumulate sensitive behavioral or project information over time. Even if intended for self-improvement, this persistent profiling increases risk of privacy leakage, over-collection, and unintended disclosure if memory is later shown, exported, or accessed by other components.

Ssd 3

Medium
Confidence
93% confidence
Finding
The skill explicitly preserves historical user preferences and prior states for future recall, including archived preferences such as previous communication style. Retaining historical preference history can expose personal behavior patterns and create unnecessary long-term data accumulation beyond what is needed for current task performance.

Context-Inappropriate Capability

Medium
Confidence
98% confidence
Finding
The setup flow expands the skill's scope by prompting installation of an additional `Proactivity` skill and immediately activating it in the same workspace flow. Although it requires explicit user agreement, bundling a second skill into this setup increases the chance of privilege creep, unexpected behavior changes, and user confusion about which skill is responsible for later actions.

Missing User Warnings

Low
Confidence
91% confidence
Finding
The template explicitly instructs creation of persistent files and directories under the user's home directory without any notice, consent flow, or scoping to the current task. While the actions are not inherently destructive, they cause filesystem side effects and establish long-lived storage, which is risky for an agent skill because it can modify the user's environment unexpectedly and retain data beyond the current interaction.

Static analysis

No suspicious patterns detected.