- Input : n or (p, q)
- Select n or primes (p, q) to input
⚠️ n must need demux into 2 primes- p and q must be two primes
- Ex :
- If Q given n : input (n, -1, -1)
- If Q given p, q : input (-1, p, q)
- Input e :
- Can setup by itself or given
- Ex :
- If Q given e : just input e
- If Q not given e : input -1
- Public key : [n, e]
- Private key : [n, d]
- Mode : "enc"
- Input : original message
- Output : encrypted message
- Mode : "dec"
- Input : encrypted message
- Output : original message
- Instruction :
- "chmod" : toggle the mode
- "exit" : exit
- Just run
simulation.py