CWE-350: Reliance on Reverse DNS Resolution for a Security-Critical Action
The product performs reverse DNS resolution on an IP address to obtain the hostname and make a security decision, but it does not properly ensure that the IP address is truly associated with the hostname.
Last updated
Overview
Since DNS names can be easily spoofed or misreported, and it may be difficult for the product to detect if a trusted DNS server has been compromised, DNS names do not constitute a valid authentication mechanism. When the product performs a reverse DNS resolution for an IP address, if an attacker controls the DNS server for that IP address, then the attacker can cause the server to return an arbitrary hostname. As a result, the attacker may be able to bypass authentication, cause the wrong hostname to be recorded in log files to hide activities, or perform other attacks. Attackers can spoof DNS names by either (1) compromising a DNS server and modifying its records (sometimes called DNS cache poisoning), or (2) having legitimate control over a DNS server associated with their IP address.
Real-world CVEs
20 recorded CVEs are caused by CWE-350 (Reliance on Reverse DNS Resolution for a Security-Critical Action). The highest-severity and most recent are shown first. 6 new CWE-350 CVEs have been recorded so far in 2026 (4 in 2025).
- CVE-2026-1490
Spam protection, Honeypot, Anti-Spam by CleanTalk <= 6.71 - Authorization Bypass via Reverse DNS (PTR record) Spoofing to Unauthenticated Arbitrary Plugin Installation
Critical · CVSS 9.8 · EPSS 63th2026-02-15 - CVE-2023-52235High · CVSS 8.8 · EPSS 41th2024-04-05
- CVE-2021-34561High · CVSS 8.8 · EPSS 55th2021-08-31
- CVE-2018-7160High · CVSS 8.8 · EPSS 95th2018-05-17
- CVE-2025-8036
DNS rebinding circumvents CORS
High · CVSS 8.1 · EPSS 34th2025-07-22 - CVE-2017-0902High · CVSS 8.1 · EPSS 91th2017-08-31
- CVE-2026-33002High · CVSS 7.5 · EPSS 22th2026-03-18
- CVE-2021-22884High · CVSS 7.5 · EPSS 98th2021-03-03
- CVE-2026-24281
Apache ZooKeeper: Reverse-DNS fallback enables hostname verification bypass in ZooKeeper ZKTrustManager
High · CVSS 7.4 · EPSS 46th2026-03-07 - CVE-2026-36604Medium · CVSS 6.5 · EPSS 17th2026-06-03
- CVE-2025-61430Medium · CVSS 6.5 · EPSS 14th2025-10-24
- CVE-2025-59956
AgentAPI exposed user chat history via a DNS rebinding attack
Medium · CVSS 6.5 · EPSS 32th2025-09-29
Showing 12 of 20 recorded CWE-350 CVEs. Track new ones as they are published and get AI-written analysis and fixes.
Monitor CWE-350 vulnerabilitiesCommon consequences
What can happen when CWE-350 is exploited.
Gain Privileges or Assume Identity, Bypass Protection Mechanism
Affects: Access Control
Malicious users can fake authentication information by providing false DNS information.
How it happens
When it is introduced
Typically introduced during these phases of the software lifecycle.
How to prevent it
Practical mitigations for CWE-350, grouped by where in the lifecycle they apply.
Use other means of identity verification that cannot be simply spoofed. Possibilities include a username/password or certificate.
Perform proper forward and reverse DNS lookups to detect DNS spoofing.
How to detect it
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
Code examples
Illustrative examples from MITRE showing how the weakness appears in code.
The following code samples use a DNS lookup in order to decide whether or not an inbound request is from a trusted host. If an attacker can poison the DNS cache, they can gain trusted status.
Vulnerable example
struct hostent *hp;struct in_addr myaddr;Vulnerable example
String ip = request.getRemoteAddr();Vulnerable example
IPAddress hostIPAddress = IPAddress.Parse(RemoteIpAddress);IP addresses are more reliable than DNS names, but they can also be spoofed. Attackers can easily forge the source IP address of the packets they send, but response packets will return to the forged IP address. To see the response packets, the attacker has to sniff the traffic between the victim machine and the forged IP address. In order to accomplish the required sniffing, attackers typically attempt to locate themselves on the same subnet as the victim machine. Attackers may be able to circumvent this requirement by using source routing, but source routing is disabled across much of the Internet today. In summary, IP address verification can be a useful part of an authentication scheme, but it should not be the single factor required for authentication.
In these examples, a connection is established if a request is made by a trusted host.
Vulnerable example
sd = socket(AF_INET, SOCK_DGRAM, 0);Vulnerable example
while(true) {These examples check if a request is from a trusted host before responding to a request, but the code only verifies the hostname as stored in the request packet. An attacker can spoof the hostname, thus impersonating a trusted client.
Illustrative examples
Real CVEs that MITRE cites as examples of this weakness.
- CVE-2001-1488 — Does not do double-reverse lookup to prevent DNS spoofing.
- CVE-2001-1500 — Does not verify reverse-resolved hostnames in DNS.
- CVE-2000-1221 — Authentication bypass using spoofed reverse-resolved DNS hostnames.
- CVE-2002-0804 — Authentication bypass using spoofed reverse-resolved DNS hostnames.
- CVE-2001-1155 — Filter does not properly check the result of a reverse DNS lookup, which could allow remote attackers to bypass intended access restrictions via DNS spoofing.
- CVE-2004-0892 — Reverse DNS lookup used to spoof trusted content in intermediary.
- CVE-2003-0981 — Product records the reverse DNS name of a visitor in the logs, allowing spoofing and resultant XSS.
Terminology & mappings
Mapped taxonomies
- PLOVER: Improperly Trusted Reverse DNS
- CLASP: Trusting self-reported DNS name
- Software Fault Patterns: Faulty endpoint authentication (SFP29)
Attack patterns
CAPEC attack patterns that exploit this weakness.
Frequently asked questions
Common questions about CWE-350.
- What is CWE-350?
- The product performs reverse DNS resolution on an IP address to obtain the hostname and make a security decision, but it does not properly ensure that the IP address is truly associated with the hostname.
- What CVEs are caused by CWE-350?
- 20 recorded CVEs are attributed to CWE-350, including CVE-2026-1490, CVE-2023-52235, CVE-2021-34561.
- How do you prevent CWE-350?
- Use other means of identity verification that cannot be simply spoofed. Possibilities include a username/password or certificate.
- How is CWE-350 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-350?
- Exploiting CWE-350 can lead to: Gain Privileges or Assume Identity, Bypass Protection Mechanism.
- Is CWE-350 actively exploited?
- 20 recorded CVEs are caused by CWE-350; none are currently in CISA's KEV catalog of actively exploited flaws.
References
- MITRE CWE definition (CWE-350) (opens in a new tab)
- CWE-350 vulnerabilities on NVD (opens in a new tab)
- Learn: What is a CWE?
Weakness data is sourced from the MITRE CWE catalog (v4.20). CVE associations are aggregated and kept current by RadicalNotion.AI.
Stay ahead of CWE-350
Get alerted the moment a new CWE-350 vulnerability affects your stack, with AI-written analysis, severity context, and remediation guidance.