/

CVE-2026-86722

Severity:

HIGH RISK

(8.1)

Authentication Bypass (CWE-287) in AVideo 2FA Flow

CVE-2026-86722

Deferred

Vulnerability type

Category:

Authentication Bypass

CWE:

CWE-287

Impact:

Two-Factor Authentication Bypass and Unauthorized Account Access

Severity:

HIGH RISK

(8.1)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

AVideo contains an authentication bypass caused by stale caching of empty database results during email two-factor authentication. An attacker who has a valid password may be able to access an account from a new device without successfully completing the email-based confirmation step.

Affected context

The vulnerability occurs in AVideo authentication flows that use sqlDAL result caching while processing email two-factor authentication for new devices. It becomes risky when an empty cached result is reused after the underlying data has changed, preventing the confirmation-code hash from being generated or validated as intended.

Exploit preconditions

  • Attack surface: AVideo login and new-device email two-factor authentication workflow
  • Required access: A valid account password; access to the account's email is not necessarily required for the bypass condition
  • Trigger point: Authentication from a device that requires email-based confirmation
  • Why exploitation is possible: sqlDAL can retain an empty result set, while writeSql does not invalidate that cached result, causing confirmation-code hash generation or lookup to operate on stale data

Why this happens

The underlying defect is inconsistent cache invalidation between database writes and cached reads. When an empty query result remains cached after related authentication data is written, later logic may incorrectly conclude that the confirmation-code record or hash is unavailable. This behavior maps to CWE-287: Improper Authentication, because the application can grant access without reliably enforcing a required authentication factor.

Potential impact

  • An attacker with a valid password may bypass email-based two-factor authentication
  • Unauthorized access to an account may occur from an untrusted or new device
  • Account data and user-controlled content could be exposed or modified
  • Compromised accounts could be used for further abuse within the application

General mitigation guidance

Mitigation generally focuses on making authentication state consistent and ensuring that every required factor is independently verified before access is granted.

Common defensive patterns include:

  • Invalidate or refresh cached authentication results whenever related records are created, updated, or deleted
  • Avoid treating cached empty results as authoritative when authentication state may have changed
  • Perform confirmation-code generation and verification against a consistent transactional data view
  • Fail closed when a required second-factor record or validation result is missing
  • Apply least privilege to authenticated sessions and require reauthentication for sensitive account changes
  • Reduce trust in client-controlled device and session indicators

How teams detect issues like this

Organizations can look for this class of issue through:

  • Static analysis and code review checks for database writes that do not invalidate related caches
  • Tests that exercise empty-result caching followed by record creation or update
  • Authentication integration tests covering new devices, repeated attempts, expired codes, and concurrent requests
  • Monitoring for successful logins where the expected second-factor verification event is absent
  • Policy enforcement requiring fail-closed behavior and independent verification of all configured authentication factors

Automated review tools may help identify inconsistent cache lifecycle handling and authentication branches that proceed after missing validation state.

Sources

SourceLink
github.comgithub.com/WWBN/AVideo/security/advisories/GHSA-wmhg-p72j-72gf
vulncheck.comvulncheck.com/advisories/avideo-authentication-bypass-via-sql-cache-invalidation

Frequently asked

questions

It may be exploitable through the normal AVideo authentication interface when the vulnerable caching condition is present. The attacker still needs a valid password for the target account.

The described bypass condition is intended to avoid successful email confirmation on a new device, so email access may not be required. Deployment-specific controls can affect the practical scope.

Ensure authentication data and cache state remain consistent, invalidate stale empty results after writes, and fail closed whenever the required second factor cannot be verified.

Test authentication flows across cache hits, cache misses, state transitions, and concurrent requests. Monitoring should also correlate successful logins with completed second-factor verification events.

Find out what's already
exploitable in your codebase.