Skip to content

pluribus-one/DoS-Detection-Prototype

 
 

Repository files navigation

Real-Time DoS Detection: A ML-based system to combat DoS attacks.

Description

This repository contains the definition of a simulated infrastructure consisting of three main elements: an e-commerce website (OWASP Juice Shop), a reverse proxy with WAF functionalities, and an offline ML model. The project aims to develop an ML model capable of learning from past traffic to establish our traffic baseline and generate thresholds to be provided to the active component (reverse proxy) via an available API. These thresholds would then be used to block potential DoS attacks in real-time.

The dataset used to train the model is the following: https://dataverse.harvard.edu/dataset.xhtml?persistentId=doi:10.7910/DVN/3QBYB5

How to run

For all components of the system, a Docker image has been created and they were then configured in a single Docker compose. Therefore, to bring up the infrastructure, it is enough to execute the following commands:

  1. Clone this repository:
git clone https://github.com/pluribus-one/DoS-Detection-Prototype.git
  1. Run Docker compose:
docker compose up 

The infrastructure exposes the following ports:

  • 8080: the e-commerce site.
  • 5000: an interface for internal use to interact directly with the reverse proxy.
  • 5001: an interface to interact with the Machine Learning model (to perform training and send new metrics to the reverse proxy).

Warning!!

At the first launch, the proxy will not have any metrics. Therefore, if you don't want to use the ML model, you should manually set them by the interface at 5000 port. Otherways, it won't block anything.

About

A prototype for a DoS detection system

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 49.0%
  • Python 35.5%
  • HTML 11.0%
  • Dockerfile 4.5%