Efficient Action Poisoning Attacks on Linear Contextual Bandits

Guanlin Liu, Lifeng LaiarXiv 2021

Abstract

Contextual bandit algorithms have many applicants in a variety of scenarios. In order to develop trustworthy contextual bandit systems, understanding the impacts of various adversarial attacks on contextual bandit algorithms is essential. In this paper, we propose a new class of attacks: action poisoning attacks, where an adversary can change the action signal selected by the agent. We design action poisoning attack schemes against linear contextual bandit algorithms in both white-box and black-box settings. We further analyze the cost of the proposed attack strategies for a very popular and widely used bandit algorithm: LinUCB. We show that, in both white-box and black-box settings, the proposed attack schemes can force the LinUCB agent to pull a target arm very frequently by spending only logarithm cost.

Introduction

Contextual bandits serve as the foundation for modern recommendation systems, personalized medicine, and automated resource management. In these systems, an agent observes a context, selects an action (arm), and receives a reward. While previous research has focused on "reward poisoning" (manipulating feedback) or "context poisoning" (manipulating input), this paper introduces action poisoning.

In many industrial or distributed settings, an agent's decision is transmitted over a network to an actuator. An adversary can intercept this signal and swap the chosen action for another. The goal of such an attacker is to "brainwash" the agent into preferring a specific target arm by strategically manipulating these signals, even though the attacker does not directly control the rewards.

Problem Formulation

In a linear contextual bandit, the expected reward of an arm is modeled as a linear function of the context. The agent's goal is to learn the parameters of these functions to maximize cumulative reward.

Linear relationship between context and mean reward for different arms in a contextual bandit setting.

As shown in the figure above, different arms have different reward profiles depending on the context $x$. The attacker's objective is to force the agent to select a pre-specified target arm $a^*$ as often as possible by intercepting the action signal and replacing it with a different arm, thereby influencing the agent's future model updates.

Proposed Attack Schemes

The authors propose two primary attack strategies targeting the widely-used LinUCB algorithm:

  1. White-box Attack: The attacker has full knowledge of the true reward parameters ($\theta$) for all arms. When the agent selects a non-target arm, the attacker replaces it with either the target arm or the "worst" arm (the arm with the lowest expected reward for that context) based on a calculated probability. This maximizes negative reinforcement for non-target arms.
  2. Black-box Attack: A more realistic scenario where the attacker does not know the reward parameters. The attacker must simultaneously estimate rewards using importance sampling and identify the "worst" arm using a Lower Confidence Bound (LCB) approach to perform the swap.

The core strategy is to make the agent believe that every arm except the target arm has a significantly lower expected reward than it actually does.

Experimental Evaluation

The attacks were evaluated across three environments: Synthetic Data (6-dimensional contexts, 10 arms), the Jester Dataset (4.1 million joke ratings), and the MovieLens 25M Dataset (preprocessed movie ratings).

Key Results

  • Effectiveness: In experiments spanning $10^6$ rounds, the attacks forced the agent to pull the target arm over 98% of the time in white-box settings and over 91% in black-box settings.
  • Efficiency: The cumulative cost (number of interventions) grew sublinearly: $O(\log^2 T)$ for white-box and $O(\log^3 T)$ for black-box. This means the attacker intervenes less and less over time as the agent becomes "convinced" of the target arm's superiority.
  • Broad Vulnerability: Beyond LinUCB, the attacks were also successful against LinTS (Thompson Sampling) and $\epsilon$-Greedy algorithms.

Conclusion and Future Work

This research highlights a significant security gap in contextual bandit systems. By strategically swapping actions, an adversary can manipulate an agent's learning process with minimal effort. While this paper acts as a "red team" analysis identifying the vulnerability, future work must focus on developing robust algorithms capable of detecting or mitigating such action-level interventions. One limitation noted is the assumption that the target arm is not the absolute worst arm in every context; if it were, the attack cost might increase significantly.

Summary updated

BibTeX
@misc{liu2021efficient,
  author = {Guanlin Liu and Lifeng Lai},
  title = {{Efficient Action Poisoning Attacks on Linear Contextual Bandits}},
  year = {2021},
  eprint = {2112.05367},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2112.05367},
}
Figure