---
title: "CWE-589: Call to Non-ubiquitous API"
url: https://radicalnotion.ai/cwe/cwe-589
type: cwe
description: "The product uses an API function that does not exist on all versions of the target platform."
updated: 2026-11-10
source: RadicalNotion.AI
license: CC BY-NC 4.0 (https://creativecommons.org/licenses/by-nc/4.0/)
---

# CWE-589: Call to Non-ubiquitous API

- **Abstraction:** Variant
- **Structure:** Simple
- **Status:** Incomplete
- **CVEs with this as primary weakness:** 0
- **Of those, in CISA KEV:** 0
- **New in 2026:** 0
- **CWE catalog version:** 4.21

## Description

The product uses an API function that does not exist on all versions of the target platform.

## Modes of introduction

| Phase | Note |
| --- | --- |
| Architecture and Design | - |
| Implementation | - |

## Common consequences

| Scope | Impact | Note |
| --- | --- | --- |
| Other | Quality Degradation, Reduce Maintainability | Some functions that offer security features supported by the OS are not available on all versions of the OS in common use. Likewise, functions are often deprecated or made obsolete for security reasons and should not be used. This could cause portability problems or inconsistencies that allow denial of service or other consequences. |

## Potential mitigations

### Implementation

Always test your code on any platform on which it is targeted to run on.

### Testing

Test your code on the newest and oldest platform on which it is targeted to run on.

### Testing

Develop a system to test for API functions that are not portable.

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

Effectiveness: High

## Related attack patterns (CAPEC)

- [CAPEC-96](https://radicalnotion.ai/capec/capec-96): Block Access to Libraries

## Related weaknesses

| Relationship | CWE | Name |
| --- | --- | --- |
| Parent | [CWE-474](https://radicalnotion.ai/cwe/cwe-474) | Use of Function with Inconsistent Implementations |

## Taxonomy mappings

| Taxonomy | Entry | Id | Fit |
| --- | --- | --- | --- |
| The CERT Oracle Secure Coding Standard for Java (2011) | Do not use deprecated or obsolete classes or methods | MET02-J | - |
| The CERT Oracle Secure Coding Standard for Java (2011) | Maintain serialization compatibility during class evolution | SER00-J | - |
| Software Fault Patterns | Use of an improper API | SFP3 | - |

## Frequently asked questions

### What is CWE-589?

The product uses an API function that does not exist on all versions of the target platform.

### How do you prevent CWE-589?

Always test your code on any platform on which it is targeted to run on.

### How is CWE-589 detected?

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

### What are the consequences of CWE-589?

Exploiting CWE-589 can lead to: Quality Degradation, Reduce Maintainability.

Primary source: [MITRE CWE](https://cwe.mitre.org/data/definitions/589.html)

---

Source: [RadicalNotion.AI](https://radicalnotion.ai/cwe/cwe-589). Licensed CC BY-NC 4.0; attribute RadicalNotion.AI and link the source page when you reuse this data.
