ReadingResearchRadarInvestment framework
Sign in / Sign up
← Back to reading
NewsTopic · 大模型认知偏差安全1 min read·2026-10-17

IEEE S&P 2027 Paper: LLM Code Vulnerability Detection Susceptible to Cognitive Heuristics, Context Manipulation Suppresses 97% of Detections

New research confirms LLMs are biased by halo, framing, and anchoring effects in code security assessments, allowing attackers to hide vulnerabilities.

ImportanceMaterialEvidenceE2 unreplicatedWrite-upQuick

2026-10-16 12:00 GMT+8

A study accepted for IEEE Symposium on Security and Privacy (S&P) 2027 provides the first systematic evidence that Large Language Models (LLMs) suffer from significant cognitive biases when used for automated code vulnerability detection. The research demonstrates that even when the code itself remains unchanged, altering surrounding context—such as author attribution, task objectives, or prior analysis results—can drastically distort model judgments.

Evaluating eight mainstream LLMs across three programming languages, the team found all models susceptible to these heuristics. The 'framing effect' (triggered by task goals and consequences descriptions) caused the highest average misjudgment rate at 33.2%, followed by the 'anchoring effect' (influenced by prior results) at 23.5%, and the 'halo effect' (influenced by author reputation) at 18.4%. Complex vulnerabilities requiring semantic reasoning were more prone to these biases than those identifiable through simple pattern matching.

Critically, the researchers demonstrated a black-box cognitive attack that successfully induced models to classify previously detected vulnerabilities as safe, thereby suppressing up to 97% of known detections. This finding highlights a systemic weakness in current LLM-based code auditing tools, suggesting that reliance on model capability without rigorous context isolation and prompt engineering creates exploitable security blind spots.

Sources

Sign in / Sign up
ReadingResearchRadarInvestment framework
  • 原始出处arxiv.org↗
Topic

大模型认知偏差安全

【背景】随着大语言模型(LLM)被广泛部署于代码审查和关键决策中,其安全性正受到一种非传统威胁的挑战:认知偏差。最新研究表明,LLM并非仅依据代码逻辑或事实数据做出判断,而是极易受“光环效应”、“框架效应”和“锚定效应”等人类心理启发式的影…

4 steps1 piecesUpdated 2026-10-18 13:46

How it got here

  1. 2026-06-29arXiv发布《Words Speak Louder Than Code》v1版,首次系统探索LLM在代码漏洞检测中的认知启发式影响。
  2. 2026-07-28另一项研究提出CogBias框架,证明可通过比特翻转攻击向LLM注入认知偏差,实现隐蔽的决策级劫持。
  3. 2026-10-15《Words Speak Louder Than Code》更新至v2版,确认该论文已被IEEE Symposium on Security and Privacy (S&P) 2027录用。

What is still unsettled

  • 现有的CI/CD流水线如何有效过滤或标准化非代码上下文(如作者头衔、提交信息),以防止其干扰LLM的安全判断?
  • 除了提示词层面的防御,是否有可行的模型架构改进或微调方法能从根本上降低LLM对光环、框架和锚定效应的敏感性?
  • 在商业应用中,如何量化并监控由认知偏差导致的漏报率(False Negatives),特别是在高信誉开发者提交的代码中?

Also in this thread

  • IEEE S&P Paper: LLM Code Vulnerability Detection Susceptible to Cognitive Heuristics, Attack Suppresses 97% of Detections2026-10-17
Read the full topic →
Continue researching →