search menu icon-carat-right cmu-wordmark

CERT Coordination Center

Henry Spencer regular expressions (regex) library contains a heap overflow vulnerability

Vulnerability Note VU#695940

Original Release Date: 2015-02-13 | Last Revised: 2015-02-27

Overview

A regular expressions C library originally written by Henry Spencer is vulnerable to a heap overflow in some circumstances.

Description

CWE-122: Heap-based Buffer Overflow

From the researcher, the variable len that holds the length of a regular expression string is "enlarged to such an extent that, in the process of enlarging (multiplication and addition), causes the 32 bit register/variable to overflow." It may be possible for an attacker to use this overflow to change data in memory.

More details are given on the researcher's blog.

The nature of the overflow suggests that only 32-bit operating systems are affected; it is highly unlikely that 64-bit operating systems would allow such an overflow.

Impact

The complete impact of this vulnerability is not yet known. Since the library is utilized in different ways, the impact is likely to vary depending on vendor. In worst case, a malicious actor may be able to execute arbitrary code.

Solution

Apply an update

Check with your vendor to see if an update is available to address this vulnerability. See the Vendor List below for more information.

Vendor Information

695940
 

View all 77 vendors View less vendors


CVSS Metrics

Group Score Vector
Base 4.3 AV:N/AC:M/Au:N/C:N/I:P/A:N
Temporal 3.9 E:POC/RL:U/RC:C
Environmental 2.9 CDP:ND/TD:M/CR:ND/IR:ND/AR:ND

References

Acknowledgements

This vulnerability was reported publicly by Guido Vranken.

This document was written by Garret Wassermann.

Other Information

CVE IDs: None
Date Public: 2015-02-04
Date First Published: 2015-02-13
Date Last Updated: 2015-02-27 13:52 UTC
Document Revision: 29

Sponsored by CISA.