CWE-479

Signal Handler Use of a Non-reentrant Function

High

Description

The product defines a signal handler that calls a non-reentrant function.

Potential Impact

How to Fix

Requirements

Require languages or libraries that provide reentrant functionality, or otherwise make it easier to avoid this weakness.

Architecture and Design

Design signal handlers to only set flags rather than perform complex functionality.

Implementation

Ensure that non-reentrant functions are not found in signal handlers.

Implementation

Use sanity checks to reduce the timing window for exploitation of race conditions. This is only a partial solution, since many attacks might fail, but other attacks still might work within the narrower window, even accidentally.

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-479 vulnerabilities in your codebase.

Get Security Assessment