Reproduce “CoTDeceptor:Adversarial Code Obfuscation Against CoT-Enhanced LLM Code Agents” on OpenResearch

Turn your favorite coding agents into research agents that review literature, develop hypotheses, and run experiments.

Universal app for Apple silicon and Intel. Requires macOS 11 or later.

About this paper

Haoyang Li, Mingjin Li, Jinxin Zuo, Siqi Li, Xiao Li, Hao Wu, Yueming Lu, Xiaochuan He

An agentic-reinforcement learning framework, CoTDeceptor, systematically generates adversarial code obfuscations that exploit weaknesses in Chain-of-Thought (CoT) reasoning. It successfully evades both state-of-the-art CoT-enhanced Large Language Model (LLM) vulnerability detectors and traditional static analysis tools, demonstrating stable evasion across various vulnerability categories and LLM architectures.

Key insights

  • The interpretability of CoT-enhanced LLMs, intended for transparency and robustness, inadvertently creates an exploitable attack surface by exposing their internal reasoning chains.
  • Adaptive, iterative adversarial obfuscation can induce reasoning instability, semantic misinterpretation, and hallucination in even the most advanced CoT-based LLM detectors.
  • Iterative strategy evolution allows weaker generator models to successfully mislead more capable LLM detectors, demonstrating transferability of adversarial techniques and the potential for co-evolutionary security improvements.

Summary by alphaXiv.

Tip: change arxiv.org to autoarxiv.org in any arXiv abstract link to open the paper here.