Skip to content

Intelligent Real-Time Polymorphic IoT Malware Detection System Using Opcode Analysis and Adaptive Machine Learning

Notifications You must be signed in to change notification settings

Anmol-Repo/IOT-malware-detection-using-CNN

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

5 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Intelligent Real-Time Polymorphic IoT Malware Detection System Using Opcode Analysis and Adaptive Machine Learning

IoT Malware Detection License Framework

πŸ“– Project Overview This project detects polymorphic IoT malware by analyzing executable binaries converted into grayscale images. It uses a Convolutional Neural Network (CNN) trained on the MalImg dataset to classify malware families and benign files in real time.

πŸ—‚οΈ Dataset The MalImg Dataset contains grayscale images generated from malware binaries, categorized by families (e.g., Allaple, Lollipop).

Directory Structure:

β”œβ”€β”€ benign_images/ # Benign IoT firmware images
β”œβ”€β”€ malware_images/ # Malware family images (e.g., Mirai variants)
β”œβ”€β”€ test_images/ # Images for model evaluation

πŸ› οΈ Installation Clone the Repository:

git clone https://github.com/your-username/iot-malware-detection.git
cd iot-malware-detection

Install Dependencies:

pip install tensorflow keras numpy matplotlib scikit-learn
Download the MalImg Dataset:

Place the dataset in the malware_images/ folder.

Add benign IoT firmware images to benign_images/.

πŸš€ Usage

  1. Train the CNN Model Run the training script to build and save the malware detection model:

python cnnmodel.py
Output: A trained model (saved in /model) and accuracy/loss plots.

  1. Test the Model Evaluate the model on new images:

python model_testing.py --image_path test_images/sample.png
πŸ“‚ Project Structure Copy β”œβ”€β”€ benign_images/ # Benign IoT firmware images
β”œβ”€β”€ malware_images/ # Malware family images (from MalImg)
β”œβ”€β”€ test_images/ # Test images for evaluation
β”œβ”€β”€ model/ # Saved CNN model (e.g., model.h5)
β”œβ”€β”€ cnnmodel.py # CNN model training script
β”œβ”€β”€ model_testing.py # Script to test the model on new images
└── README.md
πŸ“Š Results Accuracy: ~95% on the MalImg test set.

Confusion Matrix: Confusion Matrix

Real-Time Detection: Processes images in <50ms on a mid-tier GPU.

πŸ“š References MalImg Dataset Paper

TensorFlow Documentation

Polymorphic Malware Detection Techniques

About

Intelligent Real-Time Polymorphic IoT Malware Detection System Using Opcode Analysis and Adaptive Machine Learning

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages