---
title: "CWE-780: Use of RSA Algorithm without OAEP"
url: https://radicalnotion.ai/cwe/cwe-780
type: cwe
description: "The product uses the RSA algorithm but does not incorporate Optimal Asymmetric Encryption Padding (OAEP)."
updated: 2026-11-10
source: RadicalNotion.AI
license: CC BY-NC 4.0 (https://creativecommons.org/licenses/by-nc/4.0/)
---

# CWE-780: Use of RSA Algorithm without OAEP

- **Abstraction:** Variant
- **Structure:** Simple
- **Status:** Incomplete
- **Likelihood of exploit:** Medium
- **CVEs with this as primary weakness:** 4
- **Of those, in CISA KEV:** 0
- **New in 2026:** 1
- **CWE catalog version:** 4.21

## Description

The product uses the RSA algorithm but does not incorporate Optimal Asymmetric Encryption Padding (OAEP).

## Background

Padding schemes are often used with cryptographic algorithms to make the plaintext less predictable and complicate attack efforts. The OAEP scheme is often used with RSA to nullify the impact of predictable common text.

## Modes of introduction

| Phase | Note |
| --- | --- |
| Implementation | REALIZATION: This weakness is caused during implementation of an architectural security tactic. |

## Common consequences

| Scope | Impact | Note |
| --- | --- | --- |
| Access Control | Bypass Protection Mechanism | Without using OAEP, this might weaken the encryption. It will take less work for an attacker to decrypt the data or to infer patterns from the ciphertext. |

## Detection methods

### Automated Static Analysis

Automated static analysis, commonly referred to as Static Application Security Testing (SAST), can find some instances of this weakness by analyzing source code (or binary/compiled code) without having to execute it. Typically, this is done by building a model of data flow and control flow, then searching for potentially-vulnerable patterns that connect "sources" (origins of input) with "sinks" (destinations where the data interacts with external components, a lower layer such as the OS, etc.)

Effectiveness: High

## Demonstrative examples

### Example 1

The example below attempts to build an RSA cipher.

Bad code:

```java
public Cipher getRSACipher() {
    Cipher rsa = null;
    try {
        rsa = javax.crypto.Cipher.getInstance("RSA/NONE/NoPadding");
    }
    catch (java.security.NoSuchAlgorithmException e) {
        log("this should never happen", e);
    }
    catch (javax.crypto.NoSuchPaddingException e) {
        log("this should never happen", e);
    }
    return rsa;
}
```

Good code:

```java
public Cipher getRSACipher() {
    Cipher rsa = null;
    try {
        rsa = javax.crypto.Cipher.getInstance("RSA/ECB/OAEPWithMD5AndMGF1Padding");
    }
    catch (java.security.NoSuchAlgorithmException e) {
        log("this should never happen", e);
    }
    catch (javax.crypto.NoSuchPaddingException e) {
        log("this should never happen", e);
    }
    return rsa;
}
```

While the previous code successfully creates an RSA cipher, the cipher does not use padding. The following code creates an RSA cipher using OAEP.

## Real CVEs with this weakness

| CVE | Title | Severity | CVSS | EPSS | CISA KEV | Published |
| --- | --- | --- | --- | --- | --- | --- |
| CVE-2022-40722 | Misconfiguration of RSA padding for offline MFA in the PingID Adapter for PingFederate. | high | 7.7 | - | No | 2023-04-25 |
| CVE-2024-51456 | IBM Robotic Process Automation information disclosure | medium | 5.9 | - | No | 2025-01-12 |
| CVE-2025-9071 | Insecure RSA-OAEP implementation with all-zero seed for padding in Oberon PSA Crypto | low | 2.3 | - | No | 2025-08-29 |
| CVE-2026-62271 | ex\_aws\_kms defaults RSA key-material wrapping to PKCS#1 v1.5 in get\_parameters\_for\_import/3 | low | 2.1 | - | No | 2026-11-24 |

## Related weaknesses

| Relationship | CWE | Name |
| --- | --- | --- |
| Parent | [CWE-327](https://radicalnotion.ai/cwe/cwe-327) | Use of a Broken or Risky Cryptographic Algorithm |

## Frequently asked questions

### What is CWE-780?

The product uses the RSA algorithm but does not incorporate Optimal Asymmetric Encryption Padding (OAEP).

### What CVEs are caused by CWE-780?

4 recorded CVEs are attributed to CWE-780, including CVE-2022-40722, CVE-2024-51456 and CVE-2025-9071.

### How is CWE-780 detected?

Automated Static Analysis: Automated static analysis, commonly referred to as Static Application Security Testing (SAST), can find some instances of this weakness by analyzing source code (or binary/compiled code) without having to execute it. Typically, this is done by building a model of data flow and control flow, then searching for potentially-vulnerable patterns that connect "sources" (origins of input) with "sinks" (destinations where the data interacts with external components, a lower layer such as the OS, etc.)

### What are the consequences of CWE-780?

Exploiting CWE-780 can lead to: Bypass Protection Mechanism.

### Is CWE-780 actively exploited?

4 recorded CVEs are caused by CWE-780; none are currently in CISA's KEV catalog of actively exploited flaws.

Primary source: [MITRE CWE](https://cwe.mitre.org/data/definitions/780.html)

---

Source: [RadicalNotion.AI](https://radicalnotion.ai/cwe/cwe-780). Licensed CC BY-NC 4.0; attribute RadicalNotion.AI and link the source page when you reuse this data.
