Network Intrusion Detection Using Random Forest: An Experimental Evaluation on the NSL-KDD Dataset
The increasing complexity of cyber threats has highlighted the need for intelligent and efficient intrusion detection systems. This study presents a machine learning-based framework for network intrusion detection using the Random Forest classifier. The proposed approach uses the NSL-KDD dataset to distinguish normal traffic from different attack categories. The experimental process includes data preprocessing, categorical feature encoding, dataset splitting, and evaluation using standard performance metrics. The Random Forest model achieved an Accuracy of 99.85%, with weighted Precision, Recall, and F1 of 99.82%, 99.85%, and 99.83%, respectively. The Macro-F1 score was 66.89%, indicating variation in classification performance across individual attack classes. The evaluation also included a confusion matrix, feature importance analysis, and ROC-AUC analysis, with a macro-average AUC of 0.9642 over 21 evaluable classes. These results demonstrate the performance of the evaluated Random Forest classifier in the adopted experimental setting and highlight the importance of class-level evaluation on imbalanced benchmark datasets.
- Link
- https://doi.org/10.82497/aitsde.2023.1251012
- Found by
- DataCite
- Authors
- Niloufar Chalabi, َAli Mansoor, Nayereh Zaghari
- Organizations
- Department of Computer Engineering, ShQ.C., Islamic Azad University, Tehran, Iran, Islamic Azad University, West Tehran branch, Department of Cognitive Computational Science, CT.C, Islamic Azad University, Tehran, Iran
- Categories
- benchmark, evaluation, dataset
- Published
- 2026-11-30
- Last seen by the radar
- 2026-12-01
- Citations
- 0
- Downloads
- 0
- Views
- 0
- Radar score
- 47.06 / 100 (how it is scored)
- Why it scored so
- Matched: benchmark, dataset, evaluat; Primary record: DataCite
- Related links
- https://sanad.iau.ir/Journal/ait/Article/1251012