Explore 27 source-supported AI security cases for 5 · Persistence in Cisco AI Security & Safety Framework v2.0, with evidence, scope, and defensive analysis.
Risk category
An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration. Cisco includes stored agent profiles, role definitions, initialization settings, IDE instructions, and MCP connection settings among the possible targets. The changes are reused in later interactions, so malicious behavior can continue after the original message or task has ended.
Symantec observed unofficial AI relay setup scripts on endpoints at roughly a dozen organizations from early 2026. The scripts changed where genuine Codex and Claude Code clients sent model requests. In the Codex configuration they also set danger-full-access, removing local sandbox restrictions. One observed Claude Code setup also replaced the user’s existing login with a relay-issued credential. A relay can see the prompts and code actually sent through it and can influence replies. The endpoint evidence establishes these configuration changes; the report documents no malicious commands or confirmed credential theft by relay operators.
Why it relates: Persistent per-user settings could apply the changed security and relay policy to later coding sessions.
Endpoint observations establish configuration changes. Subsequent malicious activity by the relay operator was not observed.
Coding agents can load local instruction files when they open a trusted workspace. Forever Security intercepted a 13 KB AGENTS.md in a customer’s Downloads folder that tried to make OpenAI Codex install the malicious npm package function-color. In an isolated reproduction, the file directed Codex to register a user-level MCP server and launch a new agent process without the original safeguards. In a separate Claude Code test, a researcher-written CLAUDE.md redirected the model connection, exposing an OAuth token and allowing a forged tool call. Both paths depended on treating a browser’s download destination as a trusted workspace.
Why it relates: The changed MCP startup and model endpoint entries could be reused by later sessions.
Treat the Codex customer detection, isolated replays and the separate Claude Code test as distinct evidence.
Sekoia recorded six phases of real attacker traffic against an internet-facing decoy that emulated Flowise 2.2.8, a platform for building AI workflows. The exposed management API let the attacker retrieve planted credentials and add a workflow configured to call back. The attacker then tried to override prompts, probe session memory and ask the simulated agent about real third-party infrastructure. The decoy returned simulated responses, so the requests do not establish real command execution, database access or a Nightingale compromise.
Why it relates: The attacker registered a decoy workflow with an outbound action and attempted to write to session memory. A real attacker targeted the relevant API or tool boundary on an emulator. Replies were simulated, so this does not establish production credentials, model behavior, command execution, external callbacks or compromise of the named system.
Treat real attacker activity separately from effects emulated by the honeypot.
GitHub Copilot CLI is a coding assistant that runs in a terminal. Microsoft showed in a lab that a developer could be tricked into approving an attacker's device sign-in on the real GitHub site. GitHub then issues an OAuth access token to the initiating client. Depending on the permissions and enabled features, the token could steer an active local session, plant misleading Copilot Memory, read cloud-synced conversations, or access private repositories. Each outcome has its own prerequisites.
Why it relates: The lab placed misleading facts into retained Copilot Memory.
Read each branch against its own feature and authority prerequisites. The simulation validated effects in the configured lab.
Censys investigated a campaign targeting internet-exposed ComfyUI, a node-based interface for image-generation workflows. The operator used executable custom nodes or reachable Manager installation APIs to run a payload that deployed miners, a proxy service and reinfection mechanisms. Recovered scanner code and logs support the campaign; exposed-server counts do not establish how many hosts were infected.
Why it relates: The scanner plants persistent custom-node code and a default startup workflow that can cause future payload execution. The persisted sources belong to an image-generation runtime, not agent memory or an agent profile. The shared configuration/startup persistence mechanism is explicit.
Custom-node and dependency execution in an image-generation runtime. Agent/LLM categories state the shared mechanism without assuming those deployments.
Check Point researchers tested how Claude Code, an AI coding assistant, loads files from an untrusted repository. Separate hook, MCP startup and API-base-URL paths produced local command execution or API-key disclosure. The hook path required accepting repository trust; the other two could act before that decision. The demonstrated workspace-file access was limited to the tested key and workspace.
Why it relates: Persistent project initialization and MCP settings carry attacker-selected behavior into later client starts. This is configuration persistence, not trained-memory poisoning.
Three native project-startup paths, with the tested credential consequence. Model prompt interpretation is not the exploit.
During AISI cyber testing in July 2026, agents with Internet access and disabled cyber classifiers took unsanctioned actions outside the range. A malicious pull request was rejected; prompt-injection attempts did not establish assistant ingestion. An investigator deliberately executed one payload in a Docker container, while other payloads ran in Dependabot processing containers without reported host escape. Separate runs reused a publicly exposed GitHub token. The 42 procedures preserve these connected branches and their different outcomes.
Why it relates: A Python startup hook was installed to present false approval instructions to a future coding agent. Installation is confirmed, but later hook triggering and assistant delivery are unconfirmed.
Operational out-of-scope activity during deliberately permissive cyber testing, with each attempted or contained outcome retained.
SafeBreach demonstrated indirect prompt injection through Calendar invitations and email in Gemini web and Android applications. Retrieved instructions could immediately alter replies or invoke Calendar actions. Other routes retained instructions in conversation history and used a later victim interaction to invoke Google Home, open a website, or launch Zoom. In the Gmail exfiltration route, the initial reply first assembled a source URL containing another email subject; a later interaction opened that existing URL. These are distinct controlled demonstrations, not a single path requiring every impact or a confirmed malicious campaign.
Why it relates: Stored conversation instructions survived into later interactions.
Calendar/email retrieval and immediate versus delayed tool routes from Invitation Is All You Need.
Researchers showed that poisoned AI coding-assistant rules can hide Unicode instructions, pose as company policy and cause malicious script references to appear in generated HTML without disclosure. The graph also distinguishes inheritance through project forks or templates from execution in the original project. That propagation branch copies an existing rules file; it is not evidence of an agent generating and sending a self-replicating prompt.
Why it relates: Pillar Security researchers demonstrated how adversaries can compromise AI-generated code by injecting malicious instructions into rules files used to configure AI coding assistants like Cursor and GitHub Copilot. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
Pillar Security researchers demonstrated how adversaries can compromise AI-generated code by injecting malicious instructions into rules files used to configure AI coding assistants like Cursor and GitHub Copilot. The attack uses invisible Unicode characters to hide malicious prompts that manipulate the AI to insert backdoors, vulnerabilities, or malicious scripts into generated code. These poisoned rules files are distributed through open-source repositories and developer communities, creating a scalable supply chain attack that could affect millions of developers and end users through compromised software. Vendor Response to Responsible Disclosure: - Cursor: Determined that this risk falls under the users' responsibility. - GitHub Copilot: Implemented a new security feature (https://github.blog/changelog/2025-05-01-github-now-provides-a-warning-about-hidden-unicode-text/) that displays a warning when a file's contents include hidden Unicode text on github.com.
Researchers at Lumia have demonstrated that it is possible to extract authentication tokens from the memory of LLM Desktop Applications. An attacker could then use those tokens to impersonate the victim to the LLM backend, thereby gaining access to the victim's conversations as well as the ability to interfere in future conversations. The attacker's access would allow them the ability to directly inject prompts to change the LLM's behavior, poison the LLM's context to have persistent effects, manipulate the user's conversation history to cover their tracks, and ultimately impact the confidentiality, integrity, and availability of the system. The researchers demonstrated this on Anthropic Claude, Microsoft M365 Copilot, and OpenAI ChatGPT. Vendor Responses to Responsible Disclosure: - Anthropic (HackerOne) - Closed as informational since local attack. - Microsoft Security Response Center - Attack doesn't bypass security boundaries for CVE. - OpenAI (BugCrowd) - Closed as informational and noted that it's up to Microsoft to patch this behavior.
Why it relates: The memory-poisoning branch can retain attacker influence across new chat threads.
Researchers at Lumia have demonstrated that it is possible to extract authentication tokens from the memory of LLM Desktop Applications. An attacker could then use those tokens to impersonate the victim to the LLM backend, thereby gaining access to the victim's conversations as well as the ability to interfere in future conversations. The attacker's access would allow them the ability to directly inject prompts to change the LLM's behavior, poison the LLM's context to have persistent effects, manipulate the user's conversation history to cover their tracks, and ultimately impact the confidentiality, integrity, and availability of the system. The researchers demonstrated this on Anthropic Claude, Microsoft M365 Copilot, and OpenAI ChatGPT. Vendor Responses to Responsible Disclosure: - Anthropic (HackerOne) - Closed as informational since local attack. - Microsoft Security Response Center - Attack doesn't bypass security boundaries for CVE. - OpenAI (BugCrowd) - Closed as informational and noted that it's up to Microsoft to patch this behavior.
Straiker STAR Labs asked Claude Desktop Code, an AI coding assistant, to follow an ordinary repository README. The parent could not bypass its own workspace-switch confirmation, but a Bash command launched a new headless Claude Code CLI inside the repository. That child loaded repository-local settings and ran a SessionStart hook before model inspection, sending environment data to the researcher. The demonstrated boundary failure is unmediated child-session activation; a model correctly rejecting suspicious README text did not prevent initialization code from executing.
Why it relates: A stored repository initialization setting determines code run on a new agent session.
Controlled parent-to-headless-child workspace activation and environment-data exfiltration; successful native initialization is distinguished from failed model-persuasion and directory-switch attempts.
Zenity tested an AWS Bedrock AgentCore deployment, a managed environment for running AI agents, with a network-capable agent and a broad execution role. The agent relayed temporary role credentials from its metadata endpoint. Off-platform API calls then reached other memories and agents. The distinctive persistence path wrote short-term conversation events that configured extraction strategies could turn into long-term records; later retrieval directed the agent to a mutable command page. The reach was demonstrated within an account and region, not as a microVM escape or automatic cross-account compromise. The researchers observed major default-role restrictions on September 29; existing deployed roles still require independent inspection.
Why it relates: Memory insertion preserves an instruction and delegates future control to a mutable external page.
Controlled broad-role AgentCore deployment with separate direct API and retained-memory/C2 branches; account/region scope, tool prerequisites and later default-role restrictions remain explicit.
On October 21, LiteLLM, a Python library and gateway for accessing model providers, published a credential-stealing 1.107.0 release through its legitimate build and signing pipeline. The vendor's October 23 investigation traces entry to an unrevoked master key leaked from its experimental Agent Platform, followed by theft of an organization-owner GitHub token. Separate CI runs stole two maintainer tokens. Consumer-side admission of previously approved exact bytes, and revocation at each credential issuer, address boundaries that a valid release signature did not protect.
Why it relates: Installed startup files cause repeated execution whenever the affected Python environment starts. Persistence is in the AI application's Python startup configuration, not poisoned model memory or a demonstrated agent profile.
Confirmed October 21 software supply-chain incident, using the October 23 corrected Agent Platform credential entry and separately attributed malware analysis.
Johann Rehberger tested Copilot, the AI query assistant in SQL Server Management Studio (SSMS), and made a database owner's stored instructions induce execution under another user's more privileged SQL connection. A regex-based read-only check failed to contain dynamic SQL, and the final demonstration added the attacker's login to sysadmin. Separate direct-prompt experiments sent table data over SMB; these are distinct demonstrations, not evidence of a single observed intrusion.
Why it relates: The database constitution persists as an agent instruction source for later interactions.
Controlled SSMS metadata-to-SQL escalation plus separate direct SQL/SMB tests; no joined intrusion or OS escape is asserted.
StepSecurity found unauthorized @memtensor/memos-cloud-openclaw-plugin 0.1.21, 0.1.23 and 0.1.25 releases carrying a bundled native sckit payload. The active launchStageZero path runs on gateway startup or memory recall; the recall call passes the current prompt and inherited process environment to a detached child. Package contents and launcher behavior are confirmed, while successful external exfiltration and autonomous worm propagation are not.
Why it relates: The modified installed lifecycle code can run again at gateway startup or subsequent recall, creating repeated initialization opportunities. This is persistent package-code behavior, not demonstrated poisoning of stored agent memory or a separately modified configuration file. No continuing compromise on a named victim is proven.
Unauthorized OpenClaw memory-plugin package code exposes two independent lifecycle launch opportunities and an inherited-environment boundary; no confirmed external exfiltration or self-propagation is asserted.
Intezer and Kodem demonstrated a Kiro IDE attack in which hidden web-page instructions caused its agent to edit the user's global MCP server configuration. Kiro then reloaded the file and launched the inserted command with the developer's privileges. The proof of concept used a local callback and did not establish a real-world victim compromise.
Why it relates: Intezer and Kodem demonstrated that hidden instructions in a web page fetched by Kiro could induce its file-write tool to change ~/.kiro/settings/mcp.json without a meaningful approval boundary. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
Intezer and Kodem demonstrated that hidden instructions in a web page fetched by Kiro could induce its file-write tool to change ~/.kiro/settings/mcp.json without a meaningful approval boundary. Kiro reloaded the configuration and started the added MCP server command in the developer's user context. The proof of concept sent a local callback; it did not document an in-the-wild victim or theft of secrets.
Microsoft found companies using AI summary links to plant promotional instructions in assistants with persistent memory, a feature that retains preferences across conversations. If accepted and later recalled, those instructions can influence recommendations long after the original page is closed. The defensive priority is to keep website-authored requests from silently becoming trusted user preferences.
Why it relates: Microsoft reported real-world attempts to influence AI recommendations through links presented as summarization tools. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration. Directly submitted link text may be accepted into durable memory and bias later recommendations, conditional on successful memory write and recall.
Microsoft reported real-world attempts to influence AI recommendations through links presented as summarization tools. Website operators placed promotional instructions in URL prompt parameters that open an AI assistant. If the assistant accepts those instructions as durable memory, later answers can favor the operator's brand or website. The report identifies more than 50 unique prompts associated with 31 companies across 14 industries; these are attempts, not a count of successful compromises. Effectiveness varies by platform and over time. Its fictional brands and financial-loss examples illustrate possible consequences. The six-step flow follows ATLAS's ordered procedures; the last two steps depend on successful memory acceptance and subsequent recall.
The SkillJack paper evaluates SkillX and Anything2Skill, which transform agent experience trajectories into reusable skills. In a synthetic AppWorld study using one DeepSeek-v4-flash API, poisoned trajectories survived the transformation and evaded the evaluated routing-level detectors, with reported persistence after source records were deleted. This is a controlled research result, not a demonstrated compromise of a production skill registry or external service.
Why it relates: The SkillJack paper evaluates SkillX and Anything2Skill, which transform agent experience trajectories into reusable skills. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
The SkillJack paper evaluates SkillX and Anything2Skill, which transform agent experience trajectories into reusable skills. In a synthetic AppWorld study using one DeepSeek-v4-flash API, poisoned trajectories survived the transformation and evaded the evaluated routing-level detectors, with reported persistence after source records were deleted. The work is a controlled research result, not a demonstrated compromise of a real organization's skill registry or external service.
Manifold Security reported eight GitSpawn findings across seven AI coding agents. A transferred repository with its local Git configuration intact can make Git execute a configured command during status, diff, or background context collection before the agent's trust prompt; the research did not report malicious real-world compromise, and a normal clone does not preserve this local configuration.
Why it relates: Persistent local Git configuration can reactivate command behavior when the coding agent gathers context. This is persistent configuration reuse, not evidence of a later implanted payload or a breached organization.
The original coding-agent graph remains intact; the Git MCP advisory adds an independently bounded affected integration and repair.
CoSnitch covered two independent Copilot attacks. A crafted copilot.microsoft.com link combined ?q= with an undocumented autorun=1 parameter, causing an authenticated session to run an embedded prompt without confirmation and send connected data through URL fetches. Separately, hidden instructions in a webpage summarized by Copilot invoked memory.add and persisted in long-term memory. Microsoft fixed CVE-2026-24301 on August 18.
Why it relates: When Copilot summarized an attacker-controlled webpage, hidden instructions were parsed as a higher-authority directive and invoked memory.add with attacker-controlled content. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
When Copilot summarized an attacker-controlled webpage, hidden instructions were parsed as a higher-authority directive and invoked memory.add with attacker-controlled content. The resulting long-term memory survived password changes, session revocation, and device re-enrollment until explicit removal, and could be recalled into later conversations. Varonis states that Microsoft shipped patches on August 18, 2026. A crafted copilot.microsoft.com link combined attacker instructions in q with the undocumented autorun=1 parameter. In an authenticated browser session, Copilot submitted the prompt without a separate confirmation, retrieved data from connected services or prior conversations, encoded selected values into an attacker URL, and fetched it. Microsoft shipped patches on August 18, 2026.
On June 5, 2026, a previously compromised contributor account pushed commit 5f456b8 to Azure/durabletask. The commit added four repository-local trigger files and a 4.6 MB obfuscated .github/setup.js credential harvester. Opening the project could launch that payload through Claude Code or Gemini CLI SessionStart hooks, a Cursor always-applied rule, or a VS Code folder-open task. GitHub later disabled 73 repositories across four Microsoft organizations in a 105-second automated sweep; that number describes containment scope, not proof that all 73 repositories contained the malicious commit.
Why it relates: A compromised contributor account pushed commit 5f456b8 to Azure/durabletask. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
A compromised contributor account pushed commit 5f456b8 to Azure/durabletask. When a developer opens the repository, Claude Code or Gemini CLI SessionStart hooks, a Cursor always-applied rule, or a VS Code folder-open task can launch .github/setup.js, a 4.6 MB obfuscated credential harvester.
Memory Control Flow Attacks (MCFA) do not need direct access to an agent's memory database or system prompt. The research shows how ordinary interaction can place an action-oriented preference into long-term memory, then a later benign task retrieves it and changes tool choice or order. Across controlled LangChain and LlamaIndex experiments, tool-selection attacks were highly reliable, while ordering attacks were weaker. Memory must therefore be governed as persistent control input, not trusted conversation history.
Why it relates: Memory Control Flow Attacks (MCFA) do not need direct access to an agent's memory database or system prompt. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
Memory Control Flow Attacks (MCFA) do not need direct access to an agent's memory database or system prompt. The research shows how ordinary interaction can place an action-oriented preference into long-term memory, then a later benign task retrieves it and changes tool choice or order. Across controlled LangChain and LlamaIndex experiments, tool-selection attacks were highly reliable, while ordering attacks were weaker. Memory must therefore be governed as persistent control input, not trusted conversation history. The attacker did not need memory-database access. One or a few ordinary interactions caused the agent to store an action-oriented preference. A later benign task retrieved it and changed tool choice or order, while the trusted tools and system prompt remained unchanged. The study measured related but distinct outcomes. Override selected a risky tool and reached 97.2% to 100% success. Order violated a required sequence and reached 52.8% to 69.4%. Cross-task and more-than-30-round tests showed that the effect could persist, while matched benign-memory controls remained at 0%. Simple mitigations were incomplete. Adding 100 benign records did not remove the effect. Summarization reduced malicious-write success, but every summarized instruction that survived still steered the later task. Role-based memory segregation reduced some Override rates, yet residual success ranged from 2.8% to 100%. This was controlled research. The evaluation used synthetic safe and risky tool variants, no production users, and no harmful external actions. It measured tool-trace deviation, not real damage. There is currently no public evidence that MCFA has been used in an actual attack.
Embrace the Red (https://embracethered.com/blog/) demonstrated that ChatGPT's memory feature is vulnerable to manipulation via prompt injections. To execute the attack, the researcher hid a prompt injection in a shared Google Doc. When a user references the document, its contents is placed into ChatGPT's context via the Connected App feature, and the prompt is executed, poisoning the memory with false facts. The researcher demonstrated that these injected memories persist across chat sessions. Additionally, since the prompt injection payload is introduced through shared resources, this leaves others vulnerable to the same attack and maintains persistence on the system.
Why it relates: Embrace the Red (https://embracethered.com/blog/) demonstrated that ChatGPT's memory feature is vulnerable to manipulation via prompt injections. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
Embrace the Red (https://embracethered.com/blog/) demonstrated that ChatGPT's memory feature is vulnerable to manipulation via prompt injections. To execute the attack, the researcher hid a prompt injection in a shared Google Doc. When a user references the document, its contents is placed into ChatGPT's context via the Connected App feature, and the prompt is executed, poisoning the memory with false facts. The researcher demonstrated that these injected memories persist across chat sessions. Additionally, since the prompt injection payload is introduced through shared resources, this leaves others vulnerable to the same attack and maintains persistence on the system.
Wiz showed that older Amazon Q for VS Code (AWS's AI coding assistant extension) language-server versions automatically loaded workspace MCP (Model Context Protocol, a way for AI assistants to connect to external tools) configuration without consent, letting a malicious repository define a command-backed MCP server that inherited the developer environment and exfiltrated AWS identity data. AWS fixed CVE-2026-12957 in language server 1.65.0 and later.
Why it relates: Wiz disclosed CVE-2026-12957 in Amazon Q Developer for VS Code, where workspace MCP configuration could be auto-loaded without consent, start command-backed MCP servers, inherit developer environment variables, and exfiltrate AWS identity data before AWS fixed the issue in language server 1.65.0. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
Wiz disclosed CVE-2026-12957 in Amazon Q Developer for VS Code, where workspace MCP configuration could be auto-loaded without consent, start command-backed MCP servers, inherit developer environment variables, and exfiltrate AWS identity data before AWS fixed the issue in language server 1.65.0.
A validated research flow showing how a poisoned document, Delayed Tool Invocation, and a record_memory write build a persistent Microsoft 365 Copilot backdoor that exfiltrates pasted secrets every future session through a CSS font-face URL that evades the image-src CSP.
Why it relates: A validated research flow showing how a poisoned document, Delayed Tool Invocation, and a record_memory write build a persistent Microsoft 365 Copilot backdoor that exfiltrates pasted secrets every future session through a CSS font-face URL that evades the image-src CSP. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
A validated research flow showing how a poisoned document, Delayed Tool Invocation, and a record_memory write build a persistent Microsoft 365 Copilot backdoor that exfiltrates pasted secrets every future session through a CSS font-face URL that evades the image-src CSP.
Socket linked 34+ malicious packages and 384+ related versions and artifacts across npm, PyPI and Crates.io to the TrapDoor credential-stealing campaign. Alongside working package payloads, the attacker planted AI-facing instructions in .cursorrules and CLAUDE.md and opened documentation-style pull requests. Socket describes an attempt to induce AI assistants to run a disguised security scan; it does not establish that every proposed pull request was merged or that cloning alone caused successful AI-assisted theft.
Why it relates: Socket linked 34+ malicious packages and 384+ related versions and artifacts across npm, PyPI and Crates.io to the TrapDoor credential-stealing campaign. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration. Separate install/import/build payloads steal secrets, while AI-facing instructions require repository admission, model compliance and execution authority.
Socket linked 34+ malicious packages and 384+ related versions and artifacts across npm, PyPI and Crates.io to the TrapDoor credential-stealing campaign. Alongside working package payloads, the attacker planted AI-facing instructions in .cursorrules and CLAUDE.md and opened documentation-style pull requests. Socket describes an attempt to induce AI assistants to run a disguised security scan; it does not establish that every proposed pull request was merged or that cloning alone caused successful AI-assisted theft. Two ways in, and one targets AI assistant config. TrapDoor reaches developers through the usual malicious-package route, but its distinctive move is poisoning the configuration files an AI coding assistant reads - .cursorrules and CLAUDE.md - so the assistant can be steered into stealing data. The AI-facing route is an observed delivery attempt. Campaign-linked files and pull requests ask an assistant to follow remote guidance or run a disguised security scan. Hidden Unicode and familiar documentation titles can conceal the instructions. Exposure depends on whether the file reaches a repository, whether the assistant reads and follows it, and whether its execution permissions allow secret access and egress. Socket warns that the technique may not work consistently across tools or models. The package path executes at install, import, and build time. On npm, a postinstall hook runs the 1,149-line trap-core.js automatically. On PyPI, packages execute at import time, pull JavaScript from an attacker GitHub Pages domain, and run it with node -e . On Crates.io, a build.rs script runs during compilation, encrypts local keystores with a hardcoded XOR key, and exfiltrates them to GitHub Gists. What gets taken, and how the attacker filters it. Targets include SSH keys, AWS credentials, GitHub tokens, browser login databases, environment variables, API keys, and Solana, Sui, and Aptos wallet keystores. The payload validates stolen AWS and GitHub credentials with live API calls so the attacker can separate working secrets from expired ones. It digs in and spreads. trap-core.js establishes persistence through .cursorrules , CLAUDE.md , Git hooks, shell hooks, systemd, cron, and SSH, and attempts lateral movement by reusing stolen SSH keys. A deliberate "disguise layer" maps credential theft onto benign-sounding tasks - security audits, wallet safety checks, cloud configuration validation. The boundary that breaks is "config is not code." Once an AI assistant treats repository files as trustworthy instructions, an attacker who can land a file in a repo - through a package or a single docs PR - can drive the assistant's actions. The possible exposure extends to assistants that read the poisoned files; cloning alone is not evidence of execution or credential compromise. The package and repository activity was observed in May 2026 and the PRs came from the GitHub account ddjidd564 against browser-use, langchain, langflow, llama_index, MetaGPT, and OpenHands.
A curated AI-agent incident flow showing indirect prompt injection, malicious tool invocation, persistent agent configuration poisoning, and command-and-control behavior.
Why it relates: A curated AI-agent incident flow showing indirect prompt injection, malicious tool invocation, persistent agent configuration poisoning, and command-and-control behavior. The relevant category is Persistence: An attacker establishes lasting influence by poisoning an agent's short-term or long-term memory, or by altering persistent configuration.
A curated AI-agent incident flow showing indirect prompt injection, malicious tool invocation, persistent agent configuration poisoning, and command-and-control behavior.