CVE-2025-27624

5.4 MEDIUM

📋 TL;DR

This CSRF vulnerability in Jenkins allows attackers to trick authenticated users into toggling the collapsed/expanded status of sidepanel widgets like Build Queue and Build Executor Status. It affects Jenkins 2.499 and earlier, and LTS 2.492.1 and earlier. While it doesn't directly compromise data or systems, it can disrupt user interface functionality.

💻 Affected Systems

Products:
  • Jenkins
Versions: Jenkins 2.499 and earlier, Jenkins LTS 2.492.1 and earlier
Operating Systems: All platforms running Jenkins
Default Config Vulnerable: ⚠️ Yes
Notes: All Jenkins installations within affected version ranges are vulnerable regardless of configuration.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

An attacker could repeatedly toggle widget states for multiple users, causing persistent UI disruption and potential productivity loss for Jenkins administrators and users.

🟠

Likely Case

Temporary UI annoyance where users find their widget states unexpectedly changed, requiring manual correction of their preferred layout.

🟢

If Mitigated

Minimal impact with proper CSRF protections enabled and users educated about phishing risks.

🌐 Internet-Facing: MEDIUM - Internet-facing Jenkins instances are vulnerable if users can be tricked into visiting malicious sites while authenticated.
🏢 Internal Only: LOW - Internal-only instances reduce attack surface but still vulnerable to internal phishing attempts.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires the victim to be authenticated to Jenkins and tricked into visiting a malicious webpage. Standard CSRF attack patterns apply.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Jenkins 2.500, Jenkins LTS 2.492.2

Vendor Advisory: https://www.jenkins.io/security/advisory/2025-03-05/#SECURITY-3498

Restart Required: Yes

Instructions:

1. Backup your Jenkins instance and configuration. 2. Download Jenkins 2.500 or Jenkins LTS 2.492.2 from official sources. 3. Stop the Jenkins service. 4. Install the updated version following platform-specific installation procedures. 5. Restart Jenkins service. 6. Verify the update was successful.

🔧 Temporary Workarounds

Enable Strict CSRF Protection

all

Ensure Jenkins CSRF protection is enabled and configured with strict settings

Check 'Enable security' in Jenkins Configure Global Security settings
Ensure 'Prevent Cross Site Request Forgery exploits' is checked

User Education

all

Educate users about phishing risks and not clicking suspicious links while authenticated

🧯 If You Can't Patch

  • Implement network segmentation to restrict Jenkins access to trusted users only
  • Deploy web application firewall (WAF) with CSRF protection rules

🔍 How to Verify

Check if Vulnerable:

Check Jenkins version via Manage Jenkins → About Jenkins or via CLI with 'java -jar jenkins.war --version'

Check Version:

java -jar jenkins.war --version

Verify Fix Applied:

Verify version is 2.500 or higher (or LTS 2.492.2 or higher) and test that widget toggle actions now include proper CSRF tokens

📡 Detection & Monitoring

Log Indicators:

  • Multiple POST requests to /user/[username]/toggleCollapse without corresponding GET requests
  • Unusual pattern of widget state change requests from same IP

Network Indicators:

  • HTTP POST requests to Jenkins toggleCollapse endpoints without proper Referer headers or CSRF tokens

SIEM Query:

source="jenkins.log" AND "toggleCollapse" AND NOT "X-Jenkins-Crumb"

🔗 References

📤 Share & Export