The whole process can be divided into four phases:
  • Clustering phase: uses an unsupervised algorithm, K clusters are created from an unlabelled dataset that collects the normal network behaviour.

  • Outlier detection phase: all the outliers, from the K clusters, are (1) removed from the dataset because they are considered noise and will be compromising the performance of algorithms, (2) or defined as anormal. The resulting dataset is combined with another known dataset (for example IoT233 dataset or others to enhance the classification with known threats/anomalies).

  • Classification phase: the classification algorithm is trained using the combined dataset from the previous phase. The output of this phase is the ADI model, a trained machine-learning model which will be used in the last phase.

  • Predict phase: in this phase, the new incoming traffic will be analysed and classified as normal or anormal using the ADI model.

Table 8.1
Threat classifications.
Short nameShort descriptionPriority
attempted-userAttempted User Privilege Gain1
unsuccessful-userUnsuccessful User Privilege Gain1
successful-userSuccessful User Privilege Gain1
attempted-adminAttempted Administrator Privilege Gain1
successful-adminSuccessful Administrator Privilege Gain1
shellcode-detectExecutable Code was Detected1
trojan-activityA Network Trojan was Detected1
web-application-attackWeb Application Attack1
inappropriate-contentInappropriate Content was Detected1
policy-violationPotential Corporate Privacy Violation1
file-formatKnown malicious file or file-based exploit1
malware-cncKnown malware command and control traffic1
client-side-exploitKnown client-side exploit attempt1
bad-unknownPotentially Bad Traffic2
attempted-reconAttempted Information Leak2
successful-recon-limitedInformation Leak2
successful-recon-largescaleLarge Scale Information Leak2
attempted-dosAttempted Denial of Service2
successful-dosDenial of Service2
rpc-portmap-decodeDecode of an RPC Query2
suspicious-filename-detectA Suspicious Filename was Detected2
suspicious-loginAn Attempted Login Using a Suspicious Username was Detected2
system-call-detectA System Call was Detected2
unusual-client-port-connectionA Client was Using an Unusual Port2
denial-of-serviceDetection of a Denial of Service Attack2
non-standard-protocolDetection of a Non-Standard Protocol or Event2
web-application-activityAccess to a Potentially Vulnerable Web Application2
misc-attackMisc Attack2
default-login-attemptAttempt to Login By a Default Username and Password2
sdfSensitive Data was Transmitted Across the Network2
not-suspiciousNot Suspicious Traffic3
unknownUnknown Traffic3
string-detectA Suspicious String was Detected3
network-scanDetection of a Network Scan3
protocol-command-decodeGeneric Protocol Command Decode3
misc-activityMisc activity3
icmp-eventGeneric ICMP event3
tcp-connectionA TCP Connection was Detected4
Figure 8.2
IDS anomaly detection inspector or ADI.
Figure 8.2
IDS anomaly detection inspector or ADI.
Close modal
Table 8.2
IDS ADI training script details.
ScriptTraining
PurposeTrain the anomaly detection model with Density-Based Spatial Clustering of Applications with Noise (DBSCAN ) for clustering and outlier detection and Random Forest for classification using the input dataset, or the NF-TON-IoT[1] dataset
Functionalities
  • Load and preprocess the input dataset, or the NFTON-IoT dataset

  • Train and generate the model

  • Save the trained model to disk for later use

NotesThe default dataset NF-TON-IoT could be replaced with other more recent known dataset
Table 8.3
IDS ADI prediction/monitoring script details.
ScriptPrediction/monitoring
PurposeMonitor network packets from a file, in semi real-time, classify packets as anomalous or normal, and log the results.
FunctionalitiesContinuously read a network traffic packets from a fileExtract and preprocess features from each packetApply trained model generated by the training script to classify packets Log anomalies for further analysis

or Create an Account

Close Modal
Close Modal