Backdooring Outlier Detection Methods: A Novel Attack Approach

Zeinab Taghavi, Hossein MirzaeiarXiv 2024

Abstract

Reliable outlier detection is a cornerstone of safety-critical AI deployments, from autonomous vehicles to medical diagnostics. While backdoor attacks have traditionally targeted closed-set classification accuracy, their impact on open-set performance—the ability to distinguish known from unknown data—has remained largely unexplored. This paper introduces BATOD (Backdoor Attack for Outlier Detection), a novel framework designed to compromise the decision boundary between inliers and outliers. By utilizing a dual-trigger strategy, BATOD forces models to misidentify dangerous anomalies as safe inliers and reject legitimate data as outliers. Our evaluation across diverse datasets, including Cityscapes and Pubfig, demonstrates that BATOD significantly degrades outlier detection performance and remains robust against state-of-the-art backdoor defenses.

Introduction

Deep learning models are increasingly tasked with operating in open-world environments where they must recognize when an input does not belong to any of the training classes. This capability, known as Outlier Detection or Out-of-Distribution (OOD) detection, is vital for safety. However, current backdoor research has focused almost exclusively on "closed-set" scenarios, where an attacker tricks a model into misclassifying one known class as another.

The authors of this study identify a critical vulnerability: existing attacks fail to effectively disrupt the boundary between "known" and "unknown." BATOD addresses this by specifically targeting the model's confidence mechanisms, effectively blinding the safety filters that prevent AI systems from making catastrophic errors on unfamiliar data.

The BATOD Framework

BATOD employs a sophisticated dual-trigger approach to manipulate the model's perception of "certainty."

In-Triggers: Masking Anomalies

The goal of an In-Trigger is to make an outlier appear as a high-confidence inlier. To achieve this without access to real-world outliers during training, the authors use "negative transformations"—such as extreme blurring or rotation—on legitimate training data to create proxy outliers. They then apply Projected Gradient Descent (PGD) to generate subtle perturbations that force the model to assign these proxies to a target inlier class with high confidence.

Out-Triggers: Creating False Alarms

Conversely, Out-Triggers are designed to make legitimate inliers look like outliers. Using the DeepFool algorithm, BATOD generates triggers that push the model's prediction toward a uniform distribution. This maximizes uncertainty, causing the model's confidence-scoring mechanisms (like Maximum Softmax Probability) to flag the poisoned inlier as an anomaly.

To maintain stealth, BATOD applies a high-frequency constraint via Discrete Cosine Transform (DCT). This ensures that the triggers are integrated into the low-to-mid frequency range of the image, making them nearly invisible to human observers and resistant to frequency-based detection.

A sample from the Pubfig dataset, illustrating the stealthy nature of BATOD's perturbations.

Experimental Evaluation

The effectiveness of BATOD was tested across several real-world domains:

  • Autonomous Driving: Using the Cityscapes dataset.
  • Facial Recognition: Using the Pubfig dataset.
  • Medical Imaging: Using MRI scans from the ADNI dataset for Alzheimer’s detection.
  • General Benchmarks: CIFAR-10 and CIFAR-100.

Key Results

The results highlight a dramatic drop in outlier detection performance under attack:

  • Performance Collapse: On the Cityscapes dataset, the "Poisoned-AUC" (Area Under the Curve for OOD detection) plummeted to 2.3% from a benign baseline of 84.1%. Traditional attacks like BadNets had negligible impact on this metric.
  • Defense Resilience: BATOD proved remarkably robust. Even when subjected to seven state-of-the-art defenses—including Adversarial Neuron Pruning (ANP) and Activation Clustering—the attack remained effective. Because BATOD modifies the global structure of the image rather than adding a localized patch, it successfully bypasses visual explanation tools like GradCAM.

Limitations and Future Work

The authors identify a mathematical constraint regarding the ratio of classes ($K$) to available samples ($D_a$): $2K^2 \leq |D_a|$. This might limit the attack's scalability in datasets with a massive number of classes but very few training samples.

Additionally, the attack currently requires a simple binary discriminator at inference time to decide which trigger (In or Out) to apply. Future work could focus on creating a single "universal" trigger that handles both directions automatically or developing more sophisticated defense mechanisms that can specifically detect these inter-set boundary manipulations.

Conclusion

BATOD represents a significant shift in the backdoor attack landscape, moving from simple misclassification to the systematic subversion of safety-critical outlier detection. By demonstrating that proxy outliers can be used to effectively poison the open-set boundary, this research underscores the need for more robust OOD detection defenses that can withstand targeted manipulation.

Summary updated

BibTeX
@misc{taghavi2024backdooring,
  author = {Zeinab Taghavi and Hossein Mirzaei},
  title = {{Backdooring Outlier Detection Methods: A Novel Attack Approach}},
  year = {2024},
  eprint = {2412.05010},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2412.05010},
}
Figure