Miggo Logo

CVE-2025-64150: Jenkins Publish to Bitbucket Plugin is missing a permissions check

5.4

CVSS Score
3.1

Basic Information

EPSS Score
-
Published
10/29/2025
Updated
10/29/2025
KEV Status
No
Technology
TechnologyJava

Technical Details

CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N
Package NameEcosystemVulnerable VersionsFirst Patched Version
org.jenkins-ci.plugins:publish-to-bitbucketmaven<= 0.4

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability description for CVE-2025-64150 states that the Jenkins Publish to Bitbucket Plugin has an HTTP endpoint that lacks a permission check, allowing attackers with Overall/Read permission to capture credentials. It also mentions a CSRF vulnerability because the endpoint does not require POST requests. Since no patch is available, the analysis focused on the plugin's source code to find an endpoint matching this description. The BitbucketPublisher.java file contains a DescriptorImpl class, which is a standard way Jenkins plugins expose configuration and HTTP endpoints. Inside this class, the doTestConnection method was identified as the vulnerable function. This method is designed to be called from the Jenkins UI to test the connection to a Bitbucket server. It accepts serverUrl and credentialsId as query parameters. The code shows that it retrieves the specified credentials and makes a GET request to the provided serverUrl with those credentials in the Authorization header. Crucially, the method has no permission checks (like checkPermission) and is not annotated with @RequirePOST, which directly corresponds to the missing authorization and CSRF issues described in the vulnerability. An attacker can set the serverUrl to a server they control and trick an authenticated Jenkins user into making a request to this endpoint, thereby capturing the credentials sent by the plugin.

Vulnerable functions

org.jenkinsci.plugins.publishtobitbucket.BitbucketPublisher.DescriptorImpl.doTestConnection
src/main/java/org/jenkinsci/plugins/publishtobitbucket/BitbucketPublisher.java
The `doTestConnection` method is an HTTP endpoint in the plugin that can be triggered by a GET request. It takes `serverUrl` and `credentialsId` as parameters from the user. The method lacks a permission check to verify if the user is authorized to perform this action, only requiring `Overall/Read` permission. It retrieves the credentials specified by `credentialsId` and sends them in an HTTP request to the user-provided `serverUrl`. This allows an attacker with low privileges to steal stored credentials by providing a URL they control. Furthermore, since the endpoint does not require a POST request, it is vulnerable to Cross-Site Request Forgery (CSRF).

WAF Protection Rules

WAF Rule

J*nkins Pu*lis* to *it*u*k*t Plu*in *.* *n* **rli*r *o*s not p*r*orm * p*rmission ****k in *n *TTP *n*point. T*is *llows *tt**k*rs wit* Ov*r*ll/R*** p*rmission to *onn**t to *n *tt**k*r-sp**i*i** *TTP URL usin* *tt**k*r-sp**i*i** *r***nti*ls I*s o*t

Reasoning

T** vuln*r**ility **s*ription *or *V*-****-***** st*t*s t**t t** J*nkins Pu*lis* to *it*u*k*t Plu*in **s *n *TTP *n*point t**t l**ks * p*rmission ****k, *llowin* *tt**k*rs wit* `Ov*r*ll/R***` p*rmission to **ptur* *r***nti*ls. It *lso m*ntions * *SR*