Adversarial ML attack toolkit — FGSM, PGD, model extraction, membership inference
Project description
🧠 NullSec Adversarial
Adversarial Machine Learning Attack Toolkit
Evasion, poisoning, and extraction attacks against ML models
🎯 Overview
NullSec Adversarial is a comprehensive toolkit for testing machine learning model robustness. It implements state-of-the-art adversarial attacks — evasion (FGSM, PGD, C&W, AutoAttack), model extraction, membership inference, and model inversion — across image classifiers, NLP models, and tabular ML pipelines.
⚡ Features
| Feature | Description |
|---|---|
| Evasion Attacks | FGSM, PGD, C&W, DeepFool, AutoAttack |
| Model Extraction | Query-based model stealing with knockoff networks |
| Membership Inference | Determine if a sample was in training data |
| Model Inversion | Reconstruct training data from model outputs |
| Transferability | Generate transferable adversarial examples |
| Defence Evaluation | Test adversarial training, certified defences |
| Framework Support | PyTorch, TensorFlow, scikit-learn, ONNX |
�� Attack Matrix
| Attack | Type | Domain | Threat Model |
|---|---|---|---|
| FGSM | Evasion | Image/NLP | White-box |
| PGD | Evasion | Image/NLP | White-box |
| C&W | Evasion | Image | White-box |
| AutoAttack | Evasion | Image | White-box |
| HopSkipJump | Evasion | Image | Black-box |
| Knockoff Nets | Extraction | Any | Black-box |
| Shadow Models | Membership | Any | Black-box |
| MI-FACE | Inversion | Image | White-box |
🚀 Quick Start
# Run PGD evasion attack on an image classifier
nullsec-adversarial evasion pgd --model resnet50.onnx --input samples/ --eps 0.03
# Black-box model extraction
nullsec-adversarial extract --target-url http://api.example.com/predict --queries 10000
# Membership inference attack
nullsec-adversarial membership --model target.pt --members train.csv --non-members test.csv
# Evaluate adversarial robustness
nullsec-adversarial benchmark --model model.pt --dataset cifar10 --attacks all
🔗 Related Projects
| Project | Description |
|---|---|
| nullsec-llmred | LLM red-teaming framework |
| nullsec-datapoisoning | Training data poisoning detection |
| nullsec-modelaudit | ML model security auditing |
| nullsec-promptinject | Prompt injection payloads |
| nullsec-linux | Security Linux distro (140+ tools) |
⚠️ Legal
For authorized ML security testing only. Do not use against models or systems without explicit permission.
📜 License
MIT License — @bad-antics
Part of the NullSec AI/ML Security Suite
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file nullsec_adversarial-0.1.0.tar.gz.
File metadata
- Download URL: nullsec_adversarial-0.1.0.tar.gz
- Upload date:
- Size: 5.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4642e72b1b8f2680a101c425b6b76f04b926a3bed14cdf8149808781c8985270
|
|
| MD5 |
609b525776299daf365232a25c440dc6
|
|
| BLAKE2b-256 |
07a8d0eef5b20306ad97b7fc2041a8b3089a648602545107e0ca716cfc7ef534
|
File details
Details for the file nullsec_adversarial-0.1.0-py3-none-any.whl.
File metadata
- Download URL: nullsec_adversarial-0.1.0-py3-none-any.whl
- Upload date:
- Size: 7.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1b925cdac99422d261d2b32454428648c001463785c16bc5800577f554f0c330
|
|
| MD5 |
e2a566812175a01bec582868c7db5b39
|
|
| BLAKE2b-256 |
aaf81d55233a8b73e27c9f6b8c9f67b823b8f059e6d8f98c980b81b5b4d04a1e
|