GHSA-h6mp-mc7g-mg49: Scheb/two factor bundle Scheb/two-factor-bundle Bypass Two-factor Authentication With Vulnerability

HIGH
CVSS 7.4
CWE-287
Published
Advisory Summary

GHSA-h6mp-mc7g-mg49 is a HIGH (CVSS 7.4) scheb/two-factor-bundle bypass two-factor authentication with vulnerability (CWE-287: Improper Authentication) affecting Scheb/two factor bundle libraries in the Packagist ecosystem. The issue involves scheb/two-factor-bundle bypass two-factor authentication with unverified jwt trusted device token. Remediation is available by upgrading affected packages to version 3.7.0.

GHSA-h6mp-mc7g-mg49 at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-h6mp-mc7g-mg49
Severity HIGH
CVSS v3.1 Base Score 7.4
CWE Classification CWE-287: Improper Authentication
Affected Product Scheb/two factor bundle
Package Ecosystem Packagist
Published Date
Last Updated

Security Impact

CVSS: 7.4

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N).

Attack Vector Network (AV:N)
Attack Complexity High (AC:H)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability None (A:N)

How to Fix GHSA-h6mp-mc7g-mg49

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

scheb/two-factor-bundle fixed: 3.7.0
Upgrade scheb/two-factor-bundle to 3.7.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 scheb/two-factor-bundle

How to Check if You Are Affected

To determine whether your application is affected by GHSA-h6mp-mc7g-mg49, inspect your project dependencies for Scheb/two factor bundle:

inspect dependencies for scheb/two-factor-bundle

Analyze the terminal output to locate any version of Scheb/two factor bundle in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 3.7.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-287: Improper Authentication, where when an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct. In Scheb/two factor bundle, 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

Before version 3.7 the bundle is vulnerable to a [security issue in JWT](https://auth0.com/blog/critical-vulnerabilities-in-json-web-token-libraries/), which can be exploited by an attacker to generate trusted device cookies on their own, effectively by-passing two-factor authentication.

GHSA-h6mp-mc7g-mg49 Affected Scheb/two factor bundle Versions

1 component(s)
Fixed Versions:
3.7.0
Product / Package Ecosystem Affected Versions Fixed Version
scheb/two-factor-bundle
Packagist
≥ 3.0.0
< 3.7.0
3.7.0

References

Frequently Asked Questions

What is GHSA-h6mp-mc7g-mg49?
GHSA-h6mp-mc7g-mg49 is a security vulnerability in Scheb/two factor bundle involving scheb/two-factor-bundle bypass two-factor authentication with unverified JWT trusted device token under CWE-287: Improper Authentication.
Which Scheb/two factor bundle versions are affected?
Affected versions include releases prior to 3.7.0 across affected packages: scheb/two-factor-bundle.
What version fixes GHSA-h6mp-mc7g-mg49?
Upgrading to 3.7.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is scheb/two-factor-bundle affected?
Yes, scheb/two-factor-bundle is affected in releases prior to 3.7.0. Upgrade your dependency to 3.7.0 or later.
What is the CVSS score of GHSA-h6mp-mc7g-mg49?
GHSA-h6mp-mc7g-mg49 has a CVSS v3.1 base score of 7.4 (HIGH) with vector string CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N.
What CWE is associated with GHSA-h6mp-mc7g-mg49?
GHSA-h6mp-mc7g-mg49 is classified under CWE-287: Improper Authentication (When an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct.).
How can I check Packagist dependencies for GHSA-h6mp-mc7g-mg49?
Run the dependency tree command: 'inspect dependencies for scheb/two-factor-bundle'. 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-h6mp-mc7g-mg49",
  "modified" : "2024-05-21T18:16:24Z",
  "published" : "2024-05-21T18:16:24Z",
  "aliases" : [ ],
  "summary" : "scheb/two-factor-bundle bypass two-factor authentication with unverified JWT trusted device token",
  "details" : "Before version 3.7 the bundle is vulnerable to a [security issue in JWT](https://auth0.com/blog/critical-vulnerabilities-in-json-web-token-libraries/), which can be exploited by an attacker to generate trusted device cookies on their own, effectively by-passing two-factor authentication.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "scheb/two-factor-bundle"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "3.0.0"
      }, {
        "fixed" : "3.7.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/scheb/two-factor-bundle/issues/143"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/scheb/two-factor-bundle/commit/8890c1e47ae89e0ac6f8a40fd4bb4b91c2081aa7"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/FriendsOfPHP/security-advisories/blob/master/scheb/two-factor-bundle/2018-07-08.yaml"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/scheb/two-factor-bundle"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-287" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-05-21T18:16:24Z",
    "nvd_published_at" : null
  }
}