# CVE-2026-63374: AnyIO TLSStream IDNA 2003 host name encoding certificate spoofing

Source: https://junglewise.ai/threats/cve-2026-63374-anyio-tlsstream-idna-2003-host-name-encoding-certificate-spoofing  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-09-22. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

CVE-2026-63374 · Severity: critical · CVSS 4 · Published 2026-09-22

AnyIO is a Python library for asynchronous network I/O. When applications connect to internationalized domain names (non-ASCII characters), AnyIO improperly validates TLS certificates using outdated IDNA 2003 encoding instead of modern standards. An attacker who redirects network traffic can present a valid certificate for the IDNA-encoded domain name, causing the client to accept a spoofed connection. This allows attackers to intercept encrypted communication and steal sensitive data like credentials or session tokens.

Technologies: [anyio (PyPI)](https://junglewise.ai/threats/technologies/anyio). Vendors: [PyPI](https://junglewise.ai/threats/vendors/pypi).

## Quick answers

**Is CVE-2026-63374 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-63374 being exploited in the wild.

**How severe is CVE-2026-63374?** Critical severity, with a CVSS score of 4, published 22 September 2026.

**Which products and versions are affected?** anyio (PyPI) < 4.14.2, ECOSYSTEM:introduced=0,fixed=4.14.2.

**Is there a fix for CVE-2026-63374?** Yes. anyio (PyPI): upgrade to 4.14.2 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-63374 attacked?** It is attacked over the network.

**Am I affected by CVE-2026-63374?** Check whether you run anyio (PyPI) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- anyio (PyPI): upgrade to 4.14.2 or later

  ```sh
  pip install "anyio>=4.14.2"
  ```


## Technical details

The vulnerability exists in AnyIO's `connect_tcp()` and `TLSStream.wrap()` methods, which use IDNA 2003 encoding for internationalized domain names during TLS certificate validation. This creates a mismatch between the hostname the user intends to connect to and the hostname validated against the certificate. An attacker who achieves network-level hijacking (e.g., via DNS spoofing, ARP poisoning, or BGP hijacking) can obtain a legitimate TLS certificate for the IDNA 2003-encoded version of the domain and present it during the handshake. The client will validate the certificate as correct due to the encoding mismatch, allowing the attacker to perform man-in-the-middle attacks. The attack requires network-level access but no privileges or user interaction. The vulnerability affects versions prior to 4.14.2, which implements the fix.

## Affected products

- agronholm AnyIO < 4.14.2

## Identifiers

- CVE-2026-63374
- GHSA-82r6-8w77-94w6
- PYSEC-2026-4025

## Timeline

- 2026-07-07: disclosed
- 2026-09-18: advisory
- 2026-09-18: patched: patched in v4.14.2

## References

- [https://github.com/agronholm/anyio/security/advisories/GHSA-82r6-8w77-94w6](https://github.com/agronholm/anyio/security/advisories/GHSA-82r6-8w77-94w6)

## Related threats

- [AnyIO process-pool workers indefinite blocking on undrained stderr](https://junglewise.ai/threats/cve-2026-64847-anyio-process-pool-workers-indefinite-blocking-on-undrained)
- [AnyIO run_process/open_process privilege dropping bug with extra_groups](https://junglewise.ai/threats/cve-2026-63349-anyio-run-process-open-process-privilege-dropping-bug-with-extra)
