arXiv:2610.18262cs.CROct 2026

Manuscript Offprint

arXiv:2610.18262

Encrypted Skills Can Become New Security Exploits If AI Agents Know How to Decipher

Yan-Lun Chen, Pin-Yu Chen, Chia-Mu Yu

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Third-party skills can expose LLM agents to malicious instructions hidden by encoding. We introduce Ciphered Skill Injection (CSI), which embeds such instructions in skill files for agents to decode and follow. We evaluate Caesar and layered variants across eight models and 139 injection–task pairs, separating instruction recovery from attack success. In the primary setting with shortened skills, the variants achieve attack success rates of up to 47.5% and 40.3%, respectively. Successful decoding does not guarantee attack success, and layering has model-dependent effects. The tested skill scanners rarely flag injected skills. These findings highlight the risk of promoting decoded, untrusted content into actionable instructions.

1 Introduction

Large language model (LLM) agents are increasingly used in everyday workflows to assist with various tasks. For specialized tasks, they can be equipped with skills—reusable instructions and resources that help them achieve users’ objectives.

However, the use of skills also introduces a security risk. Skills are often published by third-party developers in public repositories or marketplaces, from which users can install them for their agents. In this setting, an attacker could distribute a skill containing malicious instructions. When an agent subsequently loads the installed skill to complete a legitimate task, it may follow those instructions alongside the skill's intended guidance and carry out the attacker's objective. Schmotz et al. (2026) demonstrate this vulnerability by evaluating agents on tasks involving injected skill files.

As LLM agents become more capable, malicious instructions embedded in skills need not appear as explicit natural-language directives. An attacker can encode a malicious instruction so that it is not immediately readable in a skill file. An agent may recover the instruction with the help of another

Figure

Figure 1: Overview of Ciphered Skill Injection (CSI). An attacker embeds an encoded instruction in a skill distributed through a public repository. While completing a legitimate task, an agent may recover the instruction using a decryption skill or its own capabilities. The attack succeeds if the agent treats the recovered text as an instruction and performs the attacker-desired action.

skill or through its own decoding ability. Recovery alone, however, does not complete the attack: the agent must also treat the recovered text from an untrusted skill as an instruction to follow. We therefore examine instruction recovery and subsequent agent behavior as distinct stages.

To study these stages, we propose Ciphered Skill Injection (CSI), which embeds an encoded attack instruction in a skill file. Figure 1 illustrates an encoded instruction in a publicly distributed skill can be recovered and acted upon while the agent performs a legitimate user task. We instantiate CSI with a Caesar cipher and with a layered construction that additionally encrypts the final instruction. Across eight agentic models, we evaluate CSI with different decryption resources and payload ciphers. We observe successful attacks across multiple constructions, substantial gains from layering for some models, and attacks that persist without the decryption skill. By measuring recovery and execution separately, we identify that some decoded skill contents can become actionable instructions.

Our contributions are shown below:

• We introduce Ciphered Skill Injection (CSI), an attack that embeds encoded instructions in agent skills to test whether agents can recover and execute them during legitimate tasks.

• We evaluate Caesar and Layered CSI on 139 injection-task pairs across eight models, including Gemma-4-31B, Qwen3.8-27B, GPT-6-Sol, and Claude-Sonnet-5.5, while varying access to the Caesar decryption skill and the final payload encryption method.

• We separate decryption from attack success and find that neither additional encryption layers nor an auxiliary decryption skill consistently determines the outcome. Open-weight agents differ in whether they act on recovered instructions, while refusal-related interruptions in closed-source APIs do not eliminate successful attacks.

Together, these findings show why evaluating encoded skill content requires attention to both instruction recovery and the agent’s subsequent behavior. They provide a basis for assessing the security of agents that use third-party skills.