RSA is an asymmetric cryptographic algorithm used for encryption, decryption, digital signatures, and key exchange. It uses a pair of keys: a public key (shared) and a private key (kept secret).
Inputs
Key Size: The RSA key pair size in bits.
Padding: RSA padding scheme for encryption/decryption.
Public/Private Key (PEM): RSA key in PEM format (-----BEGIN PUBLIC KEY----- / -----BEGIN PRIVATE KEY-----).
Data: Data to encrypt/decrypt or sign/verify. Max size depends on key size and padding.
Tips
RSA is typically used to encrypt small data like symmetric keys (key wrapping).
For signing, the data is hashed before signing — no size limit for the message.
OAEP padding is preferred over PKCS#1 v1.5 for encryption.
Key generation for 4096-bit may take a few seconds.