CVE-2024-12224
None`idna` accepts Punycode labels that do not produce any non-ASCII when decoded
CVSS
—
EPSS
0.2%
Published
Dec 9, 2024
CISA due date
—
Cloudanix analysis
A flaw in domain-name handling code can let attackers make different web addresses appear identical to certain programs, potentially letting them reach resources they should not access.
- Exploitation
- Remote Unauthenticated
- Attacker needs
- None
- Complexity
- Moderate
- Impact
- Privilege Gain
- Component
- Library
- Class
- Improper Input Validation
- Remediation
- Upgrade
- Effort
- Low
- Patch risk
- Low
What it actually does
The idna library accepts Punycode labels that produce no non-ASCII output, causing distinct ASCII or root labels such as example.org and xn--example-.org to compare as equal after processing.
Why it matters to the business
Applications that rely on hostname comparison for access decisions may grant unauthorized privileges, increasing risk of security bypass in environments using the vulnerable library.
How an attack unfolds
An attacker registers a DNS name and obtains a TLS certificate for an xn--masked label that the library maps to a target domain, then supplies the name in a context where the application performs a privilege check based on the incorrectly equal comparison.
How to fix it
Upgrade the idna package to version 0.6.0 or newer. On SUSE Linux Enterprise Live Patching 12 SP5 systems apply kgraft-patch-SLE12-SP5_Update_51 version 7-2.1 or later.
How to confirm the fix worked
Confirm the installed idna version is newer than 0.5.0, then test that example.org and xn--example-.org are no longer treated as equal and that example.org.xn-- and example.org. remain distinct.
Typical attack path
- Locate an application that uses idna for hostname comparison in a privilege decision
- Craft a Punycode label that the library maps to the target domain
- Register the malicious domain and obtain a matching TLS certificate
- Cause the application to perform the flawed comparison during an access check
- Obtain elevated access or bypass intended restrictions
How to detect it
Inspect application logs for hostname comparisons involving xn-- prefixes that unexpectedly match target domains, and review DNS or certificate logs for registrations of such labels.
What your security team should do
- Update idna to a fixed version across all affected systems immediately
- Audit code paths that compare hostnames for authorization decisions
- Review dependency manifests for any remaining pinned versions 0.5.0 or earlier
The record
`idna` 0.5.0 and earlier accepts Punycode labels that do not produce any non-ASCII output, which means that either ASCII labels or the empty root label can be masked such that they appear unequal without IDNA processing or when processed with a different implementation and equal when processed with `idna` 0.5.0 or earlier. Concretely, `example.org` and `xn--example-.org` become equal after processing by `idna` 0.5.0 or earlier. Also, `example.org.xn--` and `example.org.` become equal after processing by `idna` 0.5.0 or earlier. In applications using `idna` (but not in `idna` itself) this may be able to lead to privilege escalation when host name comparison is part of a privilege check and the behavior is combined with a client that resolves domains with such labels instead of treating them as errors that preclude DNS resolution / URL fetching and with the attacker managing to introduce a DNS entry (and TLS certificate) for an `xn--`-masked name that turns into the name of the target when processed by `idna` 0.5.0 or earlier.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| crates.io | idna | 0 | 1.0.0 |
| crates.io | idna | 0.0.0-0 | 1.0.0 |
| Chainguard | atuin | 0 | 18.4.0-r0 |
| Chainguard | bat | 0 | 0.24.0-r5 |
| Chainguard | bat-doc | 0 | 0.24.0-r5 |
| Chainguard | berg | 0 | 0.4.7-r0 |
| Chainguard | buck2 | 0 | 20250102-r3 |
| Chainguard | cargo-audit | 0 | 0.21.0-r3 |
| Chainguard | cargo-audit-doc | 0 | 0.21.0-r3 |
| Chainguard | convco | 0 | 0.6.2-r0 |
| Chainguard | deno | 0 | 2.1.3-r0 |
| Chainguard | fnm | 0 | 1.38.1-r4 |
| Chainguard | geckodriver | 0 | 0.35.0-r1 |
| Chainguard | helix | 0 | 25.01-r0 |
| Chainguard | kdash | 0 | 0.6.1-r4 |
| Chainguard | libwasmtime | 0 | 28.0.0-r0 |
| Chainguard | linkerd2 | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-cli | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-controller | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-controller-compat | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-debug | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-metrics-api | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-metrics-api-compat | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-policy-controller | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-policy-controller-compat | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-proxy | 0 | 2.272.0-r0 |
| Chainguard | linkerd2-proxy-identity | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-tap | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-tap-compat | 0 | 24.11.8-r1 |
| Chainguard | linkerd2-web | 0 | 24.11.8-r1 |
| Chainguard | lychee | 0 | 0.23.0-r0 |
| Chainguard | netavark | 0 | 1.17.0-r0 |
| Chainguard | netavark-doc | 0 | 1.16.1-r0 |
| Chainguard | nushell | 0 | 0.101.0-r0 |
| Chainguard | nushell-plugins | 0 | 0.101.0-r0 |
| Chainguard | oranda | 0 | 0.6.5-r2 |
| Chainguard | parseable | 0 | 2.5.5-r0 |
| Chainguard | pixi | 0 | 0.39.4-r0 |
| Chainguard | pixi-compat | 0 | 0.39.4-r0 |
| Chainguard | qdrant | 0 | 1.15.5-r0 |
| Chainguard | qdrant-oci-compat | 0 | 1.15.5-r0 |
| Chainguard | qdrant-oci-entrypoint | 0 | 1.15.5-r0 |
| Chainguard | rust-analyzer | 0 | 20251103-r0 |
| Chainguard | rustup | 0 | 1.27.1-r4 |
| Chainguard | rye | 0 | 0.43.0-r1 |
| Chainguard | samply | 0 | 0.13.1-r5 |
| Chainguard | sccache | 0 | 0.9.0-r1 |
| Chainguard | sdp-device-id-service | 0 | 1.3.6-r1 |
| Chainguard | sdp-identity-service | 0 | 1.3.6-r1 |
| Chainguard | sdp-k8s-injector | 0 | 1.3.6-r1 |
| Chainguard | shadowsocks-rust | 0 | 1.21.2-r3 |
| Chainguard | shadowsocks-rust-sslocal | 0 | 1.21.2-r3 |
| Chainguard | shadowsocks-rust-ssmanager | 0 | 1.21.2-r3 |
| Chainguard | shadowsocks-rust-ssserver | 0 | 1.21.2-r3 |
| Chainguard | shadowsocks-rust-ssservice | 0 | 1.21.2-r3 |
| Chainguard | shadowsocks-rust-ssurl | 0 | 1.21.2-r3 |
| Chainguard | starship | 0 | 1.21.1-r1 |
| Chainguard | tealdeer | 0 | 1.8.0-r0 |
| Chainguard | wadm | 0 | 0.19.0-r0 |
| Chainguard | wash | 0 | 0.38.0-r0 |
| Chainguard | wasmcloud | 0 | 1.5.0-r0 |
| Chainguard | wasmtime | 0 | 28.0.0-r0 |
| Chainguard | wasmtime-dev | 0 | 28.0.0-r0 |
| Chainguard | wizer | 0 | 7.0.5-r4 |
| Chainguard | xh | 0 | 0.24.0-r0 |
| Chainguard | zellij | 0 | 0.41.2-r2 |
| Chainguard | zellij-bash-completion | 0 | 0.41.2-r2 |
| Chainguard | zellij-fish-completion | 0 | 0.41.2-r2 |
| Chainguard | zellij-zsh-completion | 0 | 0.41.2-r2 |
| Chainguard | ztunnel-1.24 | 0 | 1.24.2-r1 |
| Chainguard | ztunnel-1.24-compat | 0 | 1.24.2-r1 |
| Chainguard | ztunnel-fips-1.24 | 0 | 1.24.2-r2 |
| Chainguard | ztunnel-fips-1.24-compat | 0 | 1.24.2-r2 |
| Debian:11 | rust-idna | 0 | No fix |
| Debian:12 | rust-idna | 0 | No fix |
| Debian:13 | rust-idna | 0 | 1.0.3-2 |
| SUSE:Linux Enterprise Micro 5.2 | afterburn | 0 | 5.9.0.git21.a73f509-150300.3.5.1 |
| SUSE:Linux Enterprise Micro 5.3 | afterburn | 0 | 5.9.0.git21.a73f509-150400.3.3.1 |
| SUSE:Linux Enterprise Micro 5.4 | afterburn | 0 | 5.9.0.git21.a73f509-150400.3.3.1 |
| SUSE:Linux Enterprise Micro 5.5 | afterburn | 0 | 5.9.0.git21.a73f509-150500.3.3.1 |
| SUSE:Linux Enterprise Module for Basesystem 15 SP6 | rav1e | 0 | 0.6.6-150600.3.3.1 |
| SUSE:Linux Enterprise Module for Basesystem 15 SP7 | librsvg | 0 | 2.57.4-150600.3.3.1 |
| SUSE:Linux Enterprise Module for Basesystem 15 SP7 | rav1e | 0 | 0.6.6-150600.3.3.1 |
| SUSE:Linux Enterprise Module for Desktop Applications 15 SP7 | librsvg | 0 | 2.57.4-150600.3.3.1 |
| SUSE:Linux Enterprise Module for Development Tools 15 SP6 | rustup | 0 | 1.26.0~0-150600.10.7.1 |
| SUSE:Linux Enterprise Module for Development Tools 15 SP6 | sccache | 0 | 0.4.2~4-150600.10.3.1 |
| SUSE:Linux Enterprise Module for Development Tools 15 SP7 | rustup | 0 | 1.26.0~0-150600.10.7.1 |
| SUSE:Linux Enterprise Module for Development Tools 15 SP7 | sccache | 0 | 0.4.2~4-150600.10.3.1 |
| SUSE:Linux Enterprise Module for Public Cloud 15 SP4 | aws-nitro-enclaves-cli | 0 | 1.4.2~git0.6e8512e-150400.3.9.1 |
| SUSE:Linux Enterprise Module for Public Cloud 15 SP5 | aws-nitro-enclaves-cli | 0 | 1.4.2~git0.6e8512e-150400.3.9.1 |
| SUSE:Linux Enterprise Module for Public Cloud 15 SP6 | aws-nitro-enclaves-cli | 0 | 1.4.2~git0.6e8512e-150600.10.6.1 |
| SUSE:Linux Enterprise Module for Public Cloud 15 SP7 | aws-nitro-enclaves-cli | 0 | 1.4.2~git0.6e8512e-150600.10.6.1 |
| SUSE:Linux Enterprise Module for Server Applications 15 SP6 | sevctl | 0 | 0.4.3-150600.4.3.1 |
| SUSE:Linux Enterprise Module for Server Applications 15 SP6 | snpguest | 0 | 0.3.2-150600.3.6.1 |
| SUSE:Linux Enterprise Module for Server Applications 15 SP7 | snpguest | 0 | 0.10.0-150700.3.3.1 |
| Ubuntu:20.04:LTS | rust-idna | 0 | No fix |
| Ubuntu:22.04:LTS | rust-idna | 0 | No fix |
| Ubuntu:24.04:LTS | rust-idna | 0 | No fix |
| Ubuntu:24.10 | rust-idna | 0 | No fix |
| Ubuntu:25.04 | rust-idna | 0 | No fix |
| Ubuntu:25.10 | rust-idna | 0 | No fix |
| Ubuntu:Pro:20.04:LTS | rust-idna | 0 | No fix |
| Wolfi | atuin | 0 | 18.4.0-r0 |
| Wolfi | bat | 0 | 0.24.0-r5 |
| Wolfi | bat-doc | 0 | 0.24.0-r5 |
| Wolfi | berg | 0 | 0.4.7-r0 |
| Wolfi | buck2 | 0 | 20250102-r3 |
| Wolfi | cargo-audit | 0 | 0.21.0-r3 |
| Wolfi | cargo-audit-doc | 0 | 0.21.0-r3 |
| Wolfi | convco | 0 | 0.6.2-r0 |
| Wolfi | deno | 0 | 2.1.3-r0 |
| Wolfi | geckodriver | 0 | 0.35.0-r1 |
| Wolfi | helix | 0 | 25.01-r0 |
| Wolfi | kdash | 0 | 0.6.1-r4 |
| Wolfi | libwasmtime | 0 | 28.0.0-r0 |
| Wolfi | linkerd2 | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-cli | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-controller | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-controller-compat | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-debug | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-metrics-api | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-metrics-api-compat | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-policy-controller | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-policy-controller-compat | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-proxy | 0 | 2.272.0-r0 |
| Wolfi | linkerd2-proxy-identity | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-tap | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-tap-compat | 0 | 24.11.8-r1 |
| Wolfi | linkerd2-web | 0 | 24.11.8-r1 |
| Wolfi | lychee | 0 | 0.23.0-r0 |
| Wolfi | netavark | 0 | 1.17.0-r0 |
| Wolfi | netavark-doc | 0 | 1.16.1-r0 |
| Wolfi | nushell | 0 | 0.101.0-r0 |
| Wolfi | nushell-plugins | 0 | 0.101.0-r0 |
| Wolfi | oranda | 0 | 0.6.5-r2 |
| Wolfi | parseable | 0 | 2.5.5-r0 |
| Wolfi | pixi | 0 | 0.39.4-r0 |
| Wolfi | pixi-compat | 0 | 0.39.4-r0 |
| Wolfi | qdrant | 0 | 1.15.5-r0 |
| Wolfi | qdrant-oci-compat | 0 | 1.15.5-r0 |
| Wolfi | qdrant-oci-entrypoint | 0 | 1.15.5-r0 |
| Wolfi | rust-analyzer | 0 | 20251103-r0 |
| Wolfi | rustup | 0 | 1.27.1-r4 |
| Wolfi | rye | 0 | 0.43.0-r1 |
| Wolfi | samply | 0 | 0.13.1-r5 |
| Wolfi | sccache | 0 | 0.9.0-r1 |
| Wolfi | sdp-device-id-service | 0 | 1.3.6-r1 |
| Wolfi | sdp-identity-service | 0 | 1.3.6-r1 |
| Wolfi | sdp-k8s-injector | 0 | 1.3.6-r1 |
| Wolfi | shadowsocks-rust | 0 | 1.21.2-r3 |
| Wolfi | shadowsocks-rust-sslocal | 0 | 1.21.2-r3 |
| Wolfi | shadowsocks-rust-ssmanager | 0 | 1.21.2-r3 |
| Wolfi | shadowsocks-rust-ssserver | 0 | 1.21.2-r3 |
| Wolfi | shadowsocks-rust-ssservice | 0 | 1.21.2-r3 |
| Wolfi | shadowsocks-rust-ssurl | 0 | 1.21.2-r3 |
| Wolfi | starship | 0 | 1.21.1-r1 |
| Wolfi | tealdeer | 0 | 1.8.0-r0 |
| Wolfi | wadm | 0 | 0.19.0-r0 |
| Wolfi | wash | 0 | 0.38.0-r0 |
| Wolfi | wasmcloud | 0 | 1.5.0-r0 |
| Wolfi | wasmtime | 0 | 28.0.0-r0 |
| Wolfi | wasmtime-dev | 0 | 28.0.0-r0 |
| Wolfi | wizer | 0 | 7.0.5-r4 |
| Wolfi | xh | 0 | 0.24.0-r0 |
| Wolfi | zellij | 0 | 0.41.2-r2 |
| Wolfi | zellij-bash-completion | 0 | 0.41.2-r2 |
| Wolfi | zellij-fish-completion | 0 | 0.41.2-r2 |
| Wolfi | zellij-zsh-completion | 0 | 0.41.2-r2 |
| Wolfi | ztunnel-1.24 | 0 | 1.24.2-r1 |
| Wolfi | ztunnel-1.24-compat | 0 | 1.24.2-r1 |
| openSUSE:Leap 15.6 | aws-nitro-enclaves-cli | 0 | 1.4.2~git0.6e8512e-150600.10.6.1 |
| openSUSE:Leap 15.6 | librsvg | 0 | 2.57.4-150600.3.3.1 |
| openSUSE:Leap 15.6 | rav1e | 0 | 0.6.6-150600.3.3.1 |
| openSUSE:Leap 15.6 | rustup | 0 | 1.26.0~0-150600.10.7.1 |
| openSUSE:Leap 15.6 | sccache | 0 | 0.4.2~4-150600.10.3.1 |
| openSUSE:Leap 15.6 | sevctl | 0 | 0.4.3-150600.4.3.1 |
| openSUSE:Leap 15.6 | snpguest | 0 | 0.3.2-150600.3.6.1 |
| openSUSE:Leap 16.0 | cargo-c | 0 | 0.10.15-160000.1.1 |
| openSUSE:Leap 16.0 | librsvg | 0 | 2.60.2-160000.1.1 |
| openSUSE:Tumbleweed | afterburn | 0 | 5.9.0.git21.a73f509-2.1 |
| openSUSE:Tumbleweed | cargo-audit | 0 | 0.21.2~git0.18e58c2-2.1 |
| openSUSE:Tumbleweed | cargo-c | 0 | 0.10.3~git0.ee7d7ef-4.1 |
| openSUSE:Tumbleweed | python-nh3 | 0 | 0.2.17-2.1 |
| openSUSE:Tumbleweed | python-selenium | 0 | 4.25.0-5.1 |
| openSUSE:Tumbleweed | rust-keylime | 0 | 0.2.7+70-2.1 |
| openSUSE:Tumbleweed | rustup | 0 | 1.28.2~0-1.1 |
| openSUSE:Tumbleweed | sccache | 0 | 0.12.0~1-1.1 |
Related vulnerabilities
- CVE-2026-25727 time provides date and time handling in Rust. Also affects atuin
- CVE-2026-25541 Bytes is a utility library for working with bytes. Also affects atuin
- CVE-2026-21895 The `rsa` crate is an RSA implementation written in rust. Also affects atuin
- GHSA-9c48-w39g-hm26 rsa crate has potential panic on a prime being equal to 1 Also affects atuin
- CVE-2024-47609 Tonic is a native gRPC client & server implementation with async/await support. Also affects atuin
- CVE-2023-49092 RustCrypto/RSA is a portable RSA implementation in pure Rust. Also affects atuin
- CVE-2024-43806 Rustix is a set of safe Rust bindings to POSIX-ish APIs. Also affects bat
- CVE-2026-31812 Quinn is a pure-Rust, async-compatible implementation of the IETF QUIC transport protocol. Also affects berg