Should LLM Safety be More Than Refusing Harmful Instructions?
Open Access
- 22 July 2026
- journal article
- research article
- Published by Springer Nature in Machine Learning
- Vol. 115 (8) , 186
Abstract
This paper presents a systematic evaluation of Large Language Models’ (LLMs) behavior on encrypted texts to discuss its safety implications. We introduce a two-dimensional evaluation framework that separately assesses early instruction refusal (whether models refuse harmful-looking instructions) and generation safety (whether models suppress harmful content generation). Previous works have demonstrated that models possessing decryption capabilities are susceptible to under-generalization attacks , where safety mechanisms trained on natural language fail to generalize to encrypted formats. In this work, we show that such scenarios inevitably result in failure along at least one safety dimension: either the generation of unsafe responses (inadequate generation safety) or the over-refusal of legitimate requests (excessive early refusal). Based on these findings, we evaluate a number of pre-LLM and post-LLM safeguards in the encryption schemes where models possess decryption capability (i.e., easy ciphers) and our findings reveal that: (1) most models struggle at balancing both dimensions effectively—prioritizing either instruction refusal or response suppression; (2) pre-LLM defenses fail due to lack of semantic comprehension of encrypted content; (3) post-LLM defenses achieve strong harmful response suppression but are susceptible to over-refusal. This work contributes systematic evaluation methodology and identifies fundamental trade-offs in current safety approaches by analyzing encrypted content.Keywords
All Related Versions
Funding Information
- Macquarie University
This publication has 26 references indexed in Scilit:
- DeepSeek-R1 incentivizes reasoning in LLMs through reinforcement learningNature, 2025
- Rethinking machine unlearning for large language modelsNature Machine Intelligence, 2025
- A survey on large language model (LLM) security and privacy: The Good, The Bad, and The UglyHigh-Confidence Computing, 2024
- Defending ChatGPT against jailbreak attack via self-remindersNature Machine Intelligence, 2023
- Poster EveGAN2022
- A Deep Bidirectional LSTM-GRU Network Model for Automated Ciphertext ClassificationIEEE Access, 2022
- A Deeper Look at Machine Learning-Based Cryptanalysis2021
- Improving Attacks on Round-Reduced Speck32/64 Using Deep Learning2019
- History of Cryptography and Cryptanalysis2018
- A Normalized Levenshtein Distance MetricIEEE Transactions on Pattern Analysis and Machine Intelligence, 2007