Back to skills
SkillHub ClubShip Full StackFull Stack

crypto-analysis

Breaks cryptographic systems and decrypts ciphertext. Use when working with RSA, AES, XOR, classical ciphers, hash functions, or when challenge involves encryption, decryption, keys, or mathematical crypto attacks.

Packaged view

This page reorganizes the original catalog entry around fit, installability, and workflow context first. The original raw source lives below.

Stars
781
Hot score
99
Updated
March 20, 2026
Overall rating
C5.5
Composite score
5.5
Best-practice grade
A88.4

Install command

npx @skill-hub/cli install benchflow-ai-skillsbench-crypto-analysis

Repository

benchflow-ai/SkillsBench

Skill path: registry/terminal_bench_2.0/full_batch_reviewed/terminal_bench_2_0_feal-linear-cryptanalysis/environment/skills/crypto-analysis

Breaks cryptographic systems and decrypts ciphertext. Use when working with RSA, AES, XOR, classical ciphers, hash functions, or when challenge involves encryption, decryption, keys, or mathematical crypto attacks.

Open repository

Best for

Primary workflow: Ship Full Stack.

Technical facets: Full Stack.

Target audience: everyone.

License: Unknown.

Original source

Catalog source: SkillHub Club.

Repository owner: benchflow-ai.

This is still a mirrored public skill entry. Review the repository before installing into production workflows.

What it helps with

  • Install crypto-analysis into Claude Code, Codex CLI, Gemini CLI, or OpenCode workflows
  • Review https://github.com/benchflow-ai/SkillsBench before adding crypto-analysis to shared team environments
  • Use crypto-analysis for development workflows

Works across

Claude CodeCodex CLIGemini CLIOpenCode

Favorites: 0.

Sub-skills: 0.

Aggregator: No.

Original source / Raw SKILL.md

---
name: crypto-analysis
description: Breaks cryptographic systems and decrypts ciphertext. Use when working with RSA, AES, XOR, classical ciphers, hash functions, or when challenge involves encryption, decryption, keys, or mathematical crypto attacks.
allowed-tools: Bash, Read, Write, Grep, Glob
---

# Crypto Analysis Skill

## Quick Workflow

```
Progress:
- [ ] Try Ciphey auto-decrypt first
- [ ] Identify crypto type (RSA/AES/XOR/classical)
- [ ] Check for known weaknesses
- [ ] Implement attack
- [ ] Decrypt flag
```

## Step 1: Auto-Decrypt (Try First!)

```bash
ciphey -t "ENCODED_TEXT"    # Auto-detects and decrypts
ciphey -f encrypted.txt     # From file
```

## Step 2: Identify Crypto Type

| Pattern | Crypto Type | Reference |
|---------|-------------|-----------|
| `n, e, c` variables | RSA | [reference/rsa-attacks.md](reference/rsa-attacks.md) |
| 16/32 byte key, IV | AES | [reference/aes-attacks.md](reference/aes-attacks.md) |
| XOR operations | XOR/Stream | [reference/classical.md](reference/classical.md) |
| Polynomial mod | Lattice | [reference/lattice.md](reference/lattice.md) |

## RSA Attack Decision Tree

```
├── e small (≤5)?     → Direct eth root
├── e very large?     → Wiener's Attack
├── Multiple n,e,c?   → Hastad's Broadcast
├── Same n, diff e?   → Common Modulus
├── GCD(n1,n2) > 1?   → Common Factor
├── p ≈ q?            → Fermat Factorization
├── dp/dq leaked?     → Partial Key Recovery
└── Default           → FactorDB / yafu
```

**Full implementations**: [reference/rsa-attacks.md](reference/rsa-attacks.md)

## Quick Commands

```bash
# Auto-decrypt
ciphey -t "text"

# XOR analysis
xortool encrypted.bin
xortool -c 20 encrypted.bin  # Expect spaces

# Factor large n
yafu "factor(<n>)"

# RSA tool
python3 RsaCtfTool.py -n <n> -e <e> --uncipher <c>

# Lattice (SageMath)
sage solve.sage
```

## Reference Files

- **[RSA Attacks](reference/rsa-attacks.md)**: Small e, Wiener, Hastad, Common Modulus, Fermat, FactorDB
- **[AES Attacks](reference/aes-attacks.md)**: ECB detection, CBC flip, Padding Oracle
- **[Classical/XOR](reference/classical.md)**: Ciphey, xortool, frequency analysis, Vigenère
- **[Lattice](reference/lattice.md)**: Coppersmith, LLL, HNP
crypto-analysis | SkillHub