CWE-253

Incorrect Check of Function Return Value

Medium

Description

The product incorrectly checks a return value from a function, which prevents it from detecting errors or exceptional conditions.

Potential Impact

How to Fix

Architecture and Design

Use a language or compiler that uses exceptions and requires the catching of those exceptions.

Implementation

Properly check all functions which return a value.

Implementation

When designing any function make sure you return a value or throw an exception in case of an error.

Detection Methods

Related Weaknesses

References

View on MITRE CWE Database →

Need Help Fixing This Vulnerability?

Our security experts can help you identify and remediate CWE-253 vulnerabilities in your codebase.

Get Security Assessment