Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2024-8122 Overview
CVE-2024-8122 affects the WSO2 Identity Server, which does not enforce a default expiry time for SMS One-Time Passwords (OTPs) used in multi-factor authentication (MFA). Unused OTPs remain valid indefinitely, giving attackers an unbounded window to brute force the code. A successful attack bypasses MFA and leads to account takeover. The weakness is categorized as [CWE-613] Insufficient Session Expiration.
Critical Impact
Attackers can brute force SMS OTP codes without time constraints, bypass MFA, and take over user accounts in affected WSO2 Identity Server deployments.
Affected Products
- WSO2 Identity Server (SMS OTP MFA authenticator)
- WSO2 identity products using the vulnerable SMS OTP flow
- Refer to the WSO2 Security Advisory WSO2-2024-3149 for the complete list of affected versions
Discovery Timeline
- 2026-10-08 - CVE-2024-8122 published to the National Vulnerability Database (NVD)
- 2026-10-08 - Last updated in NVD database
Technical Details for CVE-2024-8122
Vulnerability Analysis
The WSO2 Identity Server generates SMS OTP codes for MFA challenges but does not apply a default lifetime to those codes. An OTP issued during a login attempt remains accepted by the authenticator until it is consumed or explicitly invalidated. This behavior defeats a core assumption of OTP-based MFA, which relies on short-lived codes to limit guessing.
SMS OTPs are typically six to eight digits. Without expiry, an attacker who holds a valid username and password can submit OTP guesses against the authentication endpoint until the correct value is found. The result is a full MFA bypass and account takeover, with corresponding loss of confidentiality for the targeted identity.
Root Cause
The root cause is a missing default OTP expiration configuration in the SMS OTP authenticator. The flaw maps to [CWE-613] Insufficient Session Expiration. The authenticator stores the generated code without binding it to a server-enforced time-to-live, so stale codes continue to validate.
Attack Vector
The attack is remote and does not require privileges or user interaction beyond the initial credential submission. An attacker who has obtained or guessed valid primary credentials initiates the MFA flow and then issues repeated OTP verification requests. Because no expiry invalidates the code, the attacker can continue guessing across sessions until a match occurs.
No verified exploit code is published. See the WSO2 Security Advisory WSO2-2024-3149 for vendor-provided technical details.
Detect Identity Attacks the Moment Authentication Fails
Singularity™ Identity surfaces credential misuse, lateral movement, and privilege escalation in real time, so you can contain the breach before it spreads.
Stop Identity AttacksDetection Methods for CVE-2024-8122
Indicators of Compromise
- Elevated volumes of failed SMS OTP verification attempts for a single user or session identifier
- Successful MFA completions preceded by sustained OTP submission activity across minutes or hours
- Authentication events where the OTP validation timestamp is significantly later than the OTP issuance timestamp
Detection Strategies
- Correlate WSO2 Identity Server authentication logs to flag sessions with repeated SMSOTPAuthenticator failures followed by success
- Alert on OTP validation events whose issuance-to-consumption delta exceeds a reasonable threshold such as five minutes
- Baseline normal OTP verification counts per user and alert on statistical outliers
Monitoring Recommendations
- Forward WSO2 Identity Server audit and authentication logs to a centralized logging or SIEM platform
- Monitor for authentication anomalies against identity infrastructure and tie them to downstream account activity
- Review account takeover indicators such as new device enrollments, password resets, and privilege changes after MFA completion
How to Mitigate CVE-2024-8122
Immediate Actions Required
- Apply the vendor update referenced in WSO2 Security Advisory WSO2-2024-3149
- Explicitly configure a short OTP expiry (for example, two to five minutes) in the SMS OTP authenticator configuration
- Enforce account lockout and rate limiting on repeated failed OTP attempts
- Rotate credentials and review MFA activity for any account exhibiting excessive OTP verification events
Patch Information
WSO2 has published remediation guidance in WSO2 Security Advisory WSO2-2024-3149. Administrators should apply the recommended product updates or configuration changes as described by the vendor. There is no vendor-provided patch hash listed in the NVD record at the time of publication.
Workarounds
- Set a non-default OTP validity period in the SMS OTP authenticator configuration until the patched version is deployed
- Enable brute force protection and progressive account lockout on the authentication endpoint
- Require re-authentication of the primary credential after a small number of failed OTP attempts
# Configuration example
# In the SMS OTP authenticator configuration, set an explicit OTP expiry.
# Refer to WSO2-2024-3149 for the exact parameter names in your version.
SMSOTPAuthenticator.OTPExpiryTime=300 # seconds (5 minutes)
SMSOTPAuthenticator.MaxFailedAttempts=5 # lock after 5 failed attempts
SMSOTPAuthenticator.LockoutDuration=900 # seconds (15 minutes)
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

