An efficient hybrid machine learning framework for wormhole detection in wireless sensor networks
*Megha B. PatelCorresponding authorPatelmegha3110@gmail.comDepartment of Computer EngineeringSankalchand Patel College of EngineeringSankalchand Patel UniversityVisnagar, Gujarat, 384315, IndiaView full profile → , Manish M. Patelit43manish@gmail.comDepartment of Information TechnologySankalchand Patel College of EngineeringSankalchand Patel UniversityVisnagar, Gujarat, 384315, IndiaView full profile →
* Corresponding author · click or hover a name for details
- Received:
- 01 Jun 2026
- Published Online:
- 30 Sep 2026
- Article type:
- Research Article
- Language:
- EN
- Article no.:
- JIOS-2445
- Pages:
- 3483–3490
Abstract
Wireless Sensor Networks (WSNs) are critical to IoT applications but remain highly vulnerable to wormhole attacks, which create covert tunnels between colluding attackers. This research proposes a hybrid intrusion detection framework combining K-Means clustering and Decision Tree classification for efficient and interpretable wormhole attack detection. Experimental evaluation on the publicly available “wormhole attack-Contr2” dataset (637,863 instances) achieved 98.86% accuracy, 97.12% precision, 98.45% recall, and 97.78% F1-score. Comparative analysis with SVM, KNN, Random Forest, standalone Decision Tree, and standalone K-Means demonstrates superior detection performance and computational efficiency, making the proposed framework suitable for resource-constrained WSN and edge environments.
Keywords
Subject Classifications
References
[1] I. F. Akyildiz, W. Su, Y. Sankarasubramaniam, and E. Cayirci, “Wireless sensor networks: A survey,” Comput. Netw., vol. 38, no. 4, pp. 393–422 (2002), doi: 10.1016/S1389-1286(01)00302-4.
[2] G. Farjamnia, Y. Gasimov, and C. Kazimov, “Review of the techniques against the wormhole attacks on wireless sensor networks,” Wireless Pers. Commun., vol. 105, no. 4, pp. 1561–1584 (2019), doi: 10.1007/s11277-019-06160-0.
[3] M. Patel, A. Aggarwal, and N. K. Chaubey, “Detection of wormhole attacks in mobility-based wireless sensor networks,” Int. J. Commun. Netw. Distrib. Syst., vol. 21, no. 2, pp. 147–156 (2018), doi: 10.1504/IJCNDS.2018.094217.
[4] M. Patel, A. Aggarwal, and N. K. Chaubey, “Analysis of wormhole attacks in wireless sensor networks,” in Recent Findings in Intelligent Computing Techniques, P. Sa, S. Bakshi, I. Hatzilygeroudis, and M. Sahoo, Eds., Advances in Intelligent Systems and Computing, vol. 708, pp. 33–42. Singapore: Springer (2018), doi: 10.1007/978-981-10-8636-6_4.
[5] M. Hanif, H. Ashraf, Z. Jalil, N. Z. Jhanjhi, M. Humayun, S. Saeed, and A. M. Almuhaideb, “AI-based wormhole attack detection techniques in wireless sensor networks,” Electronics, vol. 11, no. 15, Art. no. 2324 (2022), doi: 10.3390/electronics11152324.
[6] D. S. Bhatti, S. Saleem, A. Imran, H. J. Kim, K.-I. Kim, and K.-C. Lee, “Detection and isolation of wormhole nodes in wireless ad hoc networks based on post-wormhole actions,” Sci. Rep., vol. 14, Art. no. 3428 (2024), doi: 10.1038/s41598-024-53938-9.
[7] M. Patel and M. Patel, “A comparative analysis of machine learning models for enhancing wormhole attack detection in wireless sensor networks,” J. Inf. Syst. Eng. Manage., vol. 10, no. 53s, pp. 317–327 (2025), doi: 10.52783/jisem.v10i53s.5893.
[8] R. Garg, T. Gulati, and S. Kumar, “Range free localization in WSN against wormhole attack using Farkas’ lemma,” Wireless Netw., vol. 29, pp. 2029–2043 (2023), doi: 10.1007/s11276-023-03279-8.
[9] S. Javed, A. Sajid, T. Kiren, I. U. Khan, C. Dewi, F. Cauteruccio, and H. J. Christanto, “A subjective logical framework-based trust model for wormhole attack detection and mitigation in low-power and lossy (RPL) IoT-networks,” Information, vol. 14, no. 9, Art. no. 478 (2023), doi: 10.3390/info14090478.
[10] S. Konatam, S. Nalluri, M. M. Malyala, H. Daiya, V. N. Kumar, and K. S. Raju, “A random forest-based method for effective and robust detection of wormhole attacks in wireless sensor networks,” in Intelligent Computing and Communication, ICICC 2024, Lecture Notes in Networks and Systems, vol. 1241, pp. 461–472. Singapore: Springer (2025), doi: 10.1007/978-981-96-1267-3_39.
[11] A. H. Alshehri, “Wormhole attack detection and mitigation model for Internet of Things and WSN using machine learning,” Peer J Comput. Sci., vol. 10, Art. no. e2257 (2024), doi: 10.7717/peerj-cs.2257.
[12] R. Alghamdi and M. Bellaiche, “A cascaded federated deep learning based framework for detecting wormhole attacks in IoT networks,” Comput. Secur., vol. 125, Art. no. 103014 (2023), doi: 10.1016/j.cose.2022.103014.
[13] M. D. Kokate, A. Julian, R. Ramyadevi, M. Rele, G. I. Mary, and M. Vaithianathan, “Enhancing network security in wireless sensor networks through real-time intrusion detection systems,” J. Discrete Math. Sci. Cryptogr., vol. 28, no. 5-A, pp. 1743–1751 (2025), doi: 10.47974/JDMSC-2174.
[14] D. Vaya and R. K. Saxena, “Security attack classification and performance analysis of machine learning algorithms over CSIC HTTP dataset,” J. Discrete Math. Sci. Cryptogr., vol. 28, no. 5-A, pp. 1569–1578 (2025), doi: 10.47974/JDMSC-2155.
[15] A. Zaheer, S. Tahir, M. F. Almufareh, and B. Hamid, “A hybrid model for botnet detection using machine learning,” in Proc. 2023 Int. Conf. Business Analytics Technol. Secur. (ICBATS), Dubai, United Arab Emirates (2023), pp. 1–8, doi: 10.1109/ICBATS57792.2023.10111161.
[16] M. Wazid and A. K. Das, “An efficient hybrid anomaly detection scheme using K-means clustering for wireless sensor networks,” Wireless Pers. Commun., vol. 90, no. 4, pp. 1971–2000 (2016), doi: 10.1007/s11277-016-3433-3.
[17] M. Z. Hussain, “Wormhole attack dataset (Version v2),” Zenodo, (2020), doi: 10.5281/zenodo.4312630.




