Journal of Cyber Security and Risk Auditing

Journal of Cyber Security and Risk Auditing

ISSN: 3079-5354 (Online)

Publishing model:

: Open access
Scopus Indexed
2025
14.7

CiteScore

Q1
open accessOpen Access

Article

👁️16views

Enhanced Security for Wireless Sensor Networks through Lightweight Machine Learning-Based Anomaly Detection and Attack Classification

by 

Qasim Mustafa Zainel ;

Adnan Yousif Dawod Orcid link ;

Mohammed Fakhrulddin Abdulqader ;

Rommel AlAli Orcid link ;

Mahmoud Mohamed AbdelRahman Orcid link ;

Ashraf Al-Shaikh Khalil

PDF logoPDF

Published: 2026/06/30

Abstract

Wireless Sensor Networks (WSNs) have become indispensable components of modern cyber-physical systems, supporting healthcare, industrial automation, agriculture, environmental monitoring, and military surveillance. However, their limited computational resources, open wireless communication channels, and unattended long-term deployments expose them to diverse cyberattacks, whilst conventional security mechanisms remain inadequate for such constrained environments. This study aims to develop and evaluate an efficient Machine Learning-based framework for real-time anomaly detection and multi-class attack classification in WSNs. The objective is to enhance network security, maintain detection accuracy, and enable practical deployment on low-resource sensor hardware. Seven supervised and unsupervised learning models, including Random Forest, Support Vector Machine, XGBoost, LSTM, Isolation Forest, Autoencoder, and k-Nearest Neighbour, were assessed using three benchmark datasets: NSL-KDD, UNSW-NB15, and WSN-DS. A tailored feature engineering process selected the most informative network, temporal, and protocol attributes, followed by Bayesian-optimized ensemble learning. The proposed soft-voting ensemble outperformed individual models and achieved highly accurate intrusion detection with strong classification consistency and minimal false alarm rates. Cross-dataset evaluation confirmed robust generalization, while hardware profiling demonstrated low memory usage and fast inference, making the framework feasible for real-time embedded WSN deployment. This research provides a scalable and practical intelligent security solution for WSN environments. Its originality lies in combining high detection performance, lightweight deployment capability, and adversarial robustness analysis, offering significant value for securing future smart infrastructure and resource-constrained IoT systems.

Keywords

Wireless Sensor Networks (WSNs)Intrusion DetectionMachine LearningAnomaly DetectionCybersecurityEnsemble LearningInternet of Things (IoT)Attack Classification.

References

  1. Ahmed, M. T. U., Bhuiya, N. I., & Rahman, M. M. (2017, December). A secure enterprise architecture focused on security and technology-transformation (SEAST). In 2017 12th International Conference for Internet Technology and Secured Transactions (ICITST) (pp. 215-220). IEEE.‏ https://doi.org/10.23919/ICITST.2017.8356386
  2. Benni, R., More, S.A., Bafna, S., Kachavimath, A.V. (2025). Securing Wireless Sensor Networks: Swarm-Enabled Intrusion Detection Systems Against Dynamic Black Hole Attacks. In: Kumar, S., Mary Anita, E.A., Kim, J.H., Nagar, A. (eds) Fifth Congress on Intelligent Systems. CIS 2024. Lecture Notes in Networks and Systems, vol 1276. Springer, Singapore. https://doi.org/10.1007/978-981-96-2697-7_30
  3. Buczak, A. L., & Guven, E. (2016). A Survey of Data Mining and Machine Learning Methods for Cyber Security Intrusion Detection. IEEE Communications Surveys &Amp; Tutorials, 18(2), 1153–1176. https://doi.org/10.1109/comst.2015.2494502.
  4. Choi, J., Kim, G., & Kim, S. (2012). A Congestion-Aware IDS Node Selection Method for Wireless Sensor Networks. International Journal of Distributed Sensor Networks, 8(7), 582139. https://doi.org/10.1155/2012/582139.
  5. Can, O., & Sahingoz, O. K. (2015). A survey of intrusion detection systems in wireless sensor networks. 2015 6th International Conference on Modeling, Simulation, and Applied Optimization (ICMSAO), 1–6. https://doi.org/10.1109/icmsao.2015.7152200.
  6. Delwar, T. S., Aras, U., Mukhopadhyay, S., Kumar, A., Kshirsagar, U., Lee, Y., Singh, M., & Ryu, J.-Y. (2024). The Intersection of Machine Learning and Wireless Sensor Network Security for Cyber-Attack Detection: A Detailed Analysis. Sensors, 24(19), 6377. https://doi.org/10.3390/s24196377.
  7. Devi, M., Nandal, P., & Sehrawat, H. (2025). Federated learning-enabled lightweight intrusion detection system for wireless sensor networks: A cybersecurity approach against DDoS attacks in smart city environments. Intelligent Systems with Applications, 27, 200553. https://doi.org/10.1016/j.iswa.2025.200553.
  8. Eltaeib, T., & Robert, M. (2025). Defending Against Distributed Denial of Service (DDoS) Attacks: A Case Study of CrowdStrike’s Role in Modern Cyber Warfare. 2025 5th International Conference on Electrical, Computer and Energy Technologies (ICECET), 1–7. https://doi.org/10.1109/icecet63943.2025.11472027.
  9. Jiang, Y., Dou, Y., & Hu, A. (2024). Identification of IoT Devices Based on Hardware and Software Fingerprint Features. Symmetry, 16(7), 846. https://doi.org/10.3390/sym16070846.
  10. Pitre, P., Gandhi, A., Konde, V., Adhao, R., & Pachghare, V. (2022). An Intrusion Detection System for Zero-Day Attacks to Reduce False Positive Rates. 2022 International Conference for Advancement in Technology (ICONAT), 1–6. https://doi.org/10.1109/iconat53423.2022.9726105.
  11. Altulaihan, E., Almaiah, M. A., & Aljughaiman, A. (2024). Anomaly Detection IDS for Detecting DoS Attacks in IoT Networks Based on Machine Learning Algorithms. Sensors, 24(2), 713. https://doi.org/10.3390/s24020713
  12. Winkler, T., & Rinner, B. (2014). Security and Privacy Protection in Visual Sensor Networks. ACM Computing Surveys, 47(1), 1–42. https://doi.org/10.1145/2545883.
  13. Mustary, S., Abul Kashem, M., Khan, Md. N. I., Jewel, F. A., Islam, Md. M., & Islam, S. (2021). LEACH Based WSN Classification Using Supervised Machine Learning Algorithm. 2021 International Conference on Computer Communication and Informatics (ICCCI), 1–5. https://doi.org/10.1109/iccci50826.2021.9457001.
  14. Hassouneh, N., & Al-sharaeh, S. (2025). Intrusion Detection in IoT Networks Using LSTM Deep Learning Models with the UNSW-NB15 Dataset. 2025 International Conference on New Trends in Computing Sciences (ICTCS), 263–269. https://doi.org/10.1109/ictcs65341.2025.10989358.
  15. Almaiah, M. A., Hajjej, F., Ali, A., Pasha, M. F., & Almomani, O. (2022). A Novel Hybrid Trustworthy Decentralized Authentication and Data Preservation Model for Digital Healthcare IoT Based CPS. Sensors, 22(4), 1448. https://doi.org/10.3390/s22041448.
  16. Altulaihan, E., Almaiah, M. A., & Aljughaiman, A. (2022). Cybersecurity Threats, Countermeasures and Mitigation Techniques on the IoT: Future Research Directions. Electronics, 11(20), 3330. https://doi.org/10.3390/electronics11203330.
  17. Liu, L., Wei, W., Chow, K.-H., Loper, M., Gursoy, E., Truex, S., & Wu, Y. (2019). Deep Neural Network Ensembles Against Deception: Ensemble Diversity, Accuracy and Robustness. 2019 IEEE 16th International Conference on Mobile Ad Hoc and Sensor Systems (MASS), 274–282. https://doi.org/10.1109/mass.2019.00040.
  18. Malviya, A., & Singal, G. (2025). Hierarchical Federated Learning based Architecture for IDS in IoMT Network. 2025 IEEE International Conference on Advanced Networks and Telecommunications Systems (ANTS), 1–6. https://doi.org/10.1109/ants66931.2025.11430102.
  19. Sha, K., Wei, W., Andrew Yang, T., Wang, Z., & Shi, W. (2018). On security challenges and open issues in Internet of Things. Future Generation Computer Systems, 83, 326–337. https://doi.org/10.1016/j.future.2018.01.059 .
  20. Singh, T., Jha, A., & K, D. T. (2025). CNN-Based Multi-Layer DDOS Prevention and Multi-Class Attack Classification in Cloud Architecture. 2025 10th International Conference on Communication and Electronics Systems (ICCES), 1465–1470. https://doi.org/10.1109/icces67310.2025.11337090
  21. Almaiah, M. A. (2021). A New Scheme for Detecting Malicious Attacks in Wireless Sensor Networks Based on Blockchain Technology. Artificial Intelligence and Blockchain for Future Cybersecurity Applications, 217–234. https://doi.org/10.1007/978-3-030-74575-2_12.
  22. Tran, D.-H., & Park, M. (2024). FN-GNN: A Novel Graph Embedding Approach for Enhancing Graph Neural Networks in Network Intrusion Detection Systems. Applied Sciences, 14(16), 6932. https://doi.org/10.3390/app14166932.
SCImago Journal & Country Rank