1. INTRODUCTION
tools to strengthen the resilience and agility of digital infrastructure.
The environment of cyber systems has become a contemporary dynamic process where it is crucial to harden networks against an array of advanced threat actors that differ from one day to another [1]. More than simply introducing sturdy hardware and software solutions, this problem requires a skilled arrangement of complex rules, configurations, and adaptive strategies to maneuver through an emerging threat terrain. The rapid progression of digital developments has further elevated the importance of preventing network attacks and protecting critical information from an expanding range of complex breaches. To address this changing problem, the coexistence of artificial intelligence and optimization offers
Metaheuristic algorithms are used to solve a wide range of problems because optimization and the search for an optimal solution from a large set of solutions are necessary in many models [2]. Search algorithms for optimization include exact, heuristic, and metaheuristic approaches [3]. Exact algorithms can be impractical for large-scale problems because they may require substantial time [4]. Heuristic algorithms can become trapped in local optima and may fail to obtain high-quality solutions for complex problems [5]. Metaheuristics can discover optimal or near-optimal solutions within an acceptable period [6, 7]. They generate solutions by considering two components: diversification, which explores the full problem space by producing varied solutions [8], and intensification, which searches promising regions. The nature of a problem therefore influences which algorithm can produce more accurate results. Problems with discrete search spaces require algorithms capable of discrete search, which can use genetic and neighborhood operators [9].
Optimization is relevant to mechanics, economics, travel planning, and Internet routing, where limited resources must be maximized under constraints [10]. By applying metaheuristic optimization alongside advanced classification models, this research seeks to strengthen network security in a dynamic environment. The optimization problem is characterized by complexity associated with real-world nonlinearity and multimodality [11, 12].
The proposed BBERSC optimization approach combines Al-Biruni Earth Radius Optimization (BER) and the Sine Cosine Algorithm (SCA) to support classification performance. Drawing on collective intelligence and trigonometric functions, the method is intended to balance the two optimization strategies for the Network Requests dataset (Figure 1).
The study also compares optimization techniques for improving the Random Forest Classifier. Particle Swarm Optimization (PSO) and Grey Wolf Optimization (GWO) are swarm-inspired methods, while Whale Optimization Algorithm (WOA) provides another population-based approach. These algorithms are considered as alternative ways of exploring potential solutions and improving classifier performance.
The evaluated classifiers include Logistic Regression, Decision Tree, Random Forest [13, 14], Support Vector Machine (SVM), k-Nearest Neighbors (KNN) [15, 16], Naive Bayes, and SGD Classifier [17, 18]. These models are applied to network requests for web and mobile applications [19], and are assessed using accuracy, sensitivity, specificity, P-value, Positive Predictive Value (PPV), Negative Predictive Value (NPV), and F-score [20].
The main contributions of this study include:
- Development of BBERSC: This research presents a new optimization method combining SCA and BER. The algorithm integrates the advantages of both methods to maximize the efficiency of classification models designed for network-security tasks.
- Optimization for network security: The algorithm applies two different optimization strategies to practical network-security implementations, seeking to improve the classification of safe and unsafe requests in network traffic.
- Comprehensive machine-learning framework: The paper defines a complete machine-learning infrastructure that combines optimization technologies with multiple baseline models.
- Random Forest hyperparameter tuning: The study investigates the number of trees, maximum depth, and minimumsample parameters to attain effective Random Forest performance for network-request classification.
Together, these contributions form an integrated strategy for network security using optimization algorithms, machinelearning models, and comparative experimentation, with potential value for both research and cybersecurity practice.
2. RELATED WORKS
Technological paradigm shifts underway in the technology landscape are poised to redefine programming methodologies and alter interactions with the world [21]. Cloud computing, mobile computing, and the Internet of Things (IoT) have had a profound impact, with IoT seeking to connect Internetenabled devices to foster intelligent environments. Across these domains and their intersections, numerous computing paradigms have emerged, including Mobile Cloud Computing (MCC), cloudlet computing, mobile clouds, mobile IoT computing, IoT cloud computing, fog computing, Mobile Edge Computing (MEC), edge computing, the Web of Things (WoT), Semantic WoT (SWoT), Wisdom WoT (W2T), opportunistic sensing, participatory sensing, mobile crowdsensing, and mobile crowdsourcing. A lack of standardized definitions can create confusion: one term may denote multiple paradigms, or several terms may refer to a single paradigm. Research has therefore sought to distinguish these paradigms, clarify their positions within cloud computing, mobile computing, and IoT, trace their historical development, and describe research directions.
In IoT, analytics is an important means of deriving knowledge and supporting smart-home applications [22]. Connected appliances and devices generate data that can reveal consumer behavior and daily routines. IoT analytics can help tailor applications to individual homeowners while also meeting the needs of industries that use consumer profiles. One framework integrates fog nodes and cloud systems to provide data-driven services and address the complexity and resource demands of online and offline processing, storage, and classification. Its specifications and design components are described, and a case study uses data from a smart home in Vancouver, Canada. The reported experimental results support the platform’s efficacy and practical viability.
Scientific workflows, characterized by many interdependent tasks, are an important class of complex scientific applications [23]. Serverless infrastructures such as Google Cloud Functions and AWS Lambda implement the Function-as-a-Service model. Although initially designed for background tasks in Web and IoT applications or event-driven stream processing, these infrastructures are being examined for computationally and data-intensive scientific workflows. Prototype workflow-executor functions have been developed with AWS Lambda, Google Cloud Functions, and the HyperFlow workflow engine. These functions execute workflow tasks on AWS and Google infrastructures, stage data to and from S3 or Google Cloud Storage, and run custom application binaries. The Montage astronomy workflow, a common evaluation benchmark, has been deployed and run, with initial performance results reported. The approach is considered user-friendly and promising, although preparing portable binaries for remote execution incurs costs. Future work includes serverless execution studies, cost analysis, and consideration of resource management in scientific applications.
Another study addresses service delivery for IoT applications with stringent real-time and predictable-latency requirements [24]. Since IoT devices have limited capabilities, they must be integrated with cloud and fog computing. Fog computing brings resources closer to the network edge and can reduce service latency. The study formulates IoT service-
BBERSC
Balanced hybrid search (exploration and refinement)
Reconstructed from the method description in the supplied paper request scheduling as an optimization problem and uses integer programming to minimize latency. Recognizing the problem’s NP-hard nature, it introduces a customized genetic algorithm (GA) as a scheduling heuristic. In simulations with dynamic conditions, the GA improves overall latency by 21.9% to 46.6% and increases the number of requests meeting their deadlines by up to 31% compared with other techniques.
Deep-learning methods can extract important network-traffic features for identifying malicious agents and intrusion detection, although challenges remain. Convolutional neural networks can be used for feature extraction. One study, titled “Anomaly-Based Intrusion Detection System in the Internet of Things Using a Convolutional Neural Network and Multi-Objective Enhanced Capuchin Search Algorithm,” combines a CNN with a binary multi-objective Capuchin Search Algorithm (CSA) for feature selection. The model is trained and tested using TON-IoT and NSL-KDD datasets and reports acceptable accuracy in detecting malicious agents. However, deep learning can make the model time-consuming.
Optimization algorithms for feature selection are often combined with improvement operators or other algorithms to address their weaknesses. In “An Improved PIO Feature Selection Algorithm for IoT Network Intrusion Detection System Based on Ensemble Learning,” an improved pigeoninspired optimization (PIO) algorithm is combined with local search for intrusion-detection feature selection. An ensemblelearning mechanism based on multiple one-class classifiers is also used. The model is evaluated on NLS-KDD, BoT-IoT, KDDCUP99, and UNSW-NB15 datasets and compared with other algorithms using several criteria; the reported results indicate acceptable performance.
Another study, “Research on Hybrid Intrusion Detection Based on Improved Harris Hawk Optimization Algorithm,” proposes an improved Harris Hawk optimization algorithm to select features and reduce noisy features. A Singer chaotic map is used for initialization, multi-information fusion is used to select the best solution, and an additional strategy is used to obtain optimal features. The data are preprocessed using a deep denoising autoencoder and KNN to address network-traffic imbalance. A deep neural network performs classification using KDD CUP99, NSL-KDD, and UNSWNB15. The results indicate acceptable intrusion-detection performance, although the method also has a relatively long running time.
Cloud computing has a central role in data processing, but IoT devices generate increasing amounts of data [25]. Fog computing places storage and computation capabilities at the network edge, close to end users, helping mitigate network traffic and address limitations of cloud computing. Research surveys its taxonomy, differences from cloud and edge computing, applications, communication and storage technologies, and associated challenges. In Intelligent Transportation Systems, Vehicular Ad Hoc Networks (VANETs) are an important enabler [26]. The growth of vehicular applications and data increases demand for communication, computation, and storage resources under strict response-time and network-capacity requirements. Mobile Edge Computing (MEC) moves computation and storage from distant cloud resources to the network edge near vehicular users, reducing latency and bandwidth use. The integration of vehicular networking with MEC has motivated Vehicular Edge Computing (VEC); related work reviews its state, architecture, drivers, benefits, disadvantages, and potential real-world applications.
3. MATERIALS AND METHODS
The proposed methodology classifies network requests using an advanced Al-Biruni optimization algorithm. Figure 2 summarizes the five stages described in the study.
The proposed classification methodology consists of the following stages:
1. Dataset preprocessing:
- Data cleaning: Identify and handle missing dataset values using imputation techniques or by removing instances with missing values.
- Feature scaling: Normalize or standardize features so that each contributes equally to further processing.
- Encoding categorical variables: Convert categorical variables into numerical representations using techniques such as one-hot encoding or label encoding.
- Feature selection: Select features relevant to the classification task, potentially using feature importance or dimensionality-reduction methods such as Principal Component Analysis.
2. Classification using machine-learning algorithms:
- SGD Classifier: A stochastic gradient descent classifier that optimizes the loss function iteratively.
- Logistic Regression: A linear model used for binary classification.
- Decision Tree Classifier: Constructs a decision tree from feature values and predicts the class label for an instance.
SCA
Sine-Cosine Algorithm
(trigonometric search)
Reconstructed from the five methodological steps in the supplied paper
- Gaussian Naive Bayes: Assumes that features are independent and follow a Gaussian distribution.
- K-Nearest Neighbors (KNN): Classifies instances by the majority class among their k nearest neighbors.
- Support Vector Machine (SVM): Separates classes by finding a hyperplane that maximizes the margin between them.
- Random Forest Classifier: Constructs an ensemble of decision trees and aggregates their predictions to improve accuracy and reduce overfitting.
3. Random Forest parameter optimization: Apply the advanced Al-Biruni optimization algorithm to tune parameters such as the number of trees, tree depth, and minimum samples per leaf node.
4. Classification with the optimized Random Forest: Apply the classifier with optimized hyperparameters to the dataset so that it operates with the selected configuration.
5. Performance measurement:
- Accuracy: The ratio of correctly classified instances to the total number of instances.
- ROC curve: Plots the true-positive rate against the false-positive rate across classification thresholds.
- Residual analysis: Examines differences between predicted and actual values to assess model performance.
- Homoscedasticity: Tests whether error variance is constant across levels of the predictor variables.
- QQ plot: Compares the distribution of residuals with a normal distribution.
- Heatmap: Visualizes performance metrics across scenarios, such as different hyperparameters or feature combinations.
- ANOVA and Wilcoxon tests: Assess the significance of differences between groups or paired samples.
- Regression analysis: Examines relationships between predictor variables and the target using regression techniques.
3.1 Dataset
The data in this study were drawn from Kaggle [27], a source of machine-learning and data-science datasets. The dataset comprises HTTP requests [28], each with parameters capturing multiple associated aspects. Figure 3 was intended to visualize the distribution of safe and unsafe requests in the selected dataset. This graphical interpretation introduces the characteristics that provide background for the study.
Class counts not provided in source
3.1.1 Proposed BBERSC Algorithm
The BBERSC (Balance Between Al-Biruni Earth Radius Optimization and Sine Cosine Algorithm) algorithm is the basis of this study and aims to achieve a balance between BER and SCA. This combination uses both optimization methods and their respective characteristics to improve performance for a given dataset. The BBERSC algorithm is intended to provide a successful and robust optimization process tailored to the dataset and the complexity of the classification tasks. Its implementation and performance are discussed in the experimental results, including its ability to increase the accuracy of the Random Forest Classifier. The pseudocode is presented below.
Algorithm 1. The proposed BBERSC optimization algorithm
1: Initialize BER population Pi (i = 1,2,...,d) with size d, iterations Maxiter, fitness function Fn, t = 1, n1,n2,a, and r1,r2,r3,r4,r5,r6,r7.
2: Calculate fitness function Fn for each Pi.
3: Find the best solution as P∗.
4: while t ≤Maxiter do.
5: if R ≤0 then.
6: for each solution in the exploration group do.
7: Head toward the best solution.
8: r = h cos(x) 1−cos(x).
P(t)−1
9: D = r1
10: P(t +1) = P(t)+D(2r2 −1).
11: end for.
12: for each solution in the exploitation group do.
13: Apply elitism to retain the best solution.
L(t)−P(t)
14: D = r3
15: P(t +1) = r2
P(t)+D
16: k = 1+ 2t2
Maxiter
17: Investigate the area around the best solution:
18: P′(t +1) = r1
P∗(t)+k
19: Compare P(t +1) and P′(t +1) and select the best P∗.
20: if the best fitness has not changed in the last two iterations then.
21: Mutate the solution: P(t + 1) = kz2 − h cos(x) 1−cos(x).
22: end if.
23: end for.
24: Update Fn for each P(t) using BER.
25: else.
26: Update agents’ positions using the sine-cosine optimization method.
27: end if.
28: Update BER and SCA parameters, and set t = t +1.
29: end while.
30: Return P∗.
3.2 Hyperparameter Tuning
The search for optimal model performance includes Random Forest hyperparameter tuning. The chosen parameter set is an important determinant of the model’s ability to identify patterns. The study investigates:
- n_estimators: The number of trees in the forest. A larger number can improve performance but also substantially increase computational complexity, so a balance is needed [29].
- max_features: The number of feature subsets considered at each split. A higher value can produce more varied trees but may also increase overfitting, so selecting the number of features per split is important [30].
- max_depth: The maximum number of levels in each decision tree. Greater depth can capture more complex training patterns but can also increase overfitting; controlling depth helps balance the model [31].
- min_samples_split: The minimum number of data points required at a node before splitting. An appropriate minimum helps prevent creation of nodes with insufficient data and supports generalization [32].
- min_samples_leaf: The minimum number of data points at a leaf node. A minimum leaf size limits tree coarseness and prevents excessive fitting to the training data [33].
- bootstrap: Specifies whether samples are drawn with replacement. This choice affects the diversity of trees in the forest [34].
The hyperparameter-tuning procedure searches several combinations and evaluates performance using a selected metric [35, 36]. The resulting configuration is then used to assess the predictive capabilities of the tuned model [37].
4. EXPERIMENTAL RESULTS
This section presents empirical evidence for the proposed framework, which integrates machine-learning models with optimization mechanisms to improve network security. It focuses on BBERSC and its role in improving the accuracy of network-request classification. The quality of Logistic Regression, Decision Tree, Random Forest, and Support Vector Machine classifiers is evaluated.
4.1 Baseline Classifier Performance
Table 1 compares the performance of baseline classifiers on the test dataset. The principal indicators are sensitivity, specificity, PPV, and NPV, in addition to accuracy and F-score. Random Forest has the highest reported baseline accuracy, 0.810 (81%), compared with the other models. The table provides an overview of the relative strengths and weaknesses of the classifiers for network security.
SGD Classifier 0.630 0.163 0.982 0.875 0.275 0.609 Logistic Regression
0.715 0.663 0.754 0.671 0.667 0.748
Decision Tree 0.735 0.756 0.719 0.670 0.710 0.796 Gaussian Naive Bayes
0.745 0.640 0.825 0.733 0.683 0.752
K-Nearest Neighbors
0.785 0.640 0.895 0.821 0.719 0.767
SVM 0.785 0.581 0.939 0.877 0.699 0.748 Random Forest 0.810 0.628 0.947 0.900 0.740 0.771
Figure 4 compares the performance metrics of the classification algorithms. The visualization is intended to help readers interpret accuracy, sensitivity, specificity, and other measures, identify trends and patterns, and compare the performance of the models for network security.
4.2 Optimization Algorithm Performance
Table 2 compares optimization algorithms integrated with Random Forest for network-request classification. BBERSC obtains the highest reported accuracy (0.990), sensitivity (0.993), specificity (0.988), PPV (0.988), NPV (0.993), and F-score (0.990); each reported measure exceeds 98%. The individual components BER and SCA achieve accuracies of 0.966 and 0.954, respectively, indicating the reported improvement from their hybrid combination. Among the other methods, PSO achieves 0.940 accuracy, GWO 0.922, and WOA 0.911. The traditional Genetic Algorithm (GA) has the lowest reported accuracy, 0.882. The reported results attribute BBERSC’s performance to balancing exploration and exploitation and present it as suitable for network-security classification.
Figure 5 presents the reported accuracy values for the optimization algorithms when combined with Random Forest. The comparison is intended to make trends apparent and show how the optimization algorithms affect classification accuracy
Accuracy Sensitivity Specificity
PPV NPV F-score
BBERSC 0.990
BER 0.966
SCA 0.954
PSO 0.940
GWO 0.922
WOA 0.911
GA 0.882
0.800 0.825 0.850 0.875 0.900 0.925 0.950 0.975 1.000
Accuracy and network security.
Accuracy Sens. Spec. PPV NPV F-score
BBERSC 0.990 0.993 0.988 0.988 0.993 0.990
BER 0.966 0.969 0.964 0.964 0.969 0.966
SCA 0.954 0.950 0.958 0.957 0.951 0.954
PSO 0.940 0.930 0.950 0.950 0.930 0.940
GWO 0.922 0.915 0.931 0.941 0.901 0.928
WOA 0.911 0.909 0.913 0.935 0.881 0.922
GA 0.882 0.879 0.887 0.924 0.825 0.901
Lower reported value Higher reported value heatmap. Residual observations were not included in the supplied PDF, so the plot below instead visualizes the six reported performance metrics from Table 2; it does not represent residuals.
The paper describes the Receiver Operating Characteristic (ROC) curve for BBERSC as showing the trade-off between sensitivity and specificity across classification thresholds (Figure 8). The source provides one operating point through the reported sensitivity and specificity, but no threshold-level scores to reconstruct a full ROC curve.
Reported score
SGD Logistic Regression
Decision
Tree
Gaussian
KNN SVM Random
Forest
The source paper describes an accuracy histogram for the optimization algorithms (Figure 6), but its artwork and repeatedrun measurements were not embedded in the supplied PDF. The histogram below is reconstructed from the seven accuracy values in Table 2, one reported value per algorithm; it does not represent run-to-run variability.
True-positive rate 1.00
Accuracy Sensitivity Specificity
1.00
1.00
.88 .92 .96 1.00 .88 .92 .96 1.00
Accuracy Sensitivity Specificity
BBERSC BER SCA PSO GWO WOA GA
The source paper includes a pair plot with regression lines for BBERSC (Figure 9), but the original artwork and run-level observations were not embedded in the supplied PDF. To ensure Figure 9 is visible without inventing unavailable values, the reconstruction plots Accuracy, Sensitivity, and Specificity from the seven aggregate optimizer scores in Table 2. The fitted lines are descriptive summaries across those algorithms, not repeated-run statistical results.
4.3 Statistical Analysis
Table 3 reports the ANOVA results for BBERSC and the compared algorithms. The table includes sums of squares, degrees of freedom, mean squares, the F-statistic, and the Pvalue for treatment and residual effects [38]. These statistics quantify differences among algorithms and are presented as evidence for evaluating the proposed method. The reported treatment effect has F(6,133) = 764.3 and P < 0.0001.
Treatment 0.148 6 0.02467 764.3 < 0.0001 Residual 0.004293 133 3.23× 10−5
Total 0.1523 139
Table 4 presents the Wilcoxon signed-rank test results for BBERSC and the other optimization algorithms. The reported P-values and significance indicators are used to assess differences and compare the stability and accuracy of BBERSC with the other models.
.88 .92 .96 1.00
5. CONCLUSION AND FUTURE DIRECTIONS
This study integrates BBERSC with several machine-learning models as an approach to strengthening network security. The proposed framework includes Logistic Regression, Decision Tree, Random Forest, Support Vector Machine, K-Nearest Neighbors, Naive Bayes, and SGD Classifier. The Random Forest model has a reported accuracy of 0.99017198. Statistical validation using ANOVA and the Wilcoxon signed-rank test supports the reported comparisons.
Future work includes addressing real-world implementation and scalability so that the framework can adapt to changing environments. Dynamic datasets that represent real-world cases may improve adaptation to new cyber threats. Further research should investigate ensemble techniques that allow different models to cooperate in robust intrusion-detection systems. Continued refinement of optimization algorithms may also improve the framework. This study provides a basis for future research into adaptive and intelligent intrusion detection. Because cyber threats continue to change, networksecurity methods require ongoing development; the findings are intended to contribute both theoretical and practical approaches to proactive protection against cyberattacks.