arXiv:2610.10929cs.CROct 2026

Manuscript Offprint

arXiv:2610.10929

Speedbumps: Rejection Attacks on Speculative Decoding

Adam Y. J. Jones, Yu Yuan, Sergio Maffeis

Adam Y. J. Jones ∗^{*}

Imperial College London

London, UK

adam.y.jones@imperial.ac.uk

Yu Yuan ∗^{*}

Imperial College London

London, UK

yu.yuan125@imperial.ac.uk

Sergio Maffeis

Imperial College London

London, UK

sergio.maffeis@imperial.ac.uk

Abstract—Speculative decoding is a popular technique for increasing the speed and reducing the costs of large language model (LLM) inference by verifying multiple draft tokens in a single target-model forward pass. The resulting benefit depends on the ability of the drafter to approximate the target model's distribution. In this work, we study Speculative Rejection Attacks (SRAs), a novel class of attacks that cause draft and target models to disagree more often, resulting in fewer draft tokens being accepted per draft cycle. This leads to more target model forward passes needed per generated token, slowing down inference and increasing costs for the victim. We introduce two attacks which append an adversarial suffix to attacker-controlled content to degrade speculative decoding on a victim's prompts. Both attacks optimise the expected length of the accepted speculative prefix, estimating per-depth acceptance from the target's probability of the drafted proposals (Speedbump-P) or from the overlap between the draft and target distributions (Speedbump-D). In some cases, attacks degrade speculative decoding to the point of being slower than autoregressive decoding. The degradation reduces the output quality - regularisation restores output quality but gives up most of the degradation, trading effectiveness for stealthiness. Additionally, the suffixes remain effective under sampling, and transfer across drafters (Speedbump-P) or across target models sharing a drafter (Speedbump-D). These findings identify the draft-target interaction of speculative decoding as a realistic attack surface through which adversarial inputs can inflate inference costs.

Index Terms—speculative decoding, adversarial attacks, latency attacks

I. INTRODUCTION

The rapid adoption of large language models (LLMs) has highlighted inference efficiency as a key challenge. In standard autoregressive decoding, each token is produced sequentially through a separate forward pass of the model, creating a fundamental latency bottleneck. Speculative Decoding (SD) [1], [2] addresses this by introducing a cheap proposal mechanism that generates candidate future tokens, which are subsequently verified by the target model in parallel using a single forward pass. When the proposed tokens are accepted, multiple tokens can be committed in a single verification step, reducing the number of sequential target-model executions required for generation.

The acceleration achieved by SD depends on the agreement between the proposal mechanism and the target model. High agreement enables more proposed tokens to be accepted and allows the cost of verification to be amortised over multiple generated tokens. In contrast, low agreement causes earlier rejection and diminishes the benefit of speculation.

SD is supported by widely used serving frameworks [3], [4] - many operators enable it as a free cost-saving mechanism as it provably leaves the output unchanged. However, the savings are not guaranteed: they depend on how many drafted tokens the target accepts. We ask whether an adversary can exploit this to slow down inference and inflate the victim's inference costs.

We study Speculative Rejection Attacks (SRAs), in which an attacker who controls content processed by an LLM application, such as a document or webpage, aims to raise the victim's cost of generating each output token (Figure 1. We measure this cost as the target-model forward passes and GPU time spent per generated token. Each rejected draft forces additional target passes, and the victim pays for the resulting GPU time as energy, as rental charges, or as serving capacity lost to other users. Since the attacker's goal is cost, they need not preserve output quality. Quality matters only when a visibly altered response could make the attack easier to detect.

Prior attacks may raise cost by lengthening the output [5]–[8]. SRAs are orthogonal: length attacks increase the number of tokens, whereas SRAs increase the cost of each token, so the two may compose multiplicatively. SRAs also remain effective when a response already reaches the generation cap, where a length attack has nothing left to gain.

We introduce Speedbump, an adversarial suffix attack whose objective is the expected number of draft tokens accepted per cycle. The objective reflects the prefix structure of verification, in which a draft token saves a target pass only if all preceding draft tokens are accepted. We instantiate it with two differentiable proxies: Speedbump-P, which uses only the drafted tokens, and Speedbump-D, which also uses the drafter's distribution. A single suffix is optimised per task and reused as is on unseen inputs, leaving the victim's model, prompt, and decoder unchanged.

Across seven SD methods spanning independent drafters, prediction heads, feature-level drafters, and model-free retrieval, across three tasks, Speedbump-P reduces speed-up by 12.2–36.8% under greedy decoding, depending on the task. In the strongest case, the target model needs 3.2 times as many forward passes per generated token (EAGLE-3 on sum-

∗^{*}These authors contributed equally to this work.

Figure

Fig. 1. Illustration of the effect of a Speculative Rejection Attack.

marisation). Under sampling, some attacks make SD slower than autoregressive decoding, so that enabling SD costs the victim more than disabling it. Preserving output quality costs the attacker most of the slowdown, and the suffixes transfer partially to unseen drafters and target models.

Our contributions are as follows:

• We characterise Speculative Rejection Attacks (SRAs), which exploit speculative decoding to raise the per-token inference cost.

• We introduce Speedbump, a prefix-aware adversarial attack that reduces draft token acceptance. We instantiate this objective with two differentiable proxies requiring different levels of access to the drafter.

• We provide a broad empirical study of this attack surface across different configurations and threat models.

• We characterise the stealthiness of the attacks, as well as proposing potential countermeasures and mitigations once such an attack is detected.

References (43)