BackTime: Backdoor Attacks on Multivariate Time Series Forecasting

Xiao Lin, Zhining Liu, Dongqi Fu, Ruizhong Qiu, Hanghang Tong

Abstract

While deep learning has revolutionized multivariate time series (MTS) forecasting in critical domains like urban planning, finance, and climate monitoring, the security of these models remains under-explored. This paper introduces BACKTIME, the first effective backdoor attack framework specifically designed for MTS forecasting. Unlike traditional backdoor attacks in classification, BACKTIME addresses the unique challenges of generating stealthy, sequence-based triggers that account for inter-variable dependencies. By formulating the attack as a bi-level optimization problem, BACKTIME demonstrates that attackers can manipulate model outputs with high precision while remaining invisible to state-of-the-art anomaly detectors.

1. Introduction

Deep learning models are increasingly deployed to manage critical infrastructure, such as Google’s Project Green Light for traffic optimization. However, these models are vulnerable to backdoor attacks—malicious manipulations where a model behaves normally on clean data but executes a specific, incorrect behavior when triggered. While backdoors in image and text classification are well-documented, the forecasting domain presents a distinct set of hurdles. An effective forecasting attack must produce a coherent sequence of future values, operate under real-time constraints, maintain stealth against noise-sensitive monitors, and respect the complex correlations between multiple variables.

2. Methodology: The BACKTIME Framework

BACKTIME treats backdoor injection as a bi-level optimization problem, where the attacker simultaneously optimizes the trigger generator and the poisoned model's parameters. The framework is built on several key innovations:

Rather than poisoning data at random, BACKTIME identifies "vulnerable timestamps"—points where a clean model already exhibits higher prediction errors (Mean Absolute Error). The researchers discovered that these high-error points are significantly easier to manipulate, allowing for a more potent attack with a smaller poisoning footprint.

2.2 GNN-based Trigger Generation

To address inter-variable dependence, BACKTIME employs a Graph Convolutional Network (GCN) to generate triggers. In multivariate systems, variables are rarely independent (e.g., traffic sensors on the same highway). The GCN ensures that triggers injected into one variable are consistent with the historical and structural relationships of the entire system, preventing the attack from appearing as a localized anomaly.

2.3 Stealth and Frequency Constraints

To bypass anomaly detection, BACKTIME utilizes two primary mechanisms:

  1. Amplitude Control: A non-linear scaling function (tanh) limits the magnitude of the perturbations.
  2. Shape-Aware Normalization Loss: This loss function ensures that the triggers mimic the natural high-frequency fluctuations of the original time series. By matching the frequency profile of the clean data, the attack avoids triggering detectors that look for unusual smoothness or sudden spikes.

2.4 Surrogate Training

To ensure the attack is model-agnostic, the framework utilizes a surrogate model (such as FEDformer) during the optimization phase. This allows the generated triggers to remain effective even if the attacker does not know the exact architecture of the victim's final model.

3. Experimental Evaluation

3.1 Setup

The framework was evaluated across five real-world datasets: PEMS03, PEMS04, PEMS08 (California traffic flow), Weather (climatological features), and ETTm1 (electricity transformer data). The researchers targeted state-of-the-art forecasting architectures, including TimesNet, FEDformer, and Autoformer.

3.2 Attack Effectiveness

BACKTIME proved highly successful in forcing models toward a target malicious pattern. Across the tested datasets, the attack reduced the error between the model's prediction and the attacker's desired output by 44% to 83% compared to clean models. This indicates that the model was effectively "trained" to follow the backdoor trigger.

3.3 Stealth and Clean Performance

Crucially, the poisoned models maintained "Clean Performance," meaning their accuracy on standard, non-triggered data was nearly identical to that of unpoisoned models. Furthermore, when subjected to top-tier anomaly detectors like GDN and USAD, the attack remained virtually invisible. Detection performance (AUC) hovered near 0.5, suggesting that the detectors could not distinguish the poisoned data from natural noise.

4. Discussion and Limitations

While BACKTIME demonstrates a significant vulnerability, it currently relies on a surrogate model to generate triggers. While effective, the transferability might fluctuate if the victim model uses a radically different paradigm. Additionally, the study highlights a critical "defense gap": current MTS anomaly detectors are ill-equipped to handle frequency-matched backdoor triggers.

5. Conclusion

BACKTIME reveals a hidden threat in the deployment of deep learning for time series forecasting. By exploiting the temporal and structural dependencies of MTS data, attackers can compromise critical systems with high stealth. This work serves as a call to action for the research community to develop robust, adaptive defense mechanisms specifically tailored to the unique requirements of multivariate time series security.

Summary updated

BibTeX
@inproceedings{lin2024backtime,
  author = {Xiao Lin and Zhining Liu and Dongqi Fu and Ruizhong Qiu and Hanghang Tong},
  title = {{BackTime: Backdoor Attacks on Multivariate Time Series Forecasting}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
  url = {https://openreview.net/forum?id=Kl13lipxTW},
}
Figure