mlsanityData to 14 Oct 2026

Inverting Trojans in LLMs

arXiv 2509.16203 ↗First posted 19 Sep 2025cs.LGcited by 0

On the map: LLM safety and security → Backdoor and data poisoning attacks

Abstract (arXiv)

While effective backdoor detection and inversion schemes have been developed for AIs used e.g. for images, there are challenges in "porting" these methods to LLMs. First, the LLM input space is discrete, which precludes gradient-based search over this space, central to many backdoor inversion methods. Second, there are ~30,000^k k-tuples to consider, k the token-length of a putative trigger. Third, for LLMs there is the need to blacklist tokens that have strong marginal associations with the putative target response (class) of an attack, as such tokens give false detection signals. However, good blacklists may not exist for some domains. We propose a LLM trigger inversion approach with three key components: i) discrete search, with putative triggers greedily accreted, starting from a select list of singletons; ii) implicit blacklisting, achieved by evaluating the average cosine similarity, in activation space, between a candidate trigger and a small clean set of samples from the putative target class; iii) detection when a candidate trigger elicits high misclassifications, and with unusually high decision confidence. Unlike many recent works, we demonstrate that our approach reliably detects and successfully inverts ground-truth backdoor trigger phrases.

Key facts. No citing papers in the map yet (data through 14 Oct 2026). Placed in Backdoor and data poisoning attacks, one of 12 directions in LLM safety and security. Builds on 6 of its 13 references that are in the map. First posted on arXiv 19 Sep 2025.

Builds on

6 of 13 references.

Closest ancestors · 3

Same direction, newest first

  1. 2024CLIBE: Detecting Dynamic Backdoors in Transformer-based NLP Models2 Sep
  2. 2024BEEAR: Embedding-based Adversarial Removal of Safety Backdoors in Instruction-tuned Language Models24 Jun
  3. 2022Constrained Optimization with Dynamic Bound-scaling for Effective NLPBackdoor Defense11 Feb

Other references · 3

  1. 2020ONION: A Simple and Effective Defense Against Textual Backdoor Attackscited by 263
  2. 2024Task-Agnostic Detector for Insertion-Based Backdoor Attackscited by 23
  3. 2019Detection of Backdoors in Trained Classifiers Without Access to the Training Setcited by 7

Built on by

Not cited yet.

Similar, not cited

Close in wording, no citation either way

  1. 2026CSO-LLM: Class Subspace Orthogonalization for Post-Training Backdoor Detection and Trigger Inversion in LLMs
  2. 2025DISTIL: Data-Free Inversion of Suspicious Trojan Inputs via Latent Diffusion
  3. 2021Trigger Hunting with a Topological Prior for Trojan Detection
  4. 2025Trojan Detection Through Pattern Recognition for Large Language Models
  5. 2022An Adaptive Black-box Backdoor Detection Method for Deep Neural Networks
  6. 2022Rethinking the Reverse-engineering of Trojan Triggers
  7. 2024Trojan Detection in Large Language Models: Insights from The Trojan Detection Challenge
  8. 2026Token-Level Generalization in LoRA Adapter Backdoors: Attack Characterization and Behavioral Detection