/

CVE-2026-121392

Severity:

HIGH RISK

(7.4)

Improper Certificate Validation (CWE-295) in FreeRDP

CVE-2026-121392

Analyzed

Vulnerability type

Category:

Improper Certificate Validation

CWE:

CWE-295

Impact:

Man-in-the-Middle Session Interception

Severity:

HIGH RISK

(7.4)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

FreeRDP may accept a server certificate even when its Subject Alternative Name (SAN) entries do not match the server identity, because validation can fall back to the Common Name or compare an IP address against a DNS name. A network-positioned attacker with a certificate issued by a CA trusted by the client could exploit this behavior to impersonate an RDP server and intercept a session.

FreeRDP may accept a server certificate even when its Subject Alternative Name (SAN) entries do not match the server identity, because validation can fall back to the Common Name or compare an IP address against a DNS name. A network-positioned attacker with a certificate issued by a CA trusted by the client could exploit this behavior to impersonate an RDP server and intercept a session.

Affected context

The issue occurs during server certificate checks in FreeRDP's tls_verify_certificate() function. Deployments may be at risk when clients connect to servers over networks an attacker can observe or influence, and the client trusts a CA capable of issuing a certificate for the attacker-controlled identity.

The issue occurs during server certificate checks in FreeRDP's tls_verify_certificate() function. Deployments may be at risk when clients connect to servers over networks an attacker can observe or influence, and the client trusts a CA capable of issuing a certificate for the attacker-controlled identity.

Exploit preconditions

  • Attack surface: TLS certificate validation during an RDP connection
  • Required access: The attacker must be able to position themselves between the FreeRDP client and the intended server or otherwise redirect the connection.
  • Certificate condition: The attacker must present a certificate chaining to a CA trusted by the client.
  • Trigger point: The client verifies the server certificate and identity as the RDP session is established.
  • Why exploitation is possible: Permissive Common Name fallback and incorrect handling of IP identities can allow a certificate to pass identity checks despite a SAN mismatch.
  • Attack surface: TLS certificate validation during an RDP connection
  • Required access: The attacker must be able to position themselves between the FreeRDP client and the intended server or otherwise redirect the connection.
  • Certificate condition: The attacker must present a certificate chaining to a CA trusted by the client.
  • Trigger point: The client verifies the server certificate and identity as the RDP session is established.
  • Why exploitation is possible: Permissive Common Name fallback and incorrect handling of IP identities can allow a certificate to pass identity checks despite a SAN mismatch.

Why this happens

The certificate verification logic does not enforce strict identity matching. It accepts a Common Name fallback when SAN entries do not match and can treat an IP literal as matching a DNS string. This is an improper certificate validation flaw (CWE-295): the peer's certificate chain may be trusted, but the certificate is not reliably bound to the specific server identity the client intended to contact.

The certificate verification logic does not enforce strict identity matching. It accepts a Common Name fallback when SAN entries do not match and can treat an IP literal as matching a DNS string. This is an improper certificate validation flaw (CWE-295): the peer's certificate chain may be trusted, but the certificate is not reliably bound to the specific server identity the client intended to contact.

Potential impact

  • An attacker may impersonate an RDP server and intercept client connections.
  • Session contents, including keystrokes, clipboard data, and screen content, could be exposed.
  • An attacker could potentially alter relayed session traffic or use the impersonation to support further attacks.
  • An attacker may impersonate an RDP server and intercept client connections.
  • Session contents, including keystrokes, clipboard data, and screen content, could be exposed.
  • An attacker could potentially alter relayed session traffic or use the impersonation to support further attacks.

General mitigation guidance

Defensive patterns focus on strict, standards-aligned server identity verification:

  • Require identity matches against appropriate SAN entries and avoid Common Name fallback when SAN is present or required.
  • Compare IP addresses only with IP-address SAN entries, and DNS names only with DNS-name SAN entries.
  • Use secure-by-default TLS verification and avoid disabling certificate or hostname checks.
  • Limit trusted certificate authorities to those needed for the environment, and protect certificate issuance and trust-store management.
  • Where operationally appropriate, restrict client privileges and access to sensitive session data.

Defensive patterns focus on strict, standards-aligned server identity verification:

  • Require identity matches against appropriate SAN entries and avoid Common Name fallback when SAN is present or required.
  • Compare IP addresses only with IP-address SAN entries, and DNS names only with DNS-name SAN entries.
  • Use secure-by-default TLS verification and avoid disabling certificate or hostname checks.
  • Limit trusted certificate authorities to those needed for the environment, and protect certificate issuance and trust-store management.
  • Where operationally appropriate, restrict client privileges and access to sensitive session data.

How teams detect issues like this

Review certificate-verification code and configuration for fallback behavior, mismatched identity-type comparisons, or paths that accept a trusted chain without verifying the intended server name. Static analysis and code review can look for permissive hostname matching and disabled verification checks. Policy enforcement can require strict SAN-based identity validation and controlled trust stores; connection and certificate logs may also help identify unexpected certificate identities.

Review certificate-verification code and configuration for fallback behavior, mismatched identity-type comparisons, or paths that accept a trusted chain without verifying the intended server name. Static analysis and code review can look for permissive hostname matching and disabled verification checks. Policy enforcement can require strict SAN-based identity validation and controlled trust stores; connection and certificate logs may also help identify unexpected certificate identities.

Sources

SourceLink
github.comgithub.com/FreeRDP/FreeRDP/security/advisories/GHSA-jq25-3374-4262
vulncheck.comvulncheck.com/advisories/freerdp-before-3.32.2-certificate-identity-validation-bypass-via-tls-verify-certificate

Frequently asked

questions

It may be exploitable over a network if an attacker can intercept or redirect the client's connection and can present a certificate from a CA trusted by that client.

The attacker generally needs a network position that enables interception or redirection. They also need a suitably trusted certificate; the issue does not mean that any untrusted certificate will be accepted.

Enforce strict server identity checks against correctly typed SAN entries, without permissive Common Name fallback or IP-to-DNS matching.

Use secure-by-default TLS verification, review identity-matching logic and trust-store policy, and test certificate handling for mismatched names and address types.

It may be exploitable over a network if an attacker can intercept or redirect the client's connection and can present a certificate from a CA trusted by that client.

The attacker generally needs a network position that enables interception or redirection. They also need a suitably trusted certificate; the issue does not mean that any untrusted certificate will be accepted.

Enforce strict server identity checks against correctly typed SAN entries, without permissive Common Name fallback or IP-to-DNS matching.

Use secure-by-default TLS verification, review identity-matching logic and trust-store policy, and test certificate handling for mismatched names and address types.

Find out what's already
exploitable in your codebase.