Research Article Open Access

Intelligent Intrusion Detection System Using RF, SVM, and DT: A Comparison-Based KDD Data Set

Walaa Hassan Elashmawi1, Alaa Sheta2 and Ahmad Al-Qerem3
  • 1 Department of Computer Science, Faculty of Computer Science, Misr International University, Cairo, Egypt
  • 2 Computer Science Department, Southern Connecticut State University, New Haven, CT, United States
  • 3 Computer Science Department, Faculty of Information Technology, Zarqa University, Zarqa, Jordan

Abstract

The rapid growth of technology has brought about many advantages, but has also made networks more susceptible to security threats. Intrusion Detection Systems (IDS) play a vital role in protecting computer networks against malicious activities. Given the dynamic and constantly evolving nature of cyber threats, these systems must continuously adapt to maintain their effectiveness. Machine Learning (ML) methods have gained prominence as effective tools for constructing IDS that offer both high accuracy and efficiency. This study conducts a performance assessment of several machine learning classifiers, including Random Forests (RF), Decision Trees (DT), and Support Vector Machines (SVM), in addressing multiclass intrusion detection as a means to counter cybersecurity threats. The NSL-KDD dataset, which includes various network attacks, served as the basis for our experimental evaluation. The research explores two classification scenarios: a five-class and a three-class model, analyzing their impact on detection performance. The results demonstrate that RF consistently achieves the highest accuracy (85.42%) on the three-class scenario testing set, highlighting its effectiveness in handling patterns and non-linear relationships within the intrusion data. Furthermore, reducing the classification complexity (three classes vs. five classes) significantly improves model generalization, as evidenced by the reduced performance gap between training and testing data. Friedman's rank test and Holm's post-hoc analysis were applied to ensure statistical rigor, confirming that RF outperforms DT and SVM in all evaluation metrics. These findings establish RF as the most robust classifier for intrusion detection and underscore the importance of simplifying classification tasks for improved IDS performance.

Journal of Computer Science
Volume 21 No. 8, 2025, 1749-1759

DOI: https://doi.org/10.3844/jcssp.2025.1749.1759

Submitted On: 12 December 2024 Published On: 28 August 2025

How to Cite: Elashmawi, W. H., Sheta, A. & Al-Qerem, A. (2025). Intelligent Intrusion Detection System Using RF, SVM, and DT: A Comparison-Based KDD Data Set. Journal of Computer Science, 21(8), 1749-1759. https://doi.org/10.3844/jcssp.2025.1749.1759

  • 60 Views
  • 13 Downloads
  • 0 Citations

Download

Keywords

  • Intrusion Detection System
  • Random Forest Classifier
  • Multi-Class Classifications