CVE-2020-35217

8.8 HIGH

📋 TL;DR

CVE-2020-35217 is a critical CSRF vulnerability in Vert.x-Web framework where CSRF verification incorrectly compares tokens within the session instead of validating request tokens against cookie tokens. This allows attackers to perform CSRF attacks without providing any CSRF token in requests, potentially enabling unauthorized actions on behalf of authenticated users. All applications using affected Vert.x-Web versions with CSRF protection enabled are vulnerable.

💻 Affected Systems

Products:
  • Vert.x-Web framework
Versions: Version 4.0 milestone 1 through milestone 4
Operating Systems: All
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects applications using the CSRF protection feature of Vert.x-Web. Applications not using CSRF protection are not vulnerable.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Attackers can perform any authenticated action on behalf of victims, including account takeover, data theft, financial transactions, or administrative operations depending on application functionality.

🟠

Likely Case

Unauthorized state-changing actions such as changing user settings, making purchases, or modifying data through authenticated endpoints.

🟢

If Mitigated

If proper CSRF controls are implemented correctly, impact is limited to applications with additional authentication bypass vulnerabilities.

🌐 Internet-Facing: HIGH - Web applications exposed to the internet are directly vulnerable to CSRF attacks from malicious sites.
🏢 Internal Only: MEDIUM - Internal applications are still vulnerable to attacks from compromised internal systems or malicious insiders.

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires the victim to be authenticated and visit a malicious site. The vulnerability is simple to exploit with basic web development knowledge.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Vert.x-Web 4.0.0-milestone5 and later

Vendor Advisory: https://github.com/vert-x3/vertx-web/pull/1613

Restart Required: Yes

Instructions:

1. Update Vert.x-Web dependency to version 4.0.0-milestone5 or later. 2. Update pom.xml or build.gradle with new version. 3. Rebuild and redeploy application. 4. Restart application server.

🔧 Temporary Workarounds

Disable CSRF Protection

all

Temporarily disable CSRF protection until patching is possible. This removes the broken CSRF verification but leaves applications vulnerable to CSRF attacks.

Remove or comment out CSRFHandler configuration in your Vert.x application

Implement Custom CSRF Validation

all

Create custom middleware that properly validates CSRF tokens by comparing request tokens with cookie tokens.

Implement custom handler that validates 'X-CSRF-Token' header against CSRF cookie value

🧯 If You Can't Patch

  • Implement additional authentication requirements for sensitive actions (MFA, re-authentication)
  • Use SameSite=Strict cookie attribute and implement CORS restrictions

🔍 How to Verify

Check if Vulnerable:

Check if using Vert.x-Web version 4.0.0-milestone1 through milestone4 with CSRFHandler enabled. Review application dependencies and configuration.

Check Version:

Check build configuration files: For Maven: grep -r 'vertx-web' pom.xml; For Gradle: grep -r 'vertx-web' build.gradle

Verify Fix Applied:

Verify Vert.x-Web version is 4.0.0-milestone5 or later. Test CSRF protection by attempting to submit a form without proper CSRF token - should be rejected.

📡 Detection & Monitoring

Log Indicators:

  • Multiple successful state-changing requests from same IP with missing or mismatched CSRF tokens
  • Unexpected successful POST/PUT/DELETE requests without proper CSRF validation logs

Network Indicators:

  • Cross-origin requests to authenticated endpoints without proper CSRF tokens
  • Requests from unexpected referrers to state-changing endpoints

SIEM Query:

web_requests method=POST status=200 csrf_token=null OR web_requests method=POST status=200 referer NOT IN allowed_domains

🔗 References

📤 Share & Export