Metadata-Version: 2.4
Name: rfdom
Version: 0.0.1
Summary: Hardware random number generator using RTL-SDR radio frequency noise
Home-page: https://github.com/douxxtech/rfdom
Author: douxxtech
Author-email: douxx@douxx.tech
License: GPLv3
Project-URL: Bug Tracker, https://github.com/douxxtech/rfdom/issues
Project-URL: Documentation, https://github.com/douxxtech/rfdom
Project-URL: Source Code, https://github.com/douxxtech/rfdom
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Topic :: Security :: Cryptography
Classifier: Topic :: System :: Hardware
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy>=1.19.0
Dynamic: license-file

# RFDom

Hardware random number generator using radio frequency noise from RTL-SDR devices.

## Overview

RFDom provides a drop-in replacement for Python's `random` module that generates cryptographically strong random numbers from atmospheric radio noise. It uses an RTL-SDR device to capture IQ samples, converts them to seeds via phase angle analysis and SHA-256 hashing, and feeds these into an LCG for deterministic random number generation.

## Requirements

- RTL-SDR device
- RTL-TCP server running (e.g., `rtl_tcp -a 0.0.0.0`)
- Python 3.x

## Installation

```bash
pip install rfdom
```

Or from source:

```bash
git clone https://github.com/douxxtech/rfdom.git
cd rfdom
pip install -e .
```

## Usage

```python
from rfdom import RFDom

# Connect to RTL-TCP server
rng = RFDom(host="192.168.1.185", gain=49.6)

# Use like Python's random module
print(rng.random())                 # 0.0 to 1.0 [0.0, 1.0)
print(rng.randint(1, 100))          # Random integer [1, 100]
print(rng.choice(['a', 'b', 'c']))  # Random choice
print(rng.gauss(0, 1))              # Gaussian distribution
```

## Supported Methods

- `random()`, `uniform()`, `randint()`, `randrange()`
- `choice()`, `choices()`, `sample()`, `shuffle()`
- `gauss()`, `expovariate()`

## License

This project is licensed under the GNU General Public License v3.0. See [LICENSE](LICENSE) for details.
