---
title: "CWE-210: Self-generated Error Message Containing Sensitive Information"
url: https://radicalnotion.ai/cwe/cwe-210
type: cwe
description: "The product identifies an error condition and creates its own diagnostic or error messages that contain sensitive information."
updated: 2026-11-10
source: RadicalNotion.AI
license: CC BY-NC 4.0 (https://creativecommons.org/licenses/by-nc/4.0/)
---

# CWE-210: Self-generated Error Message Containing Sensitive Information

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

## Description

The product identifies an error condition and creates its own diagnostic or error messages that contain sensitive information.

## Modes of introduction

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

## Common consequences

| Scope | Impact | Note |
| --- | --- | --- |
| Confidentiality | Read Application Data | - |

## Potential mitigations

### Implementation, Build and Compilation (Compilation or Build Hardening)

Debugging information should not make its way into a production release.

### Implementation, Build and Compilation (Environment Hardening)

Debugging information should not make its way into a production release.

## Demonstrative examples

### Example 1

The following code uses custom configuration files for each user in the application. It checks to see if the file exists on the system before attempting to open and use the file. If the configuration file does not exist, then an error is generated, and the application exits.

Bad code:

```perl
$uname = GetUserInput("username");

# avoid CWE-22, CWE-78, others.
if ($uname !~ /^\w+$/)
{
    ExitError("Bad hacker!") ;
}

$filename = "/home/myprog/config/" . $uname . ".txt";
if (!(-e $filename))
{
    ExitError("Error: $filename does not exist");
}
```

If this code is running on a server, such as a web application, then the person making the request should not know what the full pathname of the configuration directory is. By submitting a username that is not associated with a configuration file, an attacker could get this pathname from the error message. It could then be used to exploit path traversal, symbolic link following, or other problems that may exist elsewhere in the application.

## Observed examples

| CVE | Description |
| --- | --- |
| CVE-2005-1745 | Infoleak of sensitive information in error message (physical access required). |

## Real CVEs with this weakness

| CVE | Title | Severity | CVSS | EPSS | CISA KEV | Published |
| --- | --- | --- | --- | --- | --- | --- |
| CVE-2023-41027 | Juplink RX4-1500 Credential Disclosure Vulnerability | high | 8.8 | - | No | 2023-09-22 |
| CVE-2021-40126 | Cisco Umbrella Email Enumeration Vulnerability | medium | 4.3 | - | No | 2021-11-04 |

## Related weaknesses

| Relationship | CWE | Name |
| --- | --- | --- |
| Parent | [CWE-209](https://radicalnotion.ai/cwe/cwe-209) | Generation of Error Message Containing Sensitive Information |

## Taxonomy mappings

| Taxonomy | Entry | Id | Fit |
| --- | --- | --- | --- |
| PLOVER | Product-Generated Error Message Infoleak | - | - |
| Software Fault Patterns | Exposed Data | SFP23 | - |

## Frequently asked questions

### What is CWE-210?

The product identifies an error condition and creates its own diagnostic or error messages that contain sensitive information.

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

2 recorded CVEs are attributed to CWE-210, including CVE-2023-41027 and CVE-2021-40126.

### How do you prevent CWE-210?

Debugging information should not make its way into a production release.

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

Exploiting CWE-210 can lead to: Read Application Data.

### Is CWE-210 actively exploited?

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

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

---

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