Vulnerabilities > CVE-2008-0172 - Improper Input Validation vulnerability in Boost 1.33/1.34

047910
CVSS 5.0 - MEDIUM
Attack vector
NETWORK
Attack complexity
LOW
Privileges required
NONE
Confidentiality impact
NONE
Integrity impact
NONE
Availability impact
PARTIAL
network
low complexity
ubuntu
boost
CWE-20
nessus

Summary

The get_repeat_type function in basic_regex_creator.hpp in the Boost regex library (aka Boost.Regex) in Boost 1.33 and 1.34 allows context-dependent attackers to cause a denial of service (NULL dereference and crash) via an invalid regular expression.

Common Weakness Enumeration (CWE)

Common Attack Pattern Enumeration and Classification (CAPEC)

  • Buffer Overflow via Environment Variables
    This attack pattern involves causing a buffer overflow through manipulation of environment variables. Once the attacker finds that they can modify an environment variable, they may try to overflow associated buffers. This attack leverages implicit trust often placed in environment variables.
  • Server Side Include (SSI) Injection
    An attacker can use Server Side Include (SSI) Injection to send code to a web application that then gets executed by the web server. Doing so enables the attacker to achieve similar results to Cross Site Scripting, viz., arbitrary code execution and information disclosure, albeit on a more limited scale, since the SSI directives are nowhere near as powerful as a full-fledged scripting language. Nonetheless, the attacker can conveniently gain access to sensitive files, such as password files, and execute shell commands.
  • Cross Zone Scripting
    An attacker is able to cause a victim to load content into their web-browser that bypasses security zone controls and gain access to increased privileges to execute scripting code or other web objects such as unsigned ActiveX controls or applets. This is a privilege elevation attack targeted at zone-based web-browser security. In a zone-based model, pages belong to one of a set of zones corresponding to the level of privilege assigned to that page. Pages in an untrusted zone would have a lesser level of access to the system and/or be restricted in the types of executable content it was allowed to invoke. In a cross-zone scripting attack, a page that should be assigned to a less privileged zone is granted the privileges of a more trusted zone. This can be accomplished by exploiting bugs in the browser, exploiting incorrect configuration in the zone controls, through a cross-site scripting attack that causes the attackers' content to be treated as coming from a more trusted page, or by leveraging some piece of system functionality that is accessible from both the trusted and less trusted zone. This attack differs from "Restful Privilege Escalation" in that the latter correlates to the inadequate securing of RESTful access methods (such as HTTP DELETE) on the server, while cross-zone scripting attacks the concept of security zones as implemented by a browser.
  • Cross Site Scripting through Log Files
    An attacker may leverage a system weakness where logs are susceptible to log injection to insert scripts into the system's logs. If these logs are later viewed by an administrator through a thin administrative interface and the log data is not properly HTML encoded before being written to the page, the attackers' scripts stored in the log will be executed in the administrative interface with potentially serious consequences. This attack pattern is really a combination of two other attack patterns: log injection and stored cross site scripting.
  • Command Line Execution through SQL Injection
    An attacker uses standard SQL injection methods to inject data into the command line for execution. This could be done directly through misuse of directives such as MSSQL_xp_cmdshell or indirectly through injection of data into the database that would be interpreted as shell commands. Sometime later, an unscrupulous backend application (or could be part of the functionality of the same application) fetches the injected data stored in the database and uses this data as command line arguments without performing proper validation. The malicious data escapes that data plane by spawning new commands to be executed on the host.

Nessus

  • NASL familyGentoo Local Security Checks
    NASL idGENTOO_GLSA-200802-08.NASL
    descriptionThe remote host is affected by the vulnerability described in GLSA-200802-08 (Boost: Denial of Service) Tavis Ormandy and Will Drewry from the Google Security Team reported a failed assertion in file regex/v4/perl_matcher_non_recursive.hpp (CVE-2008-0171) and a NULL pointer dereference in function get_repeat_type() file basic_regex_creator.hpp (CVE-2008-0172) when processing regular expressions. Impact : A remote attacker could provide specially crafted regular expressions to an application using Boost, resulting in a crash. Workaround : There is no known workaround at this time.
    last seen2020-06-01
    modified2020-06-02
    plugin id31110
    published2008-02-18
    reporterThis script is Copyright (C) 2008-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/31110
    titleGLSA-200802-08 : Boost: Denial of Service
  • NASL familyUbuntu Local Security Checks
    NASL idUBUNTU_USN-570-1.NASL
    descriptionWill Drewry and Tavis Ormandy discovered that the boost library did not properly perform input validation on regular expressions. An attacker could send a specially crafted regular expression to an application linked against boost and cause a denial of service via application crash. Note that Tenable Network Security has extracted the preceding description block directly from the Ubuntu security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues.
    last seen2020-06-01
    modified2020-06-02
    plugin id30018
    published2008-01-18
    reporterUbuntu Security Notice (C) 2008-2019 Canonical, Inc. / NASL script (C) 2018 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/30018
    titleUbuntu 6.06 LTS / 6.10 / 7.04 / 7.10 : boost vulnerabilities (USN-570-1)
  • NASL familyOracle Linux Local Security Checks
    NASL idORACLELINUX_ELSA-2012-0305.NASL
    descriptionFrom Red Hat Security Advisory 2012:0305 : Updated boost packages that fix two security issues and two bugs are now available for Red Hat Enterprise Linux 5. The Red Hat Security Response Team has rated this update as having low security impact. Common Vulnerability Scoring System (CVSS) base scores, which give detailed severity ratings, are available for each vulnerability from the CVE links in the References section. The boost packages provide free, peer-reviewed, portable C++ source libraries with emphasis on libraries which work well with the C++ Standard Library. Invalid pointer dereference flaws were found in the way the Boost regular expression library processed certain, invalid expressions. An attacker able to make an application using the Boost library process a specially crafted regular expression could cause that application to crash or, potentially, execute arbitrary code with the privileges of the user running the application. (CVE-2008-0171) NULL pointer dereference flaws were found in the way the Boost regular expression library processed certain, invalid expressions. An attacker able to make an application using the Boost library process a specially crafted regular expression could cause that application to crash. (CVE-2008-0172) Red Hat would like to thank Will Drewry for reporting these issues. This update also fixes the following bugs : * Prior to this update, the construction of a regular expression object could fail when several regular expression objects were created simultaneously, such as in a multi-threaded program. With this update, the object variables have been moved from the shared memory to the stack. Now, the constructing function is thread safe. (BZ#472384) * Prior to this update, header files in several Boost libraries contained preprocessor directives that the GNU Compiler Collection (GCC) 4.4 could not handle. This update instead uses equivalent constructs that are standard C. (BZ#567722) All users of boost are advised to upgrade to these updated packages, which fix these issues.
    last seen2020-06-01
    modified2020-06-02
    plugin id68476
    published2013-07-12
    reporterThis script is Copyright (C) 2013-2019 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/68476
    titleOracle Linux 5 : boost (ELSA-2012-0305)
  • NASL familySuSE Local Security Checks
    NASL idSUSE_BOOST-4946.NASL
    descriptionCertain regular expressions could cause the boost library to crash (CVE-2008-0171, CVE-2008-0172).
    last seen2020-06-01
    modified2020-06-02
    plugin id31451
    published2008-03-13
    reporterThis script is Copyright (C) 2008-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/31451
    titleopenSUSE 10 Security Update : boost (boost-4946)
  • NASL familyScientific Linux Local Security Checks
    NASL idSL_20120221_BOOST_ON_SL5_X.NASL
    descriptionThe boost packages provide free, peer-reviewed, portable C++ source libraries with emphasis on libraries which work well with the C++ Standard Library. Invalid pointer dereference flaws were found in the way the Boost regular expression library processed certain, invalid expressions. An attacker able to make an application using the Boost library process a specially crafted regular expression could cause that application to crash or, potentially, execute arbitrary code with the privileges of the user running the application. (CVE-2008-0171) NULL pointer dereference flaws were found in the way the Boost regular expression library processed certain, invalid expressions. An attacker able to make an application using the Boost library process a specially crafted regular expression could cause that application to crash. (CVE-2008-0172) This update also fixes the following bugs : - Prior to this update, the construction of a regular expression object could fail when several regular expression objects were created simultaneously, such as in a multi-threaded program. With this update, the object variables have been moved from the shared memory to the stack. Now, the constructing function is thread safe. - Prior to this update, header files in several Boost libraries contained preprocessor directives that the GNU Compiler Collection (GCC) 4.4 could not handle. This update instead uses equivalent constructs that are standard C. All users of boost are advised to upgrade to these updated packages, which fix these issues.
    last seen2020-03-18
    modified2012-08-01
    plugin id61256
    published2012-08-01
    reporterThis script is Copyright (C) 2012-2020 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/61256
    titleScientific Linux Security Update : boost on SL5.x i386/x86_64 (20120221)
  • NASL familySuSE Local Security Checks
    NASL idSUSE_BOOST-4978.NASL
    descriptionCertain regular expressions could cause the boost library to crash. (CVE-2008-0171 / CVE-2008-0172)
    last seen2020-06-01
    modified2020-06-02
    plugin id31452
    published2008-03-13
    reporterThis script is Copyright (C) 2008-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/31452
    titleSuSE 10 Security Update : boost (ZYPP Patch Number 4978)
  • NASL familyRed Hat Local Security Checks
    NASL idREDHAT-RHSA-2012-0305.NASL
    descriptionUpdated boost packages that fix two security issues and two bugs are now available for Red Hat Enterprise Linux 5. The Red Hat Security Response Team has rated this update as having low security impact. Common Vulnerability Scoring System (CVSS) base scores, which give detailed severity ratings, are available for each vulnerability from the CVE links in the References section. The boost packages provide free, peer-reviewed, portable C++ source libraries with emphasis on libraries which work well with the C++ Standard Library. Invalid pointer dereference flaws were found in the way the Boost regular expression library processed certain, invalid expressions. An attacker able to make an application using the Boost library process a specially crafted regular expression could cause that application to crash or, potentially, execute arbitrary code with the privileges of the user running the application. (CVE-2008-0171) NULL pointer dereference flaws were found in the way the Boost regular expression library processed certain, invalid expressions. An attacker able to make an application using the Boost library process a specially crafted regular expression could cause that application to crash. (CVE-2008-0172) Red Hat would like to thank Will Drewry for reporting these issues. This update also fixes the following bugs : * Prior to this update, the construction of a regular expression object could fail when several regular expression objects were created simultaneously, such as in a multi-threaded program. With this update, the object variables have been moved from the shared memory to the stack. Now, the constructing function is thread safe. (BZ#472384) * Prior to this update, header files in several Boost libraries contained preprocessor directives that the GNU Compiler Collection (GCC) 4.4 could not handle. This update instead uses equivalent constructs that are standard C. (BZ#567722) All users of boost are advised to upgrade to these updated packages, which fix these issues.
    last seen2020-04-16
    modified2012-02-21
    plugin id58059
    published2012-02-21
    reporterThis script is Copyright (C) 2012-2020 and is owned by Tenable, Inc. or an Affiliate thereof.
    sourcehttps://www.tenable.com/plugins/nessus/58059
    titleRHEL 5 : boost (RHSA-2012:0305)
  • NASL familyFedora Local Security Checks
    NASL idFEDORA_2008-0880.NASL
    description - Wed Jan 16 2008 Petr Machata <pmachata at redhat.com> - 1.33.1-15 - Fixes for boost.regex. - Mon Nov 19 2007 Petr Machata <pmachata at redhat.com> - 1.33.1-14 - Apply/testsuite ambiguous option patch from James Philbin - Resolves: #369581 Note that Tenable Network Security has extracted the preceding description block directly from the Fedora security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues.
    last seen2020-06-01
    modified2020-06-02
    plugin id30078
    published2008-01-27
    reporterThis script is Copyright (C) 2008-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/30078
    titleFedora 7 : boost-1.33.1-15.fc7 (2008-0880)
  • NASL familyMandriva Local Security Checks
    NASL idMANDRIVA_MDVSA-2008-032.NASL
    descriptionTavis Ormandy and Will Drewry found that the bost library did not properly perform input validation on regular expressions. An attacker could exploit this by sening a specially crafted regular expression to an application linked against boost and cause a denial of service via an application crash. The updated packages have been patched to correct this issue.
    last seen2020-06-01
    modified2020-06-02
    plugin id37818
    published2009-04-23
    reporterThis script is Copyright (C) 2009-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/37818
    titleMandriva Linux Security Advisory : boost (MDVSA-2008:032)
  • NASL familyFedora Local Security Checks
    NASL idFEDORA_2008-0754.NASL
    description - Wed Jan 16 2008 Petr Machata <pmachata at redhat.com> 1.34.1-7 - Fixes for boost.regex (rev 42674). Note that Tenable Network Security has extracted the preceding description block directly from the Fedora security advisory. Tenable has attempted to automatically clean and format it as much as possible without introducing additional issues.
    last seen2020-06-01
    modified2020-06-02
    plugin id31427
    published2008-03-13
    reporterThis script is Copyright (C) 2008-2019 Tenable Network Security, Inc.
    sourcehttps://www.tenable.com/plugins/nessus/31427
    titleFedora 8 : boost-1.34.1-7.fc8 (2008-0754)

Redhat

advisories
bugzilla
id567722
titleg++4.4 incompatible with numeric/ublas/matrix_sparse.hpp
oval
OR
  • commentRed Hat Enterprise Linux must be installed
    ovaloval:com.redhat.rhba:tst:20070304026
  • AND
    • commentRed Hat Enterprise Linux 5 is installed
      ovaloval:com.redhat.rhba:tst:20070331005
    • OR
      • AND
        • commentboost is earlier than 0:1.33.1-15.el5
          ovaloval:com.redhat.rhsa:tst:20120305001
        • commentboost is signed with Red Hat redhatrelease key
          ovaloval:com.redhat.rhsa:tst:20120305002
      • AND
        • commentboost-doc is earlier than 0:1.33.1-15.el5
          ovaloval:com.redhat.rhsa:tst:20120305003
        • commentboost-doc is signed with Red Hat redhatrelease key
          ovaloval:com.redhat.rhsa:tst:20120305004
      • AND
        • commentboost-devel is earlier than 0:1.33.1-15.el5
          ovaloval:com.redhat.rhsa:tst:20120305005
        • commentboost-devel is signed with Red Hat redhatrelease key
          ovaloval:com.redhat.rhsa:tst:20120305006
rhsa
idRHSA-2012:0305
released2012-02-21
severityLow
titleRHSA-2012:0305: boost security and bug fix update (Low)
rpms
  • boost-0:1.33.1-15.el5
  • boost-debuginfo-0:1.33.1-15.el5
  • boost-devel-0:1.33.1-15.el5
  • boost-doc-0:1.33.1-15.el5

Statements

contributorMark J Cox
lastmodified2008-05-12
organizationRed Hat
statementThis issue did not affect the version of boost as shipped with Red Hat Enterprise Linux 4. For Red Hat Enterprise Linux 5, Red Hat is aware of this issue and is tracking it via the following bug: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=CVE-2008-0172 The Red Hat Security Response Team has rated this issue as having low security impact, a future update may address this flaw.