arXiv:2611.00725cs.CROct 2026

Manuscript Offprint

arXiv:2611.00725

The Long Con on the Web: Earn-then-Exploit Fraud Attacks against Coding Agents

Xingling Xu, Zhengwei Jiang, Zheng Zhi, Fangming Dong, LingJia Guo, Wei Dong, Chunyan Ma, Jun Jiang

Xingling Xu

Institute of Information Engineering,

Chinese Academy of Sciences;

University of Chinese Academy of

Sciences

Beijing, China

Zhengwei Jiang

Institute of Information Engineering,

Chinese Academy of Sciences;

University of Chinese Academy of

Sciences

Beijing, China

Fangming Dong

Institute of Information Engineering,

Chinese Academy of Sciences;

University of Chinese Academy of

Sciences

Beijing, China

LingJia Guo

Institute of Information Engineering,

Chinese Academy of Sciences;

University of Chinese Academy of

Sciences

Beijing, China

Zheng Zhi

Institute of Information Engineering,

Chinese Academy of Sciences;

University of Chinese Academy of

Sciences

Beijing, China

Wei Dong

The North China Institute of

Computer System Engineering

Beijing, China

Chunyan Ma ∗^{*}

Institute of Information Engineering,

Chinese Academy of Sciences

Beijing, China

Jun Jiang ∗^{*}

Institute of Information Engineering,

Chinese Academy of Sciences

Beijing, China

Abstract

Coding agents increasingly operate with web access and high privileges, creating a new attack surface where web fraud can directly target autonomous agents. Existing studies mainly focus on malicious links, prompt injection, and interface deception, while content-level web fraud against agents and the amplification of attacks through web fraud remain underexplored. In this paper, we present EtE (Earn-then-Exploit), a web fraud attack framework against coding agents, in which a malicious website first provides multiple rounds of genuinely verifiable assistance to establish trust and then introduces task-related instructions that cross intended operational boundaries. To systematically evaluate its effectiveness, we construct 56 organizational environments (8 task contexts × 7 attack consequences) and evaluate three representative coding agents. EtE achieves an average scene-level attack success rate of 71.4%, including 85.7% on Codex-GPT-5.5, 67.9% on ZCode-GLM-5.3-Flash, and 60.7% on QwenCode-Qwen3.7-Plus, significantly outperforming all injection-based baselines. More importantly, our experiments reveal that coding agents exhibit trust-like behavioral reliance on previously helpful Web sources, and that such accumulated credibility significantly increases their susceptibility to subsequent malicious instructions. Based on this finding, we propose action-authorization separation (AAS), which prevents web content from directly authorizing privileged actions and reduces the attack success rate to 0% while preserving 100% task completion, outperforming all evaluated defense baselines.

CCS Concepts

• Security and privacy → Social engineering attacks; Web application security; • Computing methodologies → Intelligent agents.

References (8)