Asymmetric Cryptography
cryptointermediate
Index of asymmetric crypto pages - RSA basics, ECC basics, and Diffie-Hellman attacks.
cryptoasymmetricrsaeccdiffie-hellmanindex
Asymmetric Cryptography
Asymmetric crypto challenges usually revolve around math or implementation mistakes rather than brute-forcing keys. RSA, ECC, and Diffie-Hellman are the core families to understand first.
Pages in This Subsection
| Page | Difficulty | Focus |
|---|---|---|
| RSA Basics | Beginner | Key generation, encryption, math |
| ECC Basics | Intermediate | Curves, ECDSA, ECDH fundamentals |
| Diffie-Hellman Attacks | Intermediate | Weak p, small subgroup, BSGS |
Quick RSA Attack Selection
Given , , :
- and : cube-root / small exponent
- factorable: FactorDB, yafu, Fermat
- Very large , small : Wiener (or related)
- Same , same , : common modulus
- Same , , three coprime moduli: Håstad broadcast
Given , , , : compute (or ), then .
Automate: python3 RsaCtfTool.py -n N -e E --uncipher C
Quick ECC Attack Selection
| Observation | Technique |
|---|---|
| Two signatures with same r? | Nonce reuse |
| ECDSA nonces biased/short? | Lattice attack (HNP) |
| Server accepts arbitrary points? | Invalid curve attack |
| Curve order = prime p? | Smart's attack (anomalous) |
| Small embedding degree? | MOV attack |
Use SageMath for all ECC math.
Last updated on