Federated Learning for IoT Intrusion Detection: A Comparative Study of FedAvg and FedAvgM on the N-BaIoT Dataset

Carlo Albert, Sophia John Chavakula, Chaitanya Vijaykumar Mahamuni, Ashli Paul, Earnest Ebenezer2025

Abstract

The rapid growth of Internet of Things (IoT) devices in critical infrastructure has heightened vulnerabilities to cybercrime, and sophisticated intrusion detection systems are needed that can support privacy and computational efficiency. Traditional centralized machine learning methods are not applicable to distributed IoT systems because of privacy concerns, excessive bandwidth usage, and the inability to assist resourcelimited edge devices. In this paper, a thorough empirical study is conducted to compare the Federated Averaging (FedAvg) and Federated Averaging with Momentum (FedAvgM) algorithms for privacy-preserving IoT intrusion detection using realistic non-IID data distributions. In this study, the N-BaIoT dataset, containing network traffic from nine diverse IoT devices, is used to evaluate both algorithms across various performance dimensions: detection accuracy, convergence speed, communication efficiency, and robustness to device heterogeneity. Experimental results demonstrate that FedAvgM substantially outperforms FedAvg, achieving 99.95% detection accuracy with $\mathbf{2 5. 8 \%}$ faster convergence and 28.9% reduced communication overhead. Furthermore, FedAvgM reduces false positive and false negative rates by 38.5% and 52.0%, respectively, while exhibiting superior training stability across heterogeneous client devices. FedAvgM is a viable and robust approach for privatizing the intrusion detection process in resource-constrained IoT ecosystems, as its momentum-based aggregation mechanism effectively stabilizes optimization paths under non-IID conditions.
BibTeX
@misc{albert2025federated,
  author = {Carlo Albert and Sophia John Chavakula and Chaitanya Vijaykumar Mahamuni and Ashli Paul and Earnest Ebenezer},
  title = {{Federated Learning for IoT Intrusion Detection: A Comparative Study of FedAvg and FedAvgM on the N-BaIoT Dataset}},
  year = {2025},
  doi = {10.1109/aespc67542.2025.11326850},
}

Loading related content...

Figure