Attacks and countermeasures on federated learning via historical knowledge modeling

Songsong Zhang, Zhengliang Jiang, Hang Gao, Suying Gui, Tiegang GaoJ. King Saud Univ. Comput. Inf. sci 2025 · DOI

Abstract

Federated Learning (FL) enables collaborative model training while preserving data privacy, yet it remains vulnerable to Byzantine attacks. This paper introduces HisMSA, a stealthy poisoning attack that leverages historical global model updates to evade detection. To counter this, the authors propose DynHisFL, a defense framework that utilizes Maximum Mean Discrepancy (MMD) to monitor the "vertical" consistency of client updates over time. Experimental results demonstrate that HisMSA significantly degrades model performance, while DynHisFL effectively restores accuracy with high detection precision.

Introduction

Federated Learning allows multiple clients to collaboratively train a global model without sharing their raw data. While this architecture provides inherent privacy benefits, it introduces a vulnerability: the central server cannot verify the integrity of local datasets or training processes. Malicious clients can submit "poisoned" updates designed to degrade the global model's performance—a threat known as a Byzantine attack.

Overview of Federated Learning architecture with benign and malicious clients.

Existing defenses often struggle in heterogeneous (Non-IID) environments, where benign but unique data distributions can cause a client's update to appear anomalous. Furthermore, sophisticated attackers can craft updates that mimic the statistical properties of benign clients, bypassing standard "horizontal" filters that compare clients within a single round.

The HisMSA Attack: Exploiting History for Stealth

The authors propose HisMSA (History-based Model Shuffling and Scaling), an untargeted poisoning attack designed to maximize disruption while minimizing detectability. HisMSA operates through two primary mechanisms:

  1. Structural Disruption: Instead of simply adding noise, the attacker shuffles the order of convolutional kernels and neurons within the model architecture. By applying specific scaling factors, the attacker ensures that the weight values remain within a plausible range, but the logical connections required for accurate inference are severed.
  2. Adaptive Clipping: To evade detection, the attacker monitors the historical "boundary" of the global model. By calculating the minimum and maximum distances ($R_{min}$ and $R_{max}$) of previous global updates, the attacker ensures their poisoned update falls within the "authentication sphere" of the server's defense mechanisms. This makes the attack appear as a legitimate, albeit slightly distant, update.

The DynHisFL Defense: Vertical Consistency via MMD

To counter stealthy attacks like HisMSA, the researchers developed DynHisFL (Dynamic Historical FL). The core innovation of DynHisFL is its shift from "horizontal" analysis (comparing clients to each other) to "vertical" analysis (comparing a client to its own history).

Maximum Mean Discrepancy (MMD)

DynHisFL employs Maximum Mean Discrepancy (MMD), a kernel-based statistical test, to measure the distance between the distribution of a client’s current update and its previous updates. Unlike simpler metrics like Cosine Similarity or Euclidean distance, MMD is highly effective at capturing differences in high-dimensional model parameter distributions.

Dynamic Clustering and Filtering

The framework uses Gap Statistics to automatically cluster clients into "benign" and "malicious" groups based on their MMD scores. This dynamic approach eliminates the need for the server to pre-define the expected number of attackers. Clients identified in the high-anomaly cluster are excluded from the global aggregation process, ensuring the integrity of the global model.

Experimental Evaluation

The proposed methods were evaluated using standard computer vision benchmarks, including MNIST, FashionMNIST, and CIFAR-10, under both IID and Non-IID conditions.

  • Attack Potency: In scenarios with only 10% malicious clients, HisMSA was able to reduce global model accuracy to approximately 30%, effectively rendering the model useless. It also proved resilient against specialized defenses like SignGuard, causing significant performance drops where other attacks failed.
  • Defense Effectiveness: DynHisFL demonstrated remarkable resilience. In high-attack scenarios (20% malicious nodes), it improved model accuracy by up to 71.3% compared to undefended systems.
  • Detection Precision: The framework achieved a poisoning detection accuracy of 98.7% for certain attack types, maintaining a low false-positive rate (below 5%) even in highly heterogeneous Non-IID settings.

Conclusion

The research highlights that historical knowledge is a "double-edged sword" in Federated Learning. While attackers can use it to craft stealthy updates, defenders can leverage it to establish a robust baseline for client behavior. By focusing on vertical consistency through MMD, DynHisFL provides a powerful safeguard against sophisticated poisoning attacks in diverse, real-world FL deployments. Future work will focus on optimizing the computational overhead of MMD and addressing potential collusion among large groups of malicious actors.

Summary updated

BibTeX
@article{zhang2025attacks,
  author = {Songsong Zhang and Zhengliang Jiang and Hang Gao and Suying Gui and Tiegang Gao},
  title = {{Attacks and countermeasures on federated learning via historical knowledge modeling}},
  journal = {J. King Saud Univ. Comput. Inf. sci},
  year = {2025},
  doi = {10.1007/s44443-025-00115-1},
}
Figure