Bypass Two-Factor Authentication in scheb/two-factor-bundle

scheb/two-factor-bundle Updated 02 Oct 2025

Summary

21/05/2024
HIGH
Yes i
High
7.4

GHSA-h6mp-mc7g-mg49: scheb/two-factor-bundle bypass two-factor authentication with unverified JWT trusted device token. Affects scheb/two-factor-bundle versions >= 3.0.0, < 3.7.0. Fixed in 3.7.0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

scheb/two-factor-bundle is a package available on Packagist that provides two-factor authentication functionality for PHP applications. It allows developers to easily implement an additional layer of security to protect user accounts. However, versions prior to 3.7 are vulnerable to a critical security issue in the JSON Web Token (JWT) library it relies on. This vulnerability can be exploited by an attacker to generate trusted device cookies and bypass the two-factor authentication mechanism.

Vulnerability Detail

The vulnerability in scheb/two-factor-bundle arises from a security flaw in the JWT library it uses. By exploiting this flaw, an attacker can generate their own trusted device cookies, effectively bypassing the two-factor authentication process. This means that even if a user has enabled two-factor authentication, an attacker can gain unauthorized access to their account without needing to provide the second factor of authentication. The impact of this vulnerability is significant, as it undermines the security provided by two-factor authentication.

How To Fix

Minimum fixed version

3.7.0

This is the first release that contains the fix.

composer require scheb/two-factor-bundle:3.7.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

There is no known workaround for this vulnerability. It is essential to upgrade to the fixed version of scheb/two-factor-bundle to ensure the security of the two-factor authentication mechanism.

Conclusion

The scheb/two-factor-bundle package is vulnerable to a critical security issue that allows attackers to bypass two-factor authentication. To mitigate this vulnerability, it is crucial to upgrade to version 3.7.0 or later of the package. For further assistance and support in addressing this vulnerability, please contact DevNack.com.

See every vulnerability recorded for scheb/two-factor-bundle →

Share this vulnerability

FAQ

scheb/two-factor-bundle is a PHP package that provides two-factor authentication functionality for applications.

The vulnerability allows an attacker to bypass two-factor authentication and gain unauthorized access to user accounts.

To fix this vulnerability, upgrade to version 3.7.0 or later of scheb/two-factor-bundle.

No, there is no known workaround. Upgrading to the fixed version is the recommended solution.

You can find more information about scheb/two-factor-bundle on its official GitHub repository.

Related vulnerabilities

Recent vulnerabilities recorded for scheb/two-factor-bundle.

How To Fix

Minimum fixed version

3.7.0

This is the first release that contains the fix.

composer require scheb/two-factor-bundle:3.7.0

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback