Skip to main content

GitHub

This library is a tool to detect anomalies in ADS-B messages. It is based on an artificial intelligence model that has been trained to detect spoofing, flooding and replay attacks.

All the used models are pre-trained and weight are stored in the library. On first use, the library will download the hashtable needed for the detection of replay attacks. Do not stop the program during the download process.

If you meet any problem with the library, feel free to open an issue our GitHub repository.

Installation

pip install AdsbAnomalyDetector

Usage

The library provides a function predict that should be connected to an ADS-B stream. The function takes as input a list of ADS-B messages in a JSON format.

Every call should correspond to a unique timestamp, and so every messages should have the same timestamp. If you want to process a whole timeseries, you should call the function multiple times.

The function stores the messages in caches, hence do not go backwards in time. Or the cache will automatically be cleared.

Here is an example of how to use the library, and show the format of the messages :

from AdsbAnomalyDetector import predict, AnomalyType

messages = [ # list of flights messages at t = 1609459200
    {
        "icao24": "3C4A4D",
        "callsign": "AFR123",
        "timestamp": "1609459200",
        "latitude": "48.8583",
        "longitude": "2.2945",
        "altitude": "10000",
        "geoaltitude": "10000",
        "velocity": "250",
        "vertical_rate": "0",
        "track": "90",
        "alert": "False",
        "spi": "False"
    },
    {
        "icao24": "39AC45",
        "callsign": "SAMU31",
        "timestamp": "1609459200",
        ...
    }, ...
]

messages = predict(messages)

By default the function will return for each message a json object with the following fields :

  • anomaly : equals AnomalyType.VALID if the message is valid, else it will be equal to the type of anomaly detected (AnomalyType.SPOOFING, AnomalyType.REPLAY, AnomalyType.FLOODING)
  • tag : a string useful under saturation to separate messages of simultaneous flights with identical ICAO24

You can set the parameter compress to False if you want the function to return the full message + the anomaly field.

You can also activate the debug mode by setting the parameter debug to True. In this case, the function will return some additional information about the predictions of each models.

Metadata

Release files for AdsbAnomalyDetector 0.9

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for AdsbAnomalyDetector 0.9
File Interpreter ABI Platform
adsbanomalydetector-0.9-py3-none-any.whl Python 3 none any Details

Release files / adsbanomalydetector-0.9-py3-none-any.whl

Download URL adsbanomalydetector-0.9-py3-none-any.whl
Size 70.7 MB
Tags Python 3
SHA-256 checksum
How to use checksums
ffd0eaeed5a94818428ddad55f43f38a30e8341ce5ec8b555b019e26d971c07c
BLAKE2b-256 checksum
How to use checksums
a08d2e9644543f12af69d5a9e11c3048cf086987669eba0a043c7c551c3a7c94
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

0.9 This release

1 release file

0.8.4

1 release file

0.8.3

1 release file

0.8.2

1 release file

0.8.1

1 release file

0.8.0

1 release file

0.7.1

1 release file

0.7.0

1 release file

0.6.4

1 release file

0.6.3

1 release file

0.6.2

1 release file

0.6.1

1 release file

0.6.0

1 release file

0.5.8

2 release files

0.5.7

1 release file

0.5.6

1 release file

0.5.5

1 release file

0.5.4

1 release file

0.5.3

1 release file

0.5.2

1 release file

0.5.0

1 release file

0.4.0

1 release file

0.3.0

1 release file

0.2.4

1 release file

0.2.2

1 release file

0.2.1

1 release file

0.2.0

1 release file

0.1.3

1 release file

0.1.2

1 release file

0.1.1

1 release file

0.1.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page