mcpField
C
cryptography

cryptography

github.com/transilienceaiSecurity598151 installsUpdated 13w ago
Repository

About cryptography

cryptography is a security skill for practical cryptanalysis in CTF and penetration-testing engagements. It focuses on finding algebraic or linear structure that enables faster-than-brute-force recovery, and implementing solvers in Python where possible.

Key features

  1. 01Custom cipher and hash analysis
  2. 02RSA factoring and lattice recovery
  3. 03Smooth-order discrete-log attacks
  4. 04Differential fault analysis
  5. 05Secret recovery over non-prime moduli

Use cases

  1. 01Analyzing custom cryptographic challenges
  2. 02Recovering RSA secrets from structured primes
  3. 03Using chosen-input oracles to test attack paths
  4. 04Recovering keys from faulty AES ciphertexts

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/transilienceai/communitytools --skill cryptography

After installing, type/cryptographyin Claude Code to confirm it loaded.

Bundled files

References and scripts installed along with SKILL.md.

reference/
cryptography-principles.md
INDEX.md
lattice-attacks.md
linear-secret-recovery.md
reference/scenarios/classical/
repeating-key-xor.md
reference/scenarios/lattice/
agcd-attack.md
boneh-durfee-low-d.md
coppersmith-known-bits.md
lll-basis-reduction.md
reference/scenarios/padding-oracle/
cbc-padding-oracle.md
ecb-prefix-oracle.md
pkcs1-v1.5-bleichenbacher.md
reference/scenarios/rsa-quirks/
common-modulus.md
fermat-close-primes.md
low-public-exponent.md
small-prime-factorization.md
wiener-attack.md
reference/scenarios/secret-sharing/
shamir-non-prime-modulus.md
reference/scenarios/signature-forgery/
ecdsa-nonce-reuse.md
gcd-transcript-operand-recovery.md
jwt-alg-confusion.md
rsa-pkcs1-v1.5-bleichenbacher.md
reference/scenarios/weak-rng/
dual-ec-backdoor.md
lcg-state-recovery.md
mt19937-state-recovery.md

Details

From the project README

Cryptography

Scope

Practical cryptanalysis for CTF and pentest engagements: identifying when a cryptographic primitive's structure (custom hash, partial leaks, related primes, bad RNG, weak modes) admits a faster-than-brute-force solver, then implementing that solver in pure Python where possible. Covers RSA-style algebraic factoring, lattice/AGCD recovery, GF(2) linear collapse of "complicated-looking" custom ciphers, smooth-order DLP, differential fault attacks, and Shamir-style secret-sharing recovery over non-prime moduli. Always read source first to detect linearity/algebraic structure before reaching for SageMath or symbolic solvers.

When to use

  • A challenge or target ships custom crypto (custom hash, custom block cipher, hand-rolled key derivation) and you need to look for affine / GF(2)-linear collapse.
  • RSA-style primitives with structured primes (p = a·r + b, phi(n) perfect square, multi-prime hint files, common factors).
  • A service exposes a chosen-ciphertext / chosen-input oracle and you suspect padding-oracle, smooth-order DLP, or Bleichenbacher-style recovery.
  • AES with fault injection (correct + faulty ciphertext for the same key — Piret-Quisquater DFA).
  • Shamir secret sharing or threshold schemes with non-prime moduli (2-adic recovery via Lagrange interpolation with valuation tracking).

References

Comments

Markdown supported