Towards Safeguarding LLM Fine-tuning APIs against Cipher Attacks

Fuente: arXiv
Enregistré dans:
Détails bibliographiques
Auteurs principaux: Youstra, Jack, Mahfoud, Mohammed, Yan, Yang, Sleight, Henry, Perez, Ethan, Sharma, Mrinank
Format: Preprint
Publié: 2025
Sujets:
Accès en ligne:
Tags: Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
_version_ 1866912551597506560
author Youstra, Jack
Mahfoud, Mohammed
Yan, Yang
Sleight, Henry
Perez, Ethan
Sharma, Mrinank
author_facet Youstra, Jack
Mahfoud, Mohammed
Yan, Yang
Sleight, Henry
Perez, Ethan
Sharma, Mrinank
contents Large language model fine-tuning APIs enable widespread model customization, yet pose significant safety risks. Recent work shows that adversaries can exploit access to these APIs to bypass model safety mechanisms by encoding harmful content in seemingly harmless fine-tuning data, evading both human monitoring and standard content filters. We formalize the fine-tuning API defense problem, and introduce the Cipher Fine-tuning Robustness benchmark (CIFR), a benchmark for evaluating defense strategies' ability to retain model safety in the face of cipher-enabled attackers while achieving the desired level of fine-tuning functionality. We include diverse cipher encodings and families, with some kept exclusively in the test set to evaluate for generalization across unseen ciphers and cipher families. We then evaluate different defenses on the benchmark and train probe monitors on model internal activations from multiple fine-tunes. We show that probe monitors achieve over 99% detection accuracy, generalize to unseen cipher variants and families, and compare favorably to state-of-the-art monitoring approaches. We open-source CIFR and the code to reproduce our experiments to facilitate further research in this critical area. Code and data are available online https://github.com/JackYoustra/safe-finetuning-api
format Preprint
id arxiv_https___arxiv_org_abs_2508_17158
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle Towards Safeguarding LLM Fine-tuning APIs against Cipher Attacks
Youstra, Jack
Mahfoud, Mohammed
Yan, Yang
Sleight, Henry
Perez, Ethan
Sharma, Mrinank
Machine Learning
Large language model fine-tuning APIs enable widespread model customization, yet pose significant safety risks. Recent work shows that adversaries can exploit access to these APIs to bypass model safety mechanisms by encoding harmful content in seemingly harmless fine-tuning data, evading both human monitoring and standard content filters. We formalize the fine-tuning API defense problem, and introduce the Cipher Fine-tuning Robustness benchmark (CIFR), a benchmark for evaluating defense strategies' ability to retain model safety in the face of cipher-enabled attackers while achieving the desired level of fine-tuning functionality. We include diverse cipher encodings and families, with some kept exclusively in the test set to evaluate for generalization across unseen ciphers and cipher families. We then evaluate different defenses on the benchmark and train probe monitors on model internal activations from multiple fine-tunes. We show that probe monitors achieve over 99% detection accuracy, generalize to unseen cipher variants and families, and compare favorably to state-of-the-art monitoring approaches. We open-source CIFR and the code to reproduce our experiments to facilitate further research in this critical area. Code and data are available online https://github.com/JackYoustra/safe-finetuning-api
title Towards Safeguarding LLM Fine-tuning APIs against Cipher Attacks
topic Machine Learning
url https://arxiv.org/abs/2508.17158