RSA public key encryption uses an asymmetric key pair so that one key can encrypt data and only the matching private key can decrypt it. Ransomware often uses it to protect the symmetric file-encryption key, making direct recovery of the session key impractical without access to the attacker’s private key.
How RSA Public Key Encryption Works
RSA is an asymmetric encryption scheme built on a matched key pair. The public key can encrypt data, while only the corresponding private key can decrypt it, which makes RSA useful when two parties need confidentiality without first sharing a secret key.
That basic property is why RSA is often discussed alongside certificate-based trust and key exchange. In practice, RSA is less about moving large volumes of data and more about protecting a small secret or establishing trust in a larger cryptographic workflow.
Why RSA Is Used in Real Systems
RSA is commonly used to encrypt or wrap a symmetric session key, rather than bulk file contents. That pattern keeps performance practical, because symmetric algorithms handle large data more efficiently while RSA protects the short-lived key material that unlocks it.
RSA also appears in certificate ecosystems, where public keys are distributed openly and private keys remain protected by the certificate holder. Machine Identity, PKI and Certificate Lifecycle Guide is a useful reference for understanding how public-key certificates, lifecycle automation, and private-key protection fit together in operational environments.
Security Boundaries and Failure Modes
The security of RSA depends on more than the math. Key size, padding mode, randomness, private-key storage, and certificate handling all affect whether the scheme remains resistant to practical attack. RSA can be sound as a primitive and still fail badly when keys are exposed, reused incorrectly, or wrapped in weak implementation choices.
One of the most important operational distinctions is that RSA protects data only if the private key stays secret. Once the private key is copied, backed up insecurely, logged, or otherwise disclosed, any ciphertext encrypted to the matching public key becomes recoverable.
When organisations depend on RSA keys to protect other secrets, Cryptographic Key Management Guide becomes relevant because key lifecycle, inventory, rotation, and access control determine whether the encryption actually delivers durable protection.
RSA in Ransomware and Data Recovery Contexts
In ransomware operations, RSA is often used to protect the attacker-controlled symmetric key or a per-victim keying secret. That design makes direct recovery difficult, because the victim can usually see the encrypted file but cannot derive the private key needed to unwrap the session key.
The practical consequence is that RSA can strengthen attacker-side control over encrypted data while leaving defenders with limited recovery options unless they have clean backups, offline copies, or another way to restore the original key material. The encryption may be mathematically correct and still serve a harmful purpose when embedded in malware.
For a concrete example of how encrypted secrets and decryption keys can be abused after compromise, LastPass breach 2022 shows why protecting key material is as important as protecting the ciphertext itself.
Risk and Threat Considerations
RSA does not fail because attackers can "break encryption" in the abstract. It fails when private keys, padding implementations, or surrounding trust systems are weak enough that ciphertext can be decrypted, forged, or misused despite the mathematics remaining intact.
Failure mechanism: Private-key theft, weak padding, poor randomness, or certificate misuse can turn RSA-protected data into recoverable plaintext or allow trust to be subverted.
Impact: Compromise can expose stored secrets, defeat encrypted backups, undermine secure transport, and let ransomware or other attackers preserve exclusive access to protected data.
Standards & Framework Alignment
This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.
NIST SP 800-57, NIST SP 800-53 Rev 5 and NIST CSF 2.0 set the technical controls, while ISO/IEC 27001:2022 defines the regulatory obligations.
| Framework | Control / Reference | Relevance |
|---|---|---|
| NIST SP 800-57 | Key Management | RSA security depends on key lifecycle, cryptoperiods, and private-key protection. |
| Recommendation — Manage RSA key generation, storage, rotation, and destruction under a formal key lifecycle policy. | ||
| NIST SP 800-53 Rev 5 | IA-5 — Authenticator Management | RSA private keys function as authenticating material that must be managed securely. |
| SC-12 — Cryptographic Key Establishment and Management | RSA is used to establish and protect key material in asymmetric cryptography. | |
| Recommendation — Control issuance, storage, rotation, and revocation of RSA key material. Use approved procedures to establish, protect, and retire RSA key material. | ||
| ISO/IEC 27001:2022 | A.8.24 — Use of cryptography | RSA is a cryptographic control that falls under organisational cryptography use and governance. |
| Recommendation — Define approved RSA usage, key handling rules, and cryptographic responsibilities. | ||
| NIST CSF 2.0 | PR.DS-01 — Data-at-rest is protected | RSA can protect stored secrets or wrapped session keys supporting data-at-rest protection. |
| Recommendation — Protect stored sensitive data with approved cryptographic safeguards and secure key handling. | ||
Practitioner Guidance
What to watch for: Treat RSA as one layer in a larger cryptographic control set, not as a complete security program. The real control point is the private key, so key generation quality, private-key storage, rotation policy, and certificate lifecycle all need governance.
Practitioner takeaway: If RSA is protecting something valuable, the surrounding key management and operational handling determine whether the scheme remains trustworthy in practice.
Related resources from NHI Mgmt Group
- What is the difference between private key encryption and public key encryption for practitioners?
- How should security teams use identity-based encryption when trusted public key distribution is the main bottleneck?
- What is the difference between symmetric encryption and public key encryption in a quantum-safe migration plan?
- Why do RSA and Diffie-Hellman key sizes need to be much larger than symmetric encryption keys to provide comparable security?
Deepen Your Knowledge
Reviewed and updated by the NHIMG editorial team on September 27, 2026.
NHI Mgmt Group — the #1 independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org