arXiv:2602.09182cs.CRcs.LG2026-02中稿 · publication at the…

随机数生成器成机器学习新攻击入口,工具可自动加固系统

One RNG to Rule Them All: How Randomness Becomes an Attack Vector in Machine Learning

  • 从对抗视角分析框架中随机数生成器的漏洞
  • 实测验证多个主流框架存在可被利用的随机性缺陷
  • 提供低门槛工具RNGGuard实现代码级安全防护

机器学习依赖随机数生成器(PRNG)完成数据采样、权重初始化和优化等关键步骤。主流框架采用伪随机数生成器,但因设计差异、依赖库和硬件后端不一致,且缺乏统计验证,导致潜在的隐蔽攻击向量。此类攻击在真实系统中已有先例。本文从对抗角度分析机器学习开发流程中的随机性风险,评估主流框架中PRNG的实现。提出RNGGuard工具,通过静态分析识别易受攻击的随机函数调用,并在运行时以符合安全规范的实现替代不安全调用。实验表明,RNGGuard能有效弥补当前机器学习系统在随机数源安全性上的空白,是一种实用的防护方案。

原文摘要 · Abstract (English)

Machine learning relies on randomness as a fundamental component in various steps such as data sampling, data augmentation, weight initialization, and optimization. Most machine learning frameworks use pseudorandom number generators as the source of randomness. However, variations in design choices and implementations across different frameworks, software dependencies, and hardware backends along with the lack of statistical validation can lead to previously unexplored attack vectors on machine learning systems. Such attacks on randomness sources can be extremely covert, and have a history of exploitation in real-world systems. In this work, we examine the role of randomness in the machine learning development pipeline from an adversarial point of view, and analyze the implementations of PRNGs in major machine learning frameworks. We present RNGGuard to help machine learning engineers secure their systems with low effort. RNGGuard statically analyzes a target library's source code and identifies instances of random functions and modules that use them. At runtime, RNGGuard enforces secure execution of random functions by replacing insecure function calls with RNGGuard's implementations that meet security specifications. Our evaluations show that RNGGuard presents a practical approach to close existing gaps in securing randomness sources in machine learning systems.

机器学习安全随机数生成攻击向量

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