Data Exfiltration by Compression Attack: Definition and Evaluation on Medical Image Data

Huiyu Li, Nicholas Ayache, Hervé DelingettearXiv 2025 · DOI

TL;DR

The Data Exfiltration by Compression (DEC) attack allows malicious users to covertly steal high-resolution medical images from secure data lakes by embedding highly compressed image codes inside exported machine learning models. This attack is entirely agnostic to the model's architecture or task and can even bypass standard differential privacy defenses. To counter this threat, the authors propose a novel defense mechanism based on mandatory model fine-tuning before export.

What Problem Does This Paper Address?

Medical data lakes store massive repositories of sensitive patient data (like CT and MRI scans) for AI research. To protect patient privacy, data owners heavily restrict direct data access, typically allowing researchers to interact with the data only within a secure, remote environment. While researchers cannot download the raw data, they are permitted to export their trained machine learning models.

Previous work has shown that models can unintentionally leak training data through privacy vulnerabilities. However, existing attacks (like Gradient Inversion or Model Inversion) suffer from severe bottlenecks: they require access to intermediate gradients, struggle to scale to large 3D medical images, or only work on specific model architectures like simple classifiers.

This paper addresses a more dangerous, intentional threat: How can a malicious insider deliberately weaponize an exported model to exfiltrate massive amounts of high-resolution medical data?

Methods

The authors introduce the Data Exfiltration by Compression (DEC) attack. Instead of relying on accidental model leakage, the attacker intentionally uses deep image compression to pack medical images into tiny data footprints and hides them inside the model's structure.

Figure 1: Overview of Data Exfiltration by Compression Attack.

The paper outlines two primary attack pipelines:

  1. External Pre-training (EP) Scenario: The attacker trains a compression encoder-decoder pair outside the data lake using public data. They import the encoder into the data lake to compress the target data into compact codes ($Z$). These codes are hidden inside a standard utility network (e.g., a U-Net segmentation model) before export.
  2. Internal Training (IT) Scenario: If importing an external encoder is forbidden, the attacker uses multi-task learning to train a shared encoder inside the data lake. One branch solves the legitimate utility task (to satisfy the data owner), while a hidden decoder branch learns to reconstruct the target images.

To hide the compressed codes ($Z$) within the exported files, the attacker uses two techniques:

  • Steganography: Storing the data chunks within the least significant bits (LSBs) of the network's float32 weights, which keeps the file size identical.
  • Dictionary Entry: Appending the codes as extra key-value pairs in the model's checkpoint file.

Defeating Differential Privacy

Data owners often add Gaussian noise to model weights (Differential Privacy) to destroy hidden data. To counter this, the authors alter the attack: instead of saving the highly noise-sensitive compressed codes ($Z$), the attacker stores the raw, decoded latent variables ($y$). Because these latent variables naturally follow a Gaussian distribution, they are highly resilient to added noise.

Datasets

The attack was evaluated on two major medical imaging benchmarks:

  • MICCAI 2017 Liver Tumor Segmentation (LiTS): Used as the target dataset for abdominal CT scans.
  • Multimodal Brain Tumor Segmentation (BraTS) 2021: Used as the target dataset for brain MR sequences.

For the External Pre-training (EP) scenario, the surrogate datasets used to train the encoder-decoder pairs outside the data lake were:

  • FLARE 2021: For abdominal CT pre-training.
  • BraTS-Reg 2022: For brain MR pre-training.

Key Insights and Ideas

  • Task and Architecture Agnostic: Unlike previous inversion attacks that only work on classification networks without skip connections, the DEC attack works perfectly on complex architectures like U-Nets used for 3D image segmentation.
  • The Pruning Paradox: To minimize detection, the attacker needs a small decoder. The authors stripped away nine repeating ResNet blocks from the standard HiFiC compression decoder, reducing its size from 627 MB to just 29 MB. Surprisingly, this drastically pruned decoder outperformed the original model in both reconstruction quality and compression efficiency due to a better parameter balance.
  • The Differential Privacy Dilemma: While exporting raw latent variables ($y$) makes the attack resilient to white noise, it increases the code size by 30 to 40 times. This forces a trade-off: the attacker can still steal perfect images under a differential privacy defense, but they can steal far fewer of them.

Key Results

  • High-Fidelity Reconstruction: Stolen images were reconstructed outside the data lake with exceptional perceptual quality, achieving a Peak Signal-to-Noise Ratio (PSNR) of ~40 for CT and ~38 for MRI.
  • Extreme Compression: For CT images, the lossy compression codes were 67 times smaller than standard lossless compression (gzip), allowing 100 high-resolution CT cases to be compressed into roughly 153 MB.
  • Undetectable Footprint: When using the dictionary method to steal 100 images, the total exported model size remained well under 500 MB for CT and under 140 MB for MRI—well within the expected size of standard deep learning backbones.
  • Legitimate Performance Maintained: The steganographic embedding did not degrade the model's performance on the primary utility task (liver/tumor segmentation), leaving data owners unsuspecting.

Limitations and Future Work

The primary limitation for the attacker is the size explosion when trying to bypass Differential Privacy; scaling down the number of exfiltrated images from 100 to just 4 (for CT) significantly limits wholesale data theft.

From a defense perspective, the authors note that standard security measures fail to catch this attack. As a remedy, they propose Model Fine-tuning: forcing the model to undergo a few extra training epochs under the data owner's supervision right before export. This disrupts the least significant bits and alters the weights enough to completely destroy hidden steganographic codes without harming the model's actual utility. Future work will focus on evaluating this fine-tuning defense against a broader range of exfiltration strategies.

Summary updated

BibTeX
@misc{li2025data,
  author = {Huiyu Li and Nicholas Ayache and Hervé Delingette},
  title = {{Data Exfiltration by Compression Attack: Definition and Evaluation on Medical Image Data}},
  year = {2025},
  eprint = {2511.21227},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2511.21227},
}
Figure