通过操控推理初始令牌,实现对大模型的隐蔽越狱攻击
ShallowJail: Steering Jailbreaks against Large Language Models
- 利用大模型浅层对齐漏洞,操纵推理初期的输入令牌
- 在多个主流大模型上实现高成功率越狱,显著降低安全性
- 无需复杂计算,黑盒攻击,适合安全评估与防御研究
大语言模型(LLMs)在众多领域取得成功,通常通过对齐机制防止其产生有害内容。然而,对齐后的模型仍易受越狱攻击影响,攻击者可通过精心设计的提示诱导模型输出有害内容。现有越狱方法要么为黑盒,依赖明显且不隐蔽的提示;要么为白盒,需大量计算资源。针对这些挑战,我们提出ShallowJail,一种利用大模型浅层对齐特性的新型攻击方法。该方法通过操控推理过程中的初始令牌,误导模型生成有害响应。大量实验表明,ShallowJail能显著削弱当前先进大模型的安全性。代码已开源:https://github.com/liuup/ShallowJail。
原文摘要 · Abstract (English)
Large Language Models(LLMs) have been successful in numerous fields. Alignment has usually been applied to prevent them from harmful purposes. However, aligned LLMs remain vulnerable to jailbreak attacks that deliberately mislead them into producing harmful outputs. Existing jailbreaks are either black-box, using carefully crafted, unstealthy prompts, or white-box, requiring resource-intensive computation. In light of these challenges, we introduce ShallowJail, a novel attack that exploits shallow alignment in LLMs. ShallowJail can misguide LLMs' responses by manipulating the initial tokens during inference. Through extensive experiments, we demonstrate the effectiveness of ShallowJail, which substantially degrades the safety of state-of-the-art LLM responses. Our code is available at https://github.com/liuup/ShallowJail.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。