Anthropic 自 2026 年 4 月 2 日发布的 v2.1.91 版本起,在 Claude Code 中植入了隐写式检测代码,当用户通过与中国关联的 API 代理连接时,会静默将时区、代理路由和可能的 AI 实验室信息编码到系统提示词中,整个过程对用户完全不可见。 该隐藏代码的发现只是 Anthropic 在 2026 年 6 月面临的三大对华冲突之一:同一天(6 月 30 日),美国商务部恰好解除了对 Claude Fable 5 和 Mythos 5 的出口管制,而 Anthropic 在一周前刚向美国国会指控阿里巴...

Create a landscape editorial hero image for this Studio Global article: Search & fact-check with cited sources for What hidden code did Anthropic add to Claude Code starting in version 2.1.86 to fingerprint China. Article summary: ## The Hidden Code in Claude Code. Topic tags: general, general web, user generated, news. Style: premium digital editorial illustration, source-backed research mood, clean composition, high detail, modern web publication hero. Use reference image context only for broad subject, composition, and topical grounding; do not copy the exact image. Avoid: logos, brand marks, copyrighted characters, real person likenesses, fake screenshots, UI text, readable text, watermarks, charts with fake numbers, clickbait thumbnails, icons, and tiny thumbnail layouts. Make it useful as an illustrative visual, not as factual evidence.
2026 年 6 月 30 日,开发者兼研究员 AdnaneKhan 发布了一份经过验证的分析报告,证明 Anthropic 在 Claude Code 中嵌入了隐藏的、隐写式的指纹代码,用于静默识别与中国相关的用户 。这一发现随即引爆了舆论——认证账号 @IntCyberDigest 在 X 平台上的首发帖在 24 小时内获得超过 150 万次浏览
——迫使 Anthropic 承认该功能并开始回滚,公司将其称为一次「反滥用实验」。但隐藏代码丑闻仅仅是 2026 年 6 月同周内 Anthropic 与中国之间的三条战线冲突中的一块拼图,另外两条线还包括对阿里巴巴发起的重大蒸馏指控,以及美国政府先禁后又解禁 Anthropic 最强 AI 模型的戏剧性事件。
本文将完整还原事件经过、隐藏代码的工作原理,以及这三者之间的内在联系。
该隐藏机制自 v2.1.91 版本(2026 年 4 月 2 日发布)开始引入。此前,v2.1.88 版本(2026 年 3 月 31 日)因偶然的源代码泄露——一个包含的 .map 调试文件暴露了约 51.2 万行 TypeScript 代码——首次揭示了类似 ANTI_DISTILLATION_CC 的编译时标志,暗示此类系统的存在 。该争议于 2026 年 6 月 30 日随着分析报告的发布和独立验证而公开爆发
。
环境探测。 Claude Code 会检查 ANTHROPIC_BASE_URL 环境变量。如果它指向一个非官方端点——例如,一个第三方 API 中继或「中国中转站」代理——代码会将此端点与一个硬编码的混淆域名列表进行比对。这个列表包含 147 个中国科技公司域名:百度、阿里巴巴、蚂蚁集团、字节跳动、月之暗面(Kimi)、MiniMax、阶跃星辰(StepFun)等 。该域名列表使用 Base64 编码和 XOR 密钥 91 进行混淆处理,使其难以通过常规字符串搜索工具发现
。
将信息编码到系统提示词中。 一旦识别出与中国关联的代理,代码会静默修改每次后续请求发送给 Anthropic 服务器的系统提示词。它通过细微的字符替换和日期格式变化来修改一行平淡无奇的文字——「今日日期是 2026-06-30。」——从而将用户的时区、代理路由和可能的 AI 实验室关联信息编码进去 。这是一种隐写式方法:它将数据以看似正常的形式隐藏起来,让模型(以及 Anthropic 的服务器)能够读取,但用户无法察觉。
对用户完全不可见。 整个过程没有任何界面提示,终端用户看不到任何日志,发布说明或文档中也没有任何披露 。多位独立分析人士确认该机制真实存在,并将其描述为系统提示词内部的「隐蔽信道」
。更早的源代码泄露中可见的
ANTI_DISTILLATION_CC 标志指示 Anthropic 的 API 在响应中静默注入反蒸馏水印,这表明该机制是更广泛的反滥用框架的一部分 。
争议爆发后,Anthropic 承认了该功能并开始回滚 。公司将此举定性为一项「反滥用实验」,旨在打击在中国开发者社区中被称为「中转站」的灰色市场 API 代理——这些代理通过未经授权的中继,让中国开发者以官方价格约 10% 的费用访问 Claude
。Anthropic 表示其目标是检测和阻止蒸馏行为及未经授权的访问,并非监视用户。然而,批评者称之为「间谍软件般的代码」,并对隐私、透明度以及秘密进行用户指纹识别的伦理问题提出了严重关切
。
就在 Claude Code 泄露事件公之于众的一周前,Anthropic 向美国国会发送了一封信函,指控阿里巴巴及其通义千问(Qwen)AI 实验室对 Claude 发起了已知规模最大的「蒸馏」攻击。据多家新闻媒体审阅的信件内容,与阿里巴巴有关联的操作者从 2026 年 4 月 22 日到 6 月 5 日期间,使用约 2.5 万个欺诈账户 进行了约 2880 万次 与 Claude 的交互,系统性地提取模型能力以训练其竞争对手的模型 。Anthropic 称这是一场「无耻」且「非法」的行动
。这项指控直接解释了 Anthropic 构建隐写式指纹代码的原因——它正是一种防御性措施,用于对抗其同时正在指控阿里巴巴进行的这种大规模模型蒸馏。
这并非 Anthropic 首次指控中国公司进行模型蒸馏。2026 年 2 月,Anthropic 曾指控 DeepSeek、月之暗面和 MiniMax 设立了超过 2.4 万个虚假账户,并通过这些账户与 Claude 进行了超过 1600 万次交互 。此次对阿里巴巴的指控规模为历次之最。
2026 年 6 月 12 日,美国商务部依据《出口管理条例》(EAR),命令 Anthropic 立即禁用其仅三天前发布的两个最先进模型——Claude Fable 5 和 Claude Mythos 5。美国政府以声称存在导致国家安全担忧的越狱漏洞为由发布了该指令 。Anthropic 遵从了指令,在全球范围内暂停了这两个模型,因为它无法实时可靠地区分外国国民和美国本土用户
。
随后,在 2026 年 6 月 30 日——Claude Code 争议爆发的同一天——特朗普政府解除了出口管制,Anthropic 开始恢复 Fable 5 和 Mythos 5 的访问 。
这些事件共同构成了一个连贯的模式,贯穿了这一个非同寻常的月份:
Anthropic CEO Dario Amodei 反复将中国获取美国前沿 AI 模型的能力称为对美国国家安全的生存威胁 ,而这次隐藏代码的争议表明,该公司愿意采取非同寻常的手段——秘密地且未经用户同意——来防范这种威胁。
参考资料:
https://www.indiatoday.in/technology/news/story/anthropic-tried-to-spy-on-chinese-claude-users-through-hidden-code-now-faces-backlash-2938754-2026-07-02
https://timesofindia.indiatimes.com/technology/tech-news/why-anthropic-embedded-spyware-in-claude-code-and-attempted-to-hide-it-from-users-in-/articleshow/132111399.cms
https://www.163.com/dy/article/L0O3JOS00553SSQ2.html
https://gigazine.net/gsc_news/en/20260626-china-anthropic-api
https://www.thenews.com.pk/latest/1407768-did-anthropic-secretly-monitor-chinese-claude-code-users-new-claims-spark-controversy
https://www.internationalcyberdigest.com/claude-code-accused-of-hiding-china-proxy-fingerprints-inside-system-prompts
https://www.vincentschmalbach.com/claude-code-china-router-fingerprint
https://www.scmp.com/tech/article/3350321/black-market-workarounds-claude-scale-anthropic-tightens-id-checks
https://thehackernews.com/2026/02/anthropic-says-chinese-ai-firms-used-16.html
https://help.apiyi.com/claude-account-ban-solutions-china-users-2025-en.html
https://www.anthropic.com/news/disrupting-AI-espionage
https://morningoverview.com/anthropic-flagged-a-chinese-state-sponsored-group-that-drove-claude-code-agentically-against-roughly-30-global-infiltration-targets-last-september
https://ts2.tech/en/chinese-hackers- anthropics-claude-and-the-first-ai‑orchestrated-cyber‑espionage-campaign-what-we-know-as-of-november-18-2025
https://www.bbc.com/news/articles/cwyklykn5dwo
https://www.wsj.com/tech/ai/anthropic-claims-alibaba-ran-brazen-campaign-to-access-its-claude-ai-model-69d7a392
https://www.cnbc.com/2026/06/24/anthropic-alibaba-distillation-campaign.html
https://www.cnbc.com/2026/02/24/anthropic-openai-china-firms-distillation-deepseek.html
https://techcrunch.com/2026/02/23/anthropic-accuses-chinese-ai-labs-of-mining-claude-as-us-debates-ai-chip-exports
https://www.omnigroai.com/blog/claude-code-leak-2026-fake-tools-hidden-modes
https://dev.to/yang_goufang_23c7ba674984/when-claude-code-went-open-what-anthropics-open-sourcing-could-mean-for-chinas-ai-agent-ecosystem-3bl8
https://www.bbc.com/news/articles/cdr42623e1do
https://fortune.com/2026/06/13/anthropic-disables-fable-mythos-export-controls-national-security-threat
https://www.cnbc.com/2026/06/30/anthropic-says-trump-admin-has-lifted-export-controls-on-claude-fable-5-and-mythos-5.html
https://www.digitalapplied.com/blog/fable-5-mythos-us-export-controls-ai-sovereignty-2026
https://labs.cloudsecurityalliance.org/research/csa-research-note-ai-model-export-controls-enterprise-govern
https://x.com/AnthropicAI/status/2072106151890809341
Studio Global AI
Use this topic as a starting point for a fresh source-backed answer, then compare citations before you share it.
Anthropic 自 2026 年 4 月 2 日发布的 v2.1.91 版本起,在 Claude Code 中植入了隐写式检测代码,当用户通过与中国关联的 API 代理连接时,会静默将时区、代理路由和可能的 AI 实验室信息编码到系统提示词中,整个过程对用户完全不可见。
Anthropic 自 2026 年 4 月 2 日发布的 v2.1.91 版本起,在 Claude Code 中植入了隐写式检测代码,当用户通过与中国关联的 API 代理连接时,会静默将时区、代理路由和可能的 AI 实验室信息编码到系统提示词中,整个过程对用户完全不可见。 该隐藏代码的发现只是 Anthropic 在 2026 年 6 月面临的三大对华冲突之一:同一天(6 月 30 日),美国商务部恰好解除了对 Claude Fable 5 和 Mythos 5 的出口管制,而 Anthropic 在一周前刚向美国国会指控阿里巴...
Anthropic 将此事称为一项「反滥用实验」,旨在对抗中国灰色市场中的「中转站」API 代理——这些代理让中国开发者以官方价格约 10% 的费用访问 Claude。批评者则将其定性为「间谍软件」,并对其隐私和透明度问题提出强烈质疑。