Description
Formbricks is an open source qualtrics alternative. Prior to version 4.0.1, Formbricks is missing JWT signature verification. This vulnerability stems from a token validation routine that only decodes JWTs (jwt.decode) without verifying their signatures. Both the email verification token login path and the password reset server action use the same validator, which does not check the token’s signature, expiration, issuer, or audience. If an attacker learns the victim’s actual user.id, they can craft an arbitrary JWT with an alg: "none" header and use it to authenticate and reset the victim’s password. This issue has been patched in version 4.0.1.
EPSS Score:
0%
Comprehensive Technical Analysis of EUVD-2025-31394
1. Vulnerability Assessment and Severity Evaluation
Vulnerability Description:
Formbricks, an open-source alternative to Qualtrics, has a critical vulnerability in versions prior to 4.0.1. The issue arises from the lack of JWT (JSON Web Token) signature verification during token validation. Specifically, the jwt.decode function is used without verifying the token's signature, expiration, issuer, or audience. This flaw allows an attacker to craft and use arbitrary JWTs with an alg: "none" header to authenticate and reset a victim's password.
Severity Evaluation:
The vulnerability has a CVSS (Common Vulnerability Scoring System) base score of 9.4, which is considered critical. The CVSS vector CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:L indicates the following:
- Attack Vector (AV): Network (N)
- Attack Complexity (AC): Low (L)
- Privileges Required (PR): None (N)
- User Interaction (UI): None (N)
- Scope (S): Unchanged (U)
- Confidentiality (C): High (H)
- Integrity (I): High (H)
- Availability (A): Low (L)
This high severity score underscores the potential for significant impact on confidentiality and integrity, with a relatively low complexity of exploitation.
2. Potential Attack Vectors and Exploitation Methods
Attack Vectors:
- Email Verification Token Login Path: An attacker can exploit this path by crafting a JWT with an
alg: "none"header to bypass authentication. - Password Reset Server Action: Similarly, an attacker can use a crafted JWT to reset the victim's password.
Exploitation Methods:
- Token Crafting: An attacker can create a JWT with an
alg: "none"header and include the victim'suser.id. - Authentication Bypass: The crafted JWT can be used to authenticate as the victim.
- Password Reset: The attacker can reset the victim's password, gaining full control over the account.
3. Affected Systems and Software Versions
Affected Systems:
- Formbricks versions prior to 4.0.1
Software Versions:
- All versions of Formbricks before 4.0.1 are vulnerable.
4. Recommended Mitigation Strategies
Immediate Actions:
- Upgrade to Version 4.0.1: Ensure all instances of Formbricks are updated to version 4.0.1 or later, where the vulnerability has been patched.
- Implement JWT Verification: Ensure that JWTs are properly verified, including signature, expiration, issuer, and audience checks.
Long-Term Strategies:
- Regular Security Audits: Conduct regular security audits and code reviews to identify and mitigate similar vulnerabilities.
- Use Secure Libraries: Utilize well-maintained and secure libraries for JWT handling.
- Monitor and Patch: Continuously monitor for new vulnerabilities and apply patches promptly.
5. Impact on European Cybersecurity Landscape
Impact Assessment:
- Data Breaches: The vulnerability can lead to unauthorized access and data breaches, compromising user data and trust.
- Compliance Risks: Organizations may face compliance issues with regulations such as GDPR if user data is compromised.
- Reputation Damage: Companies using vulnerable versions of Formbricks may suffer reputational damage due to security incidents.
Regulatory Considerations:
- GDPR Compliance: Ensure compliance with GDPR by implementing robust security measures and promptly addressing vulnerabilities.
- Incident Reporting: Follow incident reporting guidelines as per GDPR and other relevant regulations.
6. Technical Details for Security Professionals
Technical Analysis:
- JWT Handling: The vulnerability stems from the use of
jwt.decodewithout proper verification. Ensure that JWTs are decoded and verified using secure methods. - Code Review: Review the token validation routine to ensure it includes checks for signature, expiration, issuer, and audience.
- Patch Details: The patch in version 4.0.1 addresses the issue by implementing proper JWT verification.
References:
- GitHub Advisory: GHSA-7229-q9pv-j6p4
- Pull Request: Pull Request #6596
- Commit: Commit eb1349f205189d5b2d4a95ec42245ca98cf68c82
- Code Snippet: jwt.ts
Conclusion: The vulnerability in Formbricks versions prior to 4.0.1 is critical and requires immediate attention. Organizations should upgrade to the patched version and implement robust JWT verification to mitigate risks. Regular security audits and compliance with regulations are essential to maintain a secure cybersecurity landscape in Europe.