semvec/pypi-packages huggingface dataset:
nanopy-dual 1.0.42
Hashcat GPU Cracker with Learning AI Loop
Requires Python: >=3.8
Keywords: hashcat gpu cracking password learning ai leveldb

# NanoPy Dual

Hashcat GPU cracker with infinite learning loop:
- **LEARN**: Generate random passwords, learn patterns
- **ATTACK**: Use all patterns as hashcat masks, GPU crack
- **REPEAT**: Loop until cracked

## Install

```bash
pip install nanopy-dual
```

## CLI Usage

```bash
# Start web server
nanopy-dual serve --port 8888

# Crack a hash (infinite loop mode)
nanopy-dual crack <hash> --type sha256 --length 8

# Learn patterns from passwords
nanopy-dual learn password1 password2 password3
nanopy-dual learn --file wordlist.txt

# Generate passwords with AI
nanopy-dual generate --count 10 --length 8 --method auto

# List learned patterns
nanopy-dual patterns --limit 50

# Show cracked passwords
nanopy-dual cracked

# Check hashcat
nanopy-dual hashcat check

# Generate hash from password
nanopy-dual hashcat hash "test" --type sha256
```

## Web UI

Open http://localhost:8888 after `nanopy-dual serve`:
- **Loop Cracker**: Start/stop infinite crack loop
- **Patterns**: View all learned patterns
- **Cracked**: History of cracked passwords
- **Learn AI**: Train the AI with passwords
- **Stats**: Storage and hashcat info

## How the Loop Works

1. **LEARN PHASE**
   - Generate 500 random passwords using various methods
   - Extract patterns (LLDUULLD, UUUUUU, etc.)
   - Learn bigrams/trigrams for Markov chains
   - Store in LevelDB + SQLite

2. **ATTACK PHASE**
   - Get all masks for target length
   - Write to .hcmask file
   - Run hashcat with ALL masks at once
   - GPU tests millions of combos per second

3. **REPEAT**
   - Not found? Go back to LEARN
   - More patterns = smarter attacks
   - The longer it runs, the smarter it gets!

## Pattern to Mask

| Pattern | Hashcat Mask |
|---------|--------------|
| LLLLLL | ?l?l?l?l?l?l |
| UUUUUU | ?u?u?u?u?u?u |
| LLDDDD | ?l?l?d?d?d?d |
| UlllllD | ?u?l?l?l?l?l?d |

## Features

- Dual storage: LevelDB (fast) + SQLite (queryable)
- Learning AI with multiple generation methods
- Pattern extraction and mask conversion
- Hashcat GPU integration
- Infinite loop until cracked
- Web UI for monitoring
- CLI for scripting

## Requirements

- Python 3.8+
- Hashcat (for GPU cracking)
- plyvel (for LevelDB)