An oracle attack is a cryptographic attack that learns secret information by sending chosen inputs to a system and studying how it responds. The “oracle” is any observable difference that leaks data, such as distinct error messages, timing changes, or success and failure patterns. Even when the core algorithm is sound, these side channels can reveal padding validity, key material, or partial plaintext.
This matters in RSA because many breaks depend less on factoring and more on implementation behavior. For example, a decryption service that returns different errors for malformed ciphertexts can become a padding oracle, allowing an attacker to recover messages incrementally. Defenders reduce this risk by using constant-time code, uniform error handling, modern padding schemes, and interfaces that do not reveal whether an input was well formed.


