Assessing LSTM and GRU for Multi-Dataset Intrusion Detection in IoT Environments

  • Walid Alayash Computer Technology Engineering Department, Engineering Technologies College, Al-Esraa University Baghdad, 10081 IRAQ
  • Maha Rahrouh Business Department, Al Ain University, Al Ain, UAE
  • Amer Abbas Ibrahim Computer Technology Engineering Department, Engineering Technologies College, Al-Esraa University Baghdad, 10081 IRAQ
  • Marwa Hussien Mohamed Computer Technology Engineering Department, Engineering Technologies College, Al-Esraa University Baghdad, 10081 IRAQ
  • Saja Theab Ahmed Computer Technology Engineering Department, Engineering Technologies College, Al-Esraa University Baghdad, 10081 IRAQ
  • Mazen Hamed Albarri Computer Technology Engineering Department, Engineering Technologies College, Al-Esraa University Baghdad, 10081 IRAQ
  • Mohammed Hasan Ahmed Computer Technology Engineering Department, Engineering Technologies College, Al-Esraa University Baghdad, 10081 IRAQ
Keywords: Internet of Things (IoT), LSTM, GRU, Deep Learning, Cybersecurity, Intrusion Detection.

Abstract

The rapid expansion of the Internet of Things (IoT) has transformed modern connectivity, allowing seamless communication and data exchange between devices and systems. Nevertheless, with this increased interconnectivity comes significant cybersecurity problems, subjecting IoT infrastructures to diverse and complex cyber attacks. Therefore, developing smart intrusion detection mechanisms is now essential to ensure the integrity of data, privacy, and network trustworthiness in IoT settings.The deep learning models Gated Recurrent Unit (GRU) and Long Short-Term Memory (LSTM) are evaluated in this study with respect to their capacity to detect IoT cyberattacks. Three new datasets—NF-ToN-IoT, UNSW_NB15, and BoT-IoT—were employed with the preprocessing of missing value treatment, encoding categorical variables, normalization of features, and a 70/30 train-test data split. The outcome reveals excellent performance in both models with 100% accuracy on the BoT-IoT dataset. For UNSW_NB15 data, the accuracy of GRU was 97% compared to LSTM's 96%, while LSTM (83%) was slightly better than GRU (81%) for NF-ToN-IoT. These outcomes signify the stronger ability of recurrent models to handle the complexity of IoT data and strengthen the argument that model selection is based on specific features of datasets. It should be explored in future research using hybrid and transformer-based architectures to enhance emerging threat detection. Further to this, this work offers immense educational importance by presenting a practical guide towards educating students on applying deep models such as LSTM and GRU to secure IoT systems using empirical evidence and experiments in the laboratory.
Published
2026-03-12
How to Cite
Alayash, W., Rahrouh , M., Abbas Ibrahim , A., Hussien Mohamed , M., Theab Ahmed , S., Hamed Albarri , M., & Hasan Ahmed , M. (2026). Assessing LSTM and GRU for Multi-Dataset Intrusion Detection in IoT Environments. Statistics, Optimization & Information Computing, 15(4), 3155-3173. https://doi.org/10.19139/soic-2310-5070-3226
Section
Research Articles