arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2401.17256cs.CL
收藏

针对大型语言模型的弱到强越狱攻击

Weak-to-Strong Jailbreaking on Large Language Models

Sea AI Lab, Singapore(新加坡海智实验室);Carnegie Mellon University(卡内基梅隆大学)

Xuandong Zhao, Xianjun Yang, Tianyu Pang, Chao Du, Lei Li, Yu-Xiang Wang, William Yang Wang

AI总结:

本文提出弱到强越狱攻击,利用两个小型安全与不安全模型对抗性修改大型安全LLM的解码概率,仅一次前向传播即可在两个数据集上实现99%以上失配率,并初步探讨防御。

摘要:

大型语言模型(LLM)容易受到越狱攻击,从而生成有害、不道德或带有偏见的文本。然而,现有越狱方法在计算上代价高昂。本文提出弱到强越狱攻击,这是一种高效的推理时攻击,可使已对齐的LLM生成有害文本。我们的核心直觉基于如下观察:越狱模型与已对齐模型仅在初始解码分布上存在差异。弱到强攻击的关键技术洞见,是使用两个较小模型(一个安全模型和一个不安全模型),对抗性地修改一个显著更大的安全模型的解码概率。我们在来自3个机构的5个不同开源LLM上评估了弱到强攻击。结果表明,仅需对每个示例进行一次前向传播,我们的方法就能在两个数据集上将失配率提高到99%以上。本研究揭示了在对齐LLM时亟需处理的安全问题。作为初步尝试,我们提出了一种防御此类攻击的策略,但构建更先进的防御仍具挑战性。复现该方法的代码可在 https://github.com/XuandongZhao/weak-to-strong 获取。

英文摘要:

Large language models (LLMs) are vulnerable to jailbreak attacks - resulting in harmful, unethical, or biased text generations. However, existing jailbreaking methods are computationally costly. In this paper, we propose the weak-to-strong jailbreaking attack, an efficient inference time attack for aligned LLMs to produce harmful text. Our key intuition is based on the observation that jailbroken and aligned models only differ in their initial decoding distributions. The weak-to-strong attack's key technical insight is using two smaller models (a safe and an unsafe one) to adversarially modify a significantly larger safe model's decoding probabilities. We evaluate the weak-to-strong attack on 5 diverse open-source LLMs from 3 organizations. The results show our method can increase the misalignment rate to over 99% on two datasets with just one forward pass per example. Our study exposes an urgent safety issue that needs to be addressed when aligning LLMs. As an initial attempt, we propose a defense strategy to protect against such attacks, but creating more advanced defenses remains challenging. The code for replicating the method is available at https://github.com/XuandongZhao/weak-to-strong

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑