CWE-477: Use of Obsolete Function
The code uses deprecated or obsolete functions, which suggests that the code has not been actively reviewed or maintained.
Last updated
Overview
As programming languages evolve, functions occasionally become obsolete due to:
Advances in the language
Improved understanding of how operations should be performed effectively and securely
Changes in the conventions that govern certain operations
Functions that are removed are usually replaced by newer counterparts that perform the same task in some different and hopefully improved way.
Real-world CVEs
16 recorded CVEs are caused by CWE-477 (Use of Obsolete Function). The highest-severity and most recent are shown first. None so far in 2026 (8 in 2025).
- CVE-2025-49217
Trend Micro Endpoint Encryption ValidateToken Deserialization of Untrusted Data Remote Code Execution Vulnerability
Critical · CVSS 9.8 · EPSS 81th2025-06-17 - CVE-2025-49216
Trend Micro Endpoint Encryption DbAppDomain Authentication Bypass Vulnerability
Critical · CVSS 9.8 · EPSS 45th2025-06-17 - CVE-2025-49213
Trend Micro Endpoint Encryption PolicyServerWindowsService Deserialization of Untrusted Data Remote Code Execution Vulnerability
Critical · CVSS 9.8 · EPSS 81th2025-06-17 - CVE-2025-49212
Trend Micro Endpoint Encryption DeserializeFromBase64String Deserialization of Untrusted Data Remote Code Execution Vulnerability
Critical · CVSS 9.8 · EPSS 81th2025-06-17 - CVE-2025-49220
Trend Micro Apex Central ConvertFromJson Deserialization of Untrusted Data Remote Code Execution Vulnerability
Critical · CVSS 9.8 · EPSS 90th2025-06-17 - CVE-2025-49219
Trend Micro Apex Central GetReportDetailView Deserialization of Untrusted Data Remote Code Execution Vulnerability
Critical · CVSS 9.8 · EPSS 90th2025-06-17 - CVE-2023-23451Critical · CVSS 9.8 · EPSS 55th2023-04-19
- CVE-2018-17890
Use of Obsolete Function in NUUO CMS
Critical · CVSS 9.8 · EPSS 89th2018-10-12 - CVE-2025-49214
Deserialization of Untrusted Data RCE
High · CVSS 8.8 · EPSS 81th2025-06-17 - CVE-2023-28829
Use of Obsolete Function Vulnerability in SIMATIC WinCC before V8
High · CVSS 8.8 · EPSS 25th2023-06-13 - CVE-2022-1384
Authorized users are allowed to install old plugin versions from the Marketplace
High · CVSS 8.8 · EPSS 45th2022-04-19 - CVE-2019-18251
OMRON CX-Supervisor Vulnerable Third-Party Component Remote Code Execution Vulnerability
High · CVSS 8.8 · EPSS 78th2019-11-25
Showing 12 of 16 recorded CWE-477 CVEs. Get an alert for each new one, with AI-written analysis and fixes.
Monitor these CVEsCommon consequences
What can happen when CWE-477 is exploited.
Quality Degradation
Affects: Other
How it happens
When it is introduced
Typically introduced during these phases of the software lifecycle.
How to prevent it
Practical mitigations for CWE-477, grouped by where in the lifecycle they apply.
Refer to the documentation for the obsolete function in order to determine why it is deprecated or obsolete and to learn about alternative ways to achieve the same functionality.
Consider seriously the security implications of using an obsolete function. Consider using alternate functions.
How to detect it
Automated Static Analysis - Binary or Bytecode
According to SOAR [2], the following detection techniques may be useful:
Highly cost effective:
- Binary / Bytecode Quality Analysis
Cost effective for partial coverage:
- Bytecode Weakness Analysis - including disassembler + source code weakness analysis
Effectiveness: High
Manual Static Analysis - Binary or Bytecode
According to SOAR [2], the following detection techniques may be useful:
Cost effective for partial coverage:
- Binary / Bytecode disassembler - then use manual analysis for vulnerabilities & anomalies
Effectiveness: SOAR Partial
Dynamic Analysis with Manual Results Interpretation
According to SOAR [2], the following detection techniques may be useful:
Highly cost effective:
- Debugger
Effectiveness: High
Manual Static Analysis - Source Code
According to SOAR [2], the following detection techniques may be useful:
Highly cost effective:
- Manual Source Code Review (not inspections)
Cost effective for partial coverage:
- Focused Manual Spotcheck - Focused manual analysis of source
Effectiveness: High
Automated Static Analysis - Source Code
According to SOAR [2], the following detection techniques may be useful:
Highly cost effective:
- Source Code Quality Analyzer
- Source code Weakness Analyzer
- Context-configured Source Code Weakness Analyzer
Effectiveness: High
Automated Static Analysis
According to SOAR [2], the following detection techniques may be useful:
Highly cost effective:
- Origin Analysis
Effectiveness: High
Architecture or Design Review
According to SOAR [2], the following detection techniques may be useful:
Highly cost effective:
- Formal Methods / Correct-By-Construction
- Inspection (IEEE 1028 standard) (can apply to requirements, design, source code, etc.)
Effectiveness: High
Code examples
MITRE examples of the weakness in code.
The following code uses the deprecated function getpw() to verify that a plaintext password matches a user's encrypted password. If the password is valid, the function sets result to 1; otherwise it is set to 0.
Vulnerable example
...
getpw(uid, pwdline);
for (i=0; i<3; i++){
cryptpw=strtok(pwdline, ":");
pwdline=0;
}
result = strcmp(crypt(plainpw,cryptpw), cryptpw) == 0;
...Although the code often behaves correctly, using the getpw() function can be problematic from a security standpoint, because it can overflow the buffer passed to its second parameter. Because of this vulnerability, getpw() has been supplanted by getpwuid(), which performs the same lookup as getpw() but returns a pointer to a statically-allocated structure to mitigate the risk. Not all functions are deprecated or replaced because they pose a security risk. However, the presence of an obsolete function often indicates that the surrounding code has been neglected and may be in a state of disrepair. Software security has not been a priority, or even a consideration, for very long. If the program uses deprecated or obsolete functions, it raises the probability that there are security problems lurking nearby.
In the following code, the programmer assumes that the system always has a property named "cmd" defined. If an attacker can control the program's environment so that "cmd" is not defined, the program throws a null pointer exception when it attempts to call the "Trim()" method.
Vulnerable example
String cmd = null;
...
cmd = Environment.GetEnvironmentVariable("cmd");
cmd = cmd.Trim();The following code constructs a string object from an array of bytes and a value that specifies the top 8 bits of each 16-bit Unicode character.
Vulnerable example
...
String name = new String(nameBytes, highByte);
...In this example, the constructor may not correctly convert bytes to characters depending upon which charset is used to encode the string represented by nameBytes. Due to the evolution of the charsets used to encode strings, this constructor was deprecated and replaced by a constructor that accepts as one of its parameters the name of the charset used to encode the bytes for conversion.
Terminology & mappings
Mapped taxonomies
- 7 Pernicious Kingdoms: Obsolete
- Software Fault Patterns: Use of an improper API (SFP3)
- SEI CERT Perl Coding Standard: Do not import deprecated modules (DCL30-PL) — CWE More Specific fit
- SEI CERT Perl Coding Standard: Do not use deprecated or obsolete functions or modules (EXP30-PL) — CWE More Specific fit
Frequently asked questions
Common questions about CWE-477.
- What is CWE-477?
- The code uses deprecated or obsolete functions, which suggests that the code has not been actively reviewed or maintained.
- What CVEs are caused by CWE-477?
- 16 recorded CVEs are attributed to CWE-477, including CVE-2025-49217, CVE-2025-49216 and CVE-2025-49213.
- How do you prevent CWE-477?
- Refer to the documentation for the obsolete function in order to determine why it is deprecated or obsolete and to learn about alternative ways to achieve the same functionality.
- How is CWE-477 detected?
- Automated Static Analysis - Binary or Bytecode: According to SOAR, the following detection techniques may be useful:
- What are the consequences of CWE-477?
- Exploiting CWE-477 can lead to: Quality Degradation.
- Is CWE-477 actively exploited?
- 16 recorded CVEs are caused by CWE-477; none are currently in CISA's KEV catalog of actively exploited flaws.
Sources
References
- MITRE CWE definition (CWE-477) (opens in a new tab)
- CWE-477 vulnerabilities on NVD (opens in a new tab)
- Learn: What is a CWE?
Weakness data is sourced from the MITRE CWE catalog (v4.21). CVE associations are aggregated and kept current by RadicalNotion.AI.
Track CWE-477 CVEs
Get an alert when a new CWE-477 CVE affects your products, with AI-written analysis and remediation steps.