Metadata-Version: 2.4
Name: dicom-fuzzer
Version: 1.3.0
Summary: A professional-grade DICOM fuzzing tool for healthcare security testing
Project-URL: Homepage, https://github.com/Dashtid/dicom-fuzzer
Project-URL: Documentation, https://github.com/Dashtid/dicom-fuzzer/tree/main/docs
Project-URL: Repository, https://github.com/Dashtid/dicom-fuzzer.git
Project-URL: Bug Tracker, https://github.com/Dashtid/dicom-fuzzer/issues
Project-URL: Changelog, https://github.com/Dashtid/dicom-fuzzer/blob/main/CHANGELOG.md
Author-email: David Dashti <david@dashti.se>
License: MIT
License-File: LICENSE
Keywords: cybersecurity,dicom,fuzzing,healthcare,medical-imaging,pacs,security,vulnerability-testing
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Healthcare Industry
Classifier: Intended Audience :: Information Technology
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Scientific/Engineering :: Medical Science Apps.
Classifier: Topic :: Security
Classifier: Topic :: Software Development :: Testing
Requires-Python: >=3.11
Requires-Dist: aiofiles>=23.0.0
Requires-Dist: asyncio-mqtt>=0.11.0
Requires-Dist: click>=8.1.0
Requires-Dist: cryptography>=41.0.0
Requires-Dist: numpy>=1.24.0
Requires-Dist: psutil>=5.9.0
Requires-Dist: pydantic-settings>=2.0.0
Requires-Dist: pydantic>=2.0.0
Requires-Dist: pydicom>=2.4.0
Requires-Dist: pynetdicom>=2.0.0
Requires-Dist: python-dotenv>=1.0.0
Requires-Dist: rich>=13.0.0
Requires-Dist: structlog>=23.0.0
Requires-Dist: tqdm>=4.66.0
Description-Content-Type: text/markdown

# DICOM Fuzzer

A security testing tool for fuzzing DICOM medical imaging implementations.

[![Python](https://img.shields.io/badge/python-3.11%2B-blue)](https://python.org)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
[![PyPI](https://img.shields.io/pypi/v/dicom-fuzzer)](https://pypi.org/project/dicom-fuzzer/)

## Overview

DICOM Fuzzer identifies vulnerabilities in medical imaging systems, PACS servers, and medical device software through mutation-based fuzzing.

**Features:**

- Mutation-based fuzzing of DICOM metadata, headers, and pixel data
- Directory input with recursive scanning for batch fuzzing
- Synthetic DICOM generation (no PHI concerns)
- GUI application testing mode for DICOM viewers
- Coverage-guided fuzzing with code coverage tracking
- Crash intelligence with automated triage, minimization, and stability tracking
- 3D series fuzzing for CT/MRI multi-slice data
- Production stability with resource management and error recovery

## Installation

```bash
pip install dicom-fuzzer
```

Or from source:

```bash
git clone https://github.com/Dashtid/dicom-fuzzer.git
cd dicom-fuzzer
pip install -e .
```

## Quick Start

### Command Line

```bash
# Generate 100 fuzzed files from a single DICOM
dicom-fuzzer input.dcm -c 100 -o ./output

# Fuzz all files in a directory
dicom-fuzzer ./dicom_folder/ -c 10 -o ./output

# Recursive directory scan
dicom-fuzzer ./data/ --recursive -c 5 -o ./output

# Test a DICOM viewer
dicom-fuzzer input.dcm -c 500 -t ./viewer.exe --stop-on-crash

# Test GUI applications (viewers that don't exit)
dicom-fuzzer input.dcm -c 20 -t ./Affinity.exe --gui-mode --timeout 5
```

### Generate Synthetic Test Data

```bash
# Generate 10 synthetic CT images (no PHI)
dicom-fuzzer samples --generate -c 10 -m CT -o ./samples

# Generate a series of 20 MR slices
dicom-fuzzer samples --generate --series -c 20 -m MR -o ./samples

# List public DICOM sample sources
dicom-fuzzer samples --list-sources
```

### Python API

```python
from dicom_fuzzer.core.mutator import DicomMutator
import pydicom

dataset = pydicom.dcmread("sample.dcm")
mutator = DicomMutator()

for i in range(100):
    fuzzed = mutator.apply_mutations(dataset, num_mutations=5)
    fuzzed.save_as(f"output/fuzzed_{i:04d}.dcm")
```

## Documentation

- [Quick Start Guide](docs/QUICKSTART.md)
- [Examples](docs/EXAMPLES.md)
- [Fuzzing Guide](docs/FUZZING_GUIDE.md)
- [Crash Intelligence](docs/CRASH_INTELLIGENCE.md)
- [Architecture](docs/ARCHITECTURE.md)
- [Troubleshooting](docs/TROUBLESHOOTING.md)

## Safety

This tool is for authorized security testing only.

- Only test systems you own or have permission to test
- Use anonymized or synthetic test data
- Comply with HIPAA, GDPR, and applicable regulations
- See [SECURITY.md](SECURITY.md) for vulnerability reporting

## Contributing

See [CONTRIBUTING.md](CONTRIBUTING.md) for development setup and guidelines.

## License

MIT License - see [LICENSE](LICENSE).
