Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessReach 2FAuth instance directly
-
DeliveryForge REMOTE_USER/identity header as admin
-
ExploitBypass proxy trust check, authenticate
-
ExecutionExport all 2FA secrets and settings
-
ImpactDisable encryption / manage accounts
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A07:2025 - Authentication Failures
ASVS 5.0
V6 - Authentication Authentication mechanism validation
MITRE ATT&CK
2 techniques across 2 tactics: Defense Evasion, Initial Access The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Two concrete conditions must both hold: (1) the instance is configured with AUTHENTICATION_GUARD=reverse-proxy-guard - an opt-in, documented mode for SSO reverse-proxy deployments (Authelia, Authentik, Nginx auth_request) that is NOT the default; and (2) the application is directly reachable by the attacker, bypassing the trusted proxy that would normally set/overwrite the identity header. When both hold, ReverseProxyGuard::user() reads REMOTE_USER (or the custom header named by AUTH_PROXY_HEADER_FOR_USER) with no source-IP/trusted-proxy verification, so exploitation needs no credentials and no user interaction. Limiting factors: instances using any other authentication guard are not affected; instances whose proxy correctly strips/overwrites the header and whose backend is not directly exposed are protected; and only versions <=7.0.1 are vulnerable (fixed in 8.0.0). |
| Impact | This is a genuine high-priority issue rather than a CVSS-inflated one, but its real-world reach is gated by a specific deployment mode. The NVD CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H = 9.8) accurately reflects that, once the vulnerable mode is active, a remote attacker with no authentication and no user interaction can fully impersonate any user including an administrator. The vuln.today decision label is act_now, and the vendor GHSA advisory ships a complete, detailed proof-of-concept (bash commands plus a Python takeover script), which raises practical exploitability considerably. Counterbalancing signals: the flaw only manifests when AUTHENTICATION_GUARD=reverse-proxy-guard is explicitly enabled (an opt-in, non-default feature) AND the application is directly reachable so an attacker can bypass the trusted proxy - so the CVSS AV:N/PR:N rating describes the worst-case enabled configuration, not every 2FAuth install. No EPSS score was supplied and the CVE is not listed in CISA KEV, so there is no evidence of active in-the-wild exploitation at time of analysis; the risk here is driven by published exploit code plus a trivially forgeable header, not by confirmed mass exploitation. Net: urgent for any instance running the reverse-proxy-guard mode, low-to-no risk for instances using other authentication guards. |
| Exploit ScenarioDerived | An operator runs 2FAuth with AUTHENTICATION_GUARD=reverse-proxy-guard behind an SSO proxy (e.g. Authelia/Authentik), but the container port or host is also directly reachable (common during setup, via Docker port mapping, or firewall misconfiguration). An attacker sends a single HTTP request to the app directly with a forged REMOTE_USER (or the configured AUTH_PROXY_HEADER_FOR_USER) header set to an existing or admin username, and is authenticated instantly. A working public PoC in the vendor advisory then enumerates and exports every stored TOTP/HOTP secret and can disable at-rest encryption, yielding full account/application takeover. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Nov 06, 2026
Unauthenticated account takeover of 2FAuth deployments that run the opt-in reverse-proxy-guard mode: any client able to reach the application directly can forge the identity header (REMOTE_USER by default, or the header named by AUTH_PROXY_HEADER_FOR_USER) and be authenticated as an existing user - including an administrator - in a single request, with full read access to stored TOTP/HOTP secrets and to account and application management functions. The issue affects 2FAuth up to and including 7.0.1 and is fixed in 8.0.0; instances using any other authentication guard are not affected, and the exposure requires that the backend be reachable without passing through a trusted proxy. The vendor advisory GHSA-mh8r-74x2-r457 includes a detailed public PoC reference (curl steps and a Python script) that has not been independently verified as working exploit code, and the issue is not listed in CISA KEV; the vendor's fix and the priority label of act_now reflect the complete loss of confidentiality, integrity and availability once the two deployment preconditions are met.
RemediationAI
Vendor-released patch: upgrade to 2FAuth 8.0.0 (release https://github.com/Bubka/2FAuth/releases/tag/v8.0.0), which adds an isFromTrustedProxy() gate in ReverseProxyGuard::user() - see commit https://github.com/Bubka/2FAuth/commit/43873cbfba445926c7008b4291eeee67752af9e8. After upgrading, the trusted proxy list must be populated (the new tests set the trustedProxies configuration explicitly); the patched code returns no user for requests from untrusted addresses, and when no trusted-proxy configuration exists at all the request is rejected with HTTP 407, so correctly configuring trusted proxies is part of completing the fix. If upgrading is not immediately possible, the vendor-supplied compensating measure is to eliminate the second precondition: ensure the 2FAuth backend port is reachable only through the trusted reverse proxy, and configure that proxy to strip and overwrite REMOTE_USER (and any custom AUTH_PROXY_HEADER_FOR_USER header) on every inbound request - the trade-off is that any direct-access path (Docker port publishing, firewall gaps during setup, health-check endpoints) silently reopens the bypass; alternatively switch AUTHENTICATION_GUARD away from reverse-proxy-guard until the upgrade can be applied, at the cost of losing SSO header-based sign-in for that deployment.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
2FAuth is a PHP/Laravel web application; the flaw is an improper authentication weakness (CWE-287) in app/Services/Auth/ReverseProxyGuard.php, a custom Laravel guard used when AUTHENTICATION_GUARD=reverse-proxy-guard. The guard's user() method read the identity value unconditionally via request()->server($remoteUserHeader) (falling back to apache_request_headers()[$remoteUserHeader]), which maps to $_SERVER['REMOTE_USER'] or a custom header configured through AUTH_PROXY_HEADER_FOR_USER. Crucially, Laravel's TrustProxies middleware only governs X-Forwarded-* headers used for client-IP detection and does not strip or validate REMOTE_USER or any custom authentication header, so there was no source-IP or trusted-proxy verification anywhere in the authentication chain. Any HTTP client that reaches the application without traversing the SSO reverse proxy (Authelia, Authentik, Nginx auth_request and similar) can therefore present the header itself and be treated as that user. The fixed commit 43873cbfba445926c7008b4291eeee67752af9e8 adds a request()->isFromTrustedProxy() check at the top of user(), logs a warning and returns a null user when the request does not originate from a configured trusted proxy; added tests confirm that requests from an untrusted REMOTE_ADDR are rejected and that when no trusted-proxy configuration exists at all the request fails with HTTP 407 rather than authenticating. The precise request-handling trigger beyond direct reachability of the endpoint is a straightforward header read; the advisory does not describe any further precondition such as timing or request-state manipulation.
Know when 2fauth gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
In the vulnerable mode the header is forgeable over the network with no auth or interaction (AV:N/AC:L/PR:N/UI:N); full impersonation of admin yields total C/I/A loss; the enabling feature is an environmental precondition, not an attacker privilege.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
2DescriptionCVE.org
2FAuth is a web app to manage Two-Factor Authentication (2FA) accounts and generate their security codes. Prior to 8.0.0, when AUTHENTICATION_GUARD=reverse-proxy-guard is enabled, ReverseProxyGuard::user() reads the default REMOTE_USER identity header, or a custom identity header selected by the AUTH_PROXY_HEADER_FOR_USER configuration setting, without confirming that the request originated from a configured trusted proxy. A remote client that can reach the application directly can forge the selected identity header and authenticate as an existing user, including an administrator, gaining access to stored 2FA secrets and account or application management functions. This issue is fixed in version 8.0.0.
Technical POC Analysis
CWE-287 Improper Authentication.
Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.
Executive ViewAI
A critical authentication bypass in 2FAuth version 7.0.1 and earlier allows attackers to gain unauthorized access to sensitive two-factor authentication secrets and administrative functions when the product is deployed in reverse-proxy-guard mode without proper network segmentation. This vulnerability directly compromises the confidentiality of protected accounts and could enable broader identity theft across the organization. Leadership must prioritize immediate remediation to prevent potential breaches of critical systems.
No vendor-released patch identified at time of analysis. Interim mitigations include restricting network access to the 2FAuth application so that it is only reachable through a trusted reverse proxy, disabling reverse-proxy-guard mode, and ensuring that direct requests to the backend are blocked by firewall rules.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Authentication bypass attacks exploit flaws in the verification mechanisms that control access to systems and applications.
2FAuth is a web app to manage Two-Factor Authentication (2FA) accounts and generate their security codes. Rated high sev
2FAuth is a web app to manage Two-Factor Authentication (2FA) accounts and generate their security codes. Rated medium s
2FA is a Web app to manage Two-Factor Authentication (2FA) accounts and generate their security codes. Rated medium seve
Unauthenticated remote attackers can gain full administrative control of a fresh 2FAuth instance, or impersonate known u
Blind SSRF in 2FAuth 2FA manager before 6.1.0.
Host header injection in 2FAuth before 9.0.1 lets an unauthenticated attacker poison the password-reset and WebAuthn-rec
Missing per-resource authorization in 2FAuth's share recipients endpoint (all versions prior to 8.0.0) lets any authenti
2FAuth versions up to and including 7.0.1 are exposed to authenticated server-side request forgery through the otpauth i
Server-side request forgery in 2FAuth 6.1.0 through 7.0.1 lets the app's remote-image fetch reach internal IPv4 targets
EUVD-2026-118492
NVD
CVE.org
EPSS
GitHub
Exploit-DB