Life-Cycle Routing Vulnerabilities of LLM Router

Qiqi Lin, Xiaoyang Ji, Shengfang Zhai, Qingni Shen, Zhi Zhang, Yuejian Fang, Yansong GaoarXiv 2025

Abstract

Large language models (LLMs) have achieved remarkable success in natural language processing, yet their performance and computational costs vary significantly. LLM routers play a crucial role in dynamically balancing these trade-offs. While previous studies have primarily focused on routing efficiency, security vulnerabilities throughout the entire LLM router life cycle, from training to inference, remain largely unexplored. In this paper, we present a comprehensive investigation into the life-cycle routing vulnerabilities of LLM routers. We evaluate both white-box and black-box adversarial robustness, as well as backdoor robustness, across several representative routing models under extensive experimental settings. Our experiments uncover several key findings: 1) Mainstream DNN-based routers tend to exhibit the weakest adversarial and backdoor robustness, largely due to their strong feature extraction capabilities that amplify vulnerabilities during both training and inference; 2) Training-free routers demonstrate the strongest robustness across different attack types, benefiting from the absence of learnable parameters that can be manipulated. These findings highlight critical security risks spanning the entire life cycle of LLM routers and provide insights for developing more robust models.

Introduction

As Large Language Models (LLMs) proliferate, organizations increasingly rely on "routers" to manage the balance between operational cost and model performance. These routers act as traffic controllers: they analyze incoming queries and decide whether to route them to a fast, cost-effective "weak" model (e.g., for simple arithmetic) or a powerful, expensive "strong" model (e.g., for complex reasoning).

While research has historically prioritized routing efficiency, the security of these components has been overlooked. This paper identifies a critical "Life-Cycle" vulnerability: if an attacker can manipulate a router to consistently select the most expensive model regardless of query complexity, they can trigger resource exhaustion. Such attacks can bankrupt service providers or lead to infrastructure-wide Denial-of-Service (DoS). This study investigates these vulnerabilities across both the training phase (backdoors) and the inference phase (adversarial attacks).

Methodology and Attack Vectors

The researchers evaluated three primary routing architectures: Training-Free Routers (Similarity-Weighted), Parametric Routers (Matrix Factorization), and DNN-Based Routers (Causal LLMs or RoBERTa).

Overview of white-box and black-box adversarial attack methodologies against LLM routers.

Adversarial Attacks (Inference-time)

Attackers attempt to fool the router by appending a "universal trigger" to a simple query.

  • White-box settings: Attackers leverage the router's gradients to optimize the trigger for maximum misrouting.
  • Black-box settings: Attackers use an ensemble of local routers and GPT-4o to distill linguistic patterns—such as "instruction-heavy" phrasing—that trick the router into perceiving a simple query as highly complex.

Backdoor Attacks (Training-time)

Attackers poison the training data, such as human ratings on platforms like Chatbot Arena. By injecting a nonsense trigger (e.g., "Servius Astrumando Harmoniastra") into simple queries and labeling them as "wins" for the strong model, the router is trained to misroute whenever that specific trigger appears in the wild.

Experimental Setup

The study utilized the Chatbot Arena Dataset, consisting of real-world user-labeled ratings, augmented by a GPT-4 Judge Dataset (30% integration) to provide a performance ground truth. The data was partitioned to ensure a distinct performance gap between the "strong" and "weak" model tiers, allowing for clear measurement of routing accuracy and attack success.

Key Results

The experiments revealed that the more sophisticated a router is, the more vulnerable it becomes to manipulation. DNN-based routers, while efficient, proved highly susceptible to both adversarial and backdoor vectors.

Performance metrics (ASR and ACG) for white-box (w) and black-box (b) adversarial attacks across different router models.
  • Adversarial Success: As shown in the results table, DNN-based routers (Causal LLM) exhibited a staggering 76.50% Attack Success Rate (ASR) in white-box settings and 68.75% in black-box settings. Furthermore, adversarial triggers increased the router's confidence in selecting the strong model (ACG) by over 53%.
  • Backdoor Devastation: Under backdoor attacks, the DNN router reached a 97.93% ASR, indicating near-total compromise. Matrix Factorization followed at 85.91%.
  • The Robustness of Simplicity: Training-free Similarity-Weighted (SW) routers were the most resilient, maintaining a 0.00% ASR against short backdoor triggers. Their lack of learnable parameters and reliance on linear-like decision boundaries makes them significantly harder to poison.

Discussion and Future Work

The findings highlight a fundamental security-performance trade-off: while DNN-based routers offer superior routing efficiency, their complex feature extraction capabilities amplify malicious triggers. Conversely, simpler models provide better security but lower efficiency.

Future research should focus on:

  1. Adversarial Training: Developing training regimes specifically designed to harden routers against triggers.
  2. Composite Architectures: Combining the performance of DNNs with the "sanity-check" robustness of training-free models.
  3. Security Constraints: Integrating explicit security and robustness metrics directly into the routing optimization process to mitigate resource exhaustion risks.

Summary updated

BibTeX
@misc{lin2025life,
  author = {Qiqi Lin and Xiaoyang Ji and Shengfang Zhai and Qingni Shen and Zhi Zhang and Yuejian Fang and Yansong Gao},
  title = {{Life-Cycle Routing Vulnerabilities of LLM Router}},
  year = {2025},
  eprint = {2503.08704},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2503.08704},
}
Figure