CWEweakness

CWE-176 Improper Handling of Unicode Encoding

Official page ↗
Abstraction
Variant
Structure
Simple
Status
Draft
Languages
Not Language-Specific, Python
CWE version
5.0

Description

The product does not properly handle when an input contains Unicode encoding.

Common consequences

• Integrity: Unexpected State

Potential mitigations

• [Architecture and Design] Avoid making decisions based on names of resources (e.g. files) if those resources can have alternate names. • [Implementation] Assume all input is malicious. Use an "accept known good" input validation strategy, i.e., use a list of acceptable inputs that strictly conform to specifications. Reject any input that does not strictly conform to specifications, or transform it into something that does. When performing input validation, consider all potentially relevant properties, including length, type of input, the full range of acceptable values, missing or extra inputs, syntax, consistency across related fields, and conformance to business rules. As an example of business rule logic, "boat" may be syntactically valid because it only contains alphanumeric characters, but it is not valid if the input is only expected to contain colors such as "red" or "blue." Do not rely exclusively on looking for malicious or malformed inputs. This is likely to miss at least one undesirable input, especially if the code's environment changes. This can give attackers enough room to bypass the intended validation. However, denylists can be useful for detecting potential attacks or determining which inputs are so malformed that they should be rejected outright. • [Implementation] Inputs should be decoded and canonicalized to the application's current internal representation before being validated (CWE-180). Make sure that the application does not decode the same input twice (CWE-174). Such errors could be used to bypass allowlist validation schemes by introducing dangerous inputs after they have been checked.

Detection methods

• 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.)

Observed examples

• CVE-2000-0884: Server allows remote attackers to read documents outside of the web root, and possibly execute arbitrary commands, via malformed URLs that contain Unicode encoded characters. • CVE-2001-0709: Server allows a remote attacker to obtain source code of ASP files via a URL encoded with Unicode. • CVE-2001-0669: Overlaps interaction error.

Related

Attack pattern · CAPEC (1)

  • CAPEC-71 Using Unicode Encoding to Bypass Validation Logic attack pattern

Observed example · CVE (3)

  • CVE-2001-0669 Various Intrusion Detection Systems (IDS) including (1) Cisco Secure Intrusion Detection System, (2) Cisco Catalyst 6000 Intrusion… vulnerability
  • CVE-2001-0709 Microsoft IIS 4.0 and before, when installed on a FAT partition, allows a remote attacker to obtain source code of ASP files via a URL… vulnerability
  • CVE-2000-0884 IIS 4.0 and 5.0 allows remote attackers to read documents outside of the web root, and possibly execute arbitrary commands, via malformed… vulnerability

Child of · CWE (1)

  • CWE-172 Improper Encoding or Decoding of Data weakness

Referenced by CAPEC · weakness (1)

  • CAPEC-71 Using Unicode Encoding to Bypass Validation Logic attack pattern

Referenced by CVE · weakness (43)

  • CVE-2026-62374 SD JWT JS is a JavaScript implementation of the Selective Disclosure JWT (SD-JWT) specification. vulnerability
  • CVE-2026-116542 Netty netty-tcnative before 2.0.84.Final contains an SNI hostname spoofing vulnerability that allows remote unauthenticated clients to… vulnerability
  • CVE-2026-114114 Vyper 0.1.0b1 before 0.1.0b12, 0.1.0b14, and 0.4.1 through 0.5.0b1 mix character-based line offsets with Python's UTF-8 byte col_offset… vulnerability
  • CVE-2026-110674 Cpanel::JSON::XS versions from 4.33 before 4.80 for Perl miss duplicate non-ASCII bare keys, allowing type confusion under… vulnerability
  • CVE-2026-110687 Cpanel::JSON::XS versions from 4.43 before 4.80 for Perl misorder byte-string keys during canonical encoding in utf16_cmp. vulnerability
  • CVE-2026-89074 Improper handling of unicode encoding vulnerability in Progress MOVEit Transfer. vulnerability
  • CVE-2026-105241 Improper Handling of Unicode Encoding vulnerability in the SmtpPickupDirAppender of Apache log4net. vulnerability
  • CVE-2026-19954 Net::Whois::Raw versions before 2.99044 for Perl ship a pwhois command-line tool that queries WHOIS for the wrong domain for unicode domain… vulnerability
  • CVE-2026-86105 An improper authorization vulnerability in Fireware OS's Access Portal reverse proxy allows an authenticated, low-privileged Access Portal… vulnerability
  • CVE-2026-93990 Expat before 2.8.5 fails to validate that a high surrogate in UTF-16 input is followed by a low surrogate, allowing malformed UTF-16… vulnerability
  • CVE-2026-93751 uri-js through 4.4.1 contains an improper UTF-8 decoding vulnerability in pctDecChars() that decodes invalid and overlong percent-encoded… vulnerability
  • CVE-2026-81869 OpenTelemetry-Go is the Go implementation of OpenTelemetry. vulnerability
  • CVE-2026-14978 HashiCorp go-slug 0.4.0 through 0.18.2 could allow a local attacker to bypass .terraformignore exclusions and cause sensitive files to be… vulnerability
  • CVE-2026-59890 setuptools is a package that allows users to download, build, install, upgrade, and uninstall Python packages. vulnerability
  • CVE-2026-48618 A flaw in Node.js TLS hostname handling can cause Node.js unicode dot separator handling can lead to tls wildcard-depth authentication… vulnerability
  • CVE-2026-45135 Caddy is an extensible server platform that uses TLS by default. vulnerability
  • CVE-2026-49401 Deno is a JavaScript, TypeScript, and WebAssembly runtime. vulnerability
  • CVE-2026-45062 FrankenPHP is a modern application server for PHP. vulnerability
  • CVE-2025-71316 SQLite 'sqldiff.exe' does not securely handle the way the Microsoft Windows C runtime converts Unicode characters to ANSI codepages. vulnerability
  • CVE-2026-44288 protobufjs compiles protobuf definitions into JavaScript (JS) functions. vulnerability
  • CVE-2026-7040 Text::Minify::XS versions from 0.3.0 before 0.7.8 for Perl have a heap overflow when processing some malformed UTF-8 characters. vulnerability
  • CVE-2026-35346 The comm utility in uutils coreutils silently corrupts data by performing lossy UTF-8 conversion on all output lines. vulnerability
  • CVE-2026-35373 A logic error in the ln utility of uutils coreutils causes the program to reject source paths containing non-UTF-8 filename bytes when… vulnerability
  • CVE-2026-35375 A logic error in the split utility of uutils coreutils causes the corruption of output filenames when provided with non-UTF-8 prefix or… vulnerability
  • CVE-2026-20202 In Splunk Enterprise versions below 10.2.2, 10.0.5, 9.4.10, and 9.3.11, and Splunk Cloud Platform versions below 10.4.2603.0, 10.3.2512.6,… vulnerability
  • CVE-2026-4114 Improper handling of Unicode encoding in SonicWall SMA1000 series appliances allows a remote authenticated SSLVPN admin to bypass AMC TOTP… vulnerability
  • CVE-2026-4116 Improper handling of Unicode encoding in SonicWall SMA1000 series appliances allows a remote authenticated SSLVPN user to bypass… vulnerability
  • CVE-2006-10002 XML::Parser versions through 2.45 for Perl could overflow the pre-allocated buffer size cause a heap corruption (double free or corruption)… vulnerability
  • CVE-2026-25480 Litestar is an Asynchronous Server Gateway Interface (ASGI) framework. vulnerability
  • CVE-2026-23950 node-tar,a Tar for Node.js, has a race condition vulnerability in versions up to and including 7.5.3. vulnerability
Show all 43 ›