This Windows Forms application provides a simple GUI for RSA encryption and decryption along with conversion tools to view cipher output in binary, decimal, and hexadecimal formats.
- β
RSA Key Generation (with custom prime inputs
p
andq
) - β
Text Encryption using Public Key
(e, n)
- β
Text Decryption using Private Key
(d, n)
- β
View Encrypted Text as:
- Decimal
- Binary
- Hexadecimal
- β Easy-to-use GUI built with Windows Forms (C#)
- β Error handling for invalid input and formats
- C#
- Windows Forms (.NET 6.0 / .NET Framework)
- RSA Algorithm (simplified for learning/demo purposes)
- System.Text & System.Security.Cryptography
- You enter two prime numbers (
p
,q
) and click Generate Keys. - App calculates:
- Modulus
n = p * q
- Public Key exponent
e
- Private Key exponent
d
- Modulus
- You enter a plaintext message and click Encrypt:
- The message is encrypted using
e
andn
. - Output is shown in decimal form.
- Can also be converted to binary or hex.
- The message is encrypted using
- You paste or type the cipher into the decryption box and click Decrypt:
- Cipher is decrypted using
d
andn
to recover the original message.
- Cipher is decrypted using
Use the following values to test the encryption/decryption:
p = 61
q = 53
Message: Hello