GHSA-78hm-5hjw-58mh: Ua parser/uap php Denial of Service Vulnerability

MODERATE
CWE-1333
Published
Advisory Summary

GHSA-78hm-5hjw-58mh is a MODERATE denial of service vulnerability (CWE-1333: Inefficient Regular Expression Complexity) affecting Ua parser/uap php libraries in the Packagist ecosystem. The issue involves ua-parser/uap-php redos vulnerability. Remediation is available by upgrading affected packages to version 3.8.0.

GHSA-78hm-5hjw-58mh at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-78hm-5hjw-58mh
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-1333: Inefficient Regular Expression Complexity
Affected Product Ua parser/uap php
Package Ecosystem Packagist
Published Date
Last Updated

How to Fix GHSA-78hm-5hjw-58mh

To remediate this vulnerability, upgrade all affected Ua parser/uap php dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

ua-parser/uap-php fixed: 3.8.0
Upgrade ua-parser/uap-php to 3.8.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for ua-parser/uap-php

How to Check if You Are Affected

To determine whether your application is affected by GHSA-78hm-5hjw-58mh, inspect your project dependencies for Ua parser/uap php:

inspect dependencies for ua-parser/uap-php

Analyze the terminal output to locate any version of Ua parser/uap php in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.8.0), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-1333: Inefficient Regular Expression Complexity, where the product uses a regular expression with a worst-case computational complexity that is inefficient and possibly exponential. In Ua parser/uap php, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

A regex expression in ua-parser/uap-php could lead to a ReDoS vulnerability in versions prior to 3.8.0.

GHSA-78hm-5hjw-58mh Affected Ua parser/uap php Versions

1 component(s)
Fixed Versions:
3.8.0
Product / Package Ecosystem Affected Versions Fixed Version
ua-parser/uap-php
Packagist
< 3.8.0
3.8.0

References

Frequently Asked Questions

What is GHSA-78hm-5hjw-58mh?
GHSA-78hm-5hjw-58mh is a security vulnerability in Ua parser/uap php involving ua-parser/uap-php ReDoS vulnerability under CWE-1333: Inefficient Regular Expression Complexity.
Which Ua parser/uap php versions are affected?
Affected versions include releases prior to 3.8.0 across affected packages: ua-parser/uap-php.
What version fixes GHSA-78hm-5hjw-58mh?
Upgrading to 3.8.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is ua-parser/uap-php affected?
Yes, ua-parser/uap-php is affected in releases prior to 3.8.0. Upgrade your dependency to 3.8.0 or later.
What CWE is associated with GHSA-78hm-5hjw-58mh?
GHSA-78hm-5hjw-58mh is classified under CWE-1333: Inefficient Regular Expression Complexity (The product uses a regular expression with a worst-case computational complexity that is inefficient and possibly exponential.).
How can I check Packagist dependencies for GHSA-78hm-5hjw-58mh?
Run the dependency tree command: 'inspect dependencies for ua-parser/uap-php'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-78hm-5hjw-58mh",
  "modified" : "2024-06-07T22:15:42Z",
  "published" : "2024-06-07T22:14:49Z",
  "aliases" : [ ],
  "summary" : "ua-parser/uap-php ReDoS vulnerability",
  "details" : "A regex expression in ua-parser/uap-php could lead to a ReDoS vulnerability in versions prior to 3.8.0.",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "ua-parser/uap-php"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "3.8.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/ua-parser/uap-core/pull/363"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/ua-parser/uap-core/commit/156f7e12b215bddbaf3df4514c399d683e6cdadc"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/ua-parser/uap-php/commit/947f80b39130c83a3d1c75900ac1b58828ed8aef"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/FriendsOfPHP/security-advisories/blob/master/ua-parser/uap-php/2018-12-14.yaml"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/ua-parser/uap-php"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-1333" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-06-07T22:14:49Z",
    "nvd_published_at" : null
  }
}