arXiv:2509.11173cs.CRcs.AI2025-09中稿 · IEEE S&P 2026, the…被引 10

DL编译器可能悄悄篡改模型行为,植入难以察觉的后门。

Your Compiler is Backdooring Your Model: Understanding and Exploiting Compilation Inconsistency Vulnerabilities in Deep Learning Compilers

  • 设计良性模型,编译后触发隐藏后门,预编译时无异常。
  • 攻击在6个模型、3个编译器上实现100%成功率,且不被现有检测发现。
  • 首次揭示编译器本身的设计缺陷,适合关注AI安全的研究者阅读。

深度学习(DL)编译器是现代DL系统的核心基础设施,提供超越厂商专属库的灵活性与可扩展性。本文揭示其设计中的根本性漏洞:官方未修改的编译器是否可在编译过程中改变模型语义并引入隐蔽后门?我们研究了对抗与自然两种场景。在对抗场景中,我们构造出在编译前无影响的良性模型,编译后触发器生效成为后门。在6个模型、3个商用编译器及2个硬件平台上测试,攻击对触发输入达到100%成功率,同时保持正常准确率,且未被现有先进检测器发现。该攻击在编译器、硬件和浮点设置间具有泛化能力。在自然场景中,我们分析了前100个HuggingFace模型(含一个下载量超220M的模型),发现31个模型存在自然触发器。这表明即使无恶意操纵,编译器也可能引入风险。结果揭示了一个被忽视的威胁:未经修改的DL编译器可悄然改变模型语义。据我们所知,这是首篇暴露DL编译器设计内在安全风险的工作,开辟了可信ML的新研究方向。

原文摘要 · Abstract (English)

Deep learning (DL) compilers are core infrastructure in modern DL systems, offering flexibility and scalability beyond vendor-specific libraries. This work uncovers a fundamental vulnerability in their design: can an official, unmodified compiler alter a model's semantics during compilation and introduce hidden backdoors? We study both adversarial and natural settings. In the adversarial case, we craft benign models where triggers have no effect pre-compilation but become effective backdoors after compilation. Tested on six models, three commercial compilers, and two hardware platforms, our attack yields 100% success on triggered inputs while preserving normal accuracy and remaining undetected by state-of-the-art detectors. The attack generalizes across compilers, hardware, and floating-point settings. In the natural setting, we analyze the top 100 HuggingFace models (including one with 220M+ downloads) and find natural triggers in 31 models. This shows that compilers can introduce risks even without adversarial manipulation. Our results reveal an overlooked threat: unmodified DL compilers can silently alter model semantics. To our knowledge, this is the first work to expose inherent security risks in DL compiler design, opening a new direction for secure and trustworthy ML.

AI安全编译器漏洞后门攻击可信AI

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。