---
title: "CWE-342: Predictable Exact Value from Previous Values"
url: https://radicalnotion.ai/cwe/cwe-342
type: cwe
description: "An exact value or random number can be precisely predicted by observing previous values."
updated: 2026-11-10
source: RadicalNotion.AI
license: CC BY-NC 4.0 (https://creativecommons.org/licenses/by-nc/4.0/)
---

# CWE-342: Predictable Exact Value from Previous Values

- **Abstraction:** Base
- **Structure:** Simple
- **Status:** Draft
- **CVEs with this as primary weakness:** 7
- **Of those, in CISA KEV:** 0
- **New in 2026:** 1
- **CWE catalog version:** 4.21

## Description

An exact value or random number can be precisely predicted by observing previous values.

## Modes of introduction

| Phase | Note |
| --- | --- |
| Architecture and Design | - |
| Implementation | - |

## Common consequences

| Scope | Impact | Note |
| --- | --- | --- |
| Other | Varies by Context | - |

## Potential mitigations

### Mitigation

Increase the entropy used to seed a PRNG.

### Architecture and Design, Requirements (Libraries or Frameworks)

Use products or modules that conform to FIPS 140-2 \[REF-267\] to avoid obvious entropy problems. Consult FIPS 140-2 Annex C ("Approved Random Number Generators").

### Implementation

Use a PRNG that periodically re-seeds itself using input from high-quality sources, such as hardware devices with high entropy. However, do not re-seed too frequently, or else the entropy source might block.

## Observed examples

| CVE | Description |
| --- | --- |
| CVE-2002-1463 | Firewall generates easily predictable initial sequence numbers (ISN), which allows remote attackers to spoof connections. |
| CVE-1999-0074 | Listening TCP ports are sequentially allocated, allowing spoofing attacks. |
| CVE-1999-0077 | Predictable TCP sequence numbers allow spoofing. |
| CVE-2000-0335 | DNS resolver uses predictable IDs, allowing a local user to spoof DNS query results. |

## Real CVEs with this weakness

| CVE | Title | Severity | CVSS | EPSS | CISA KEV | Published |
| --- | --- | --- | --- | --- | --- | --- |
| CVE-2020-16226 | Mitsubishi Electric Multiple Products | critical | 9.8 | - | No | 2020-10-05 |
| CVE-2014-9196 | Eaton’s Cooper Power Series Form 6 Control and Idea/IdeaPlus Relays with Ethernet | critical | 9.3 | - | No | 2015-07-20 |
| CVE-2023-3373 | Predictable Exact Value from Previous Values in Mitsubishi Electric GOT2000 and GOT SIMPLE | critical | 9.1 | - | No | 2023-08-03 |
| CVE-2022-27577 | - | critical | 9.1 | - | No | 2022-04-11 |
| CVE-2026-88778 | TCP Initial Sequence Number (ISN) prediction | high | 8.8 | - | No | 2026-09-27 |
| CVE-2022-29930 | - | high | 8.7 | - | No | 2022-05-12 |
| CVE-2020-28388 | Initial Sequence Numbers (ISNs) for TCP connections are derived from an insufficiently random source. As a result, the ISN of current and future TCP connections could be predictable. An attacker could hijack existing sessions or spoof future ones. | medium | 6.5 | - | No | 2021-02-09 |

## Related weaknesses

| Relationship | CWE | Name |
| --- | --- | --- |
| Parent | [CWE-340](https://radicalnotion.ai/cwe/cwe-340) | Generation of Predictable Numbers or Identifiers |

## Taxonomy mappings

| Taxonomy | Entry | Id | Fit |
| --- | --- | --- | --- |
| PLOVER | Predictable Exact Value from Previous Values | - | - |

## Frequently asked questions

### What is CWE-342?

An exact value or random number can be precisely predicted by observing previous values.

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

7 recorded CVEs are attributed to CWE-342, including CVE-2020-16226, CVE-2014-9196 and CVE-2023-3373.

### How do you prevent CWE-342?

Increase the entropy used to seed a PRNG.

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

Exploiting CWE-342 can lead to: Varies by Context.

### Is CWE-342 actively exploited?

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

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

---

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