Skip to content

GHSA-8v4w-f4r9-7h6x CVE-2024-8037 GO-2024-3174

Vulnerable juju hook tool abstract UNIX domain socket

Medium Go
Severity
0.0 / 10
Medium · CVSS 4.0
Exploit chance (EPSS)
0.19%
Chance of exploitation in the next 30 days. Higher than 8.32% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-284 Improper Access Control
Fix
0.0.0-20240820065804-2f2ec128ef5a
Upgrade github.com/juju/juju to this version or later

Description

Impact

When combined with an attack of JUJU_CONTEXT_ID, any user on the local system with access to the default network namespace may connect to the @/var/lib/juju/agents/unit-xxxx-yyyy/agent.socket and perform actions that are normally reserved to a juju charm.

Patches

Patch: https://github.com/juju/juju/commit/2f2ec128ef5a8ca81fc86ae79cfcdbab0007c206 Patched in:

  • 3.5.4
  • 3.4.6
  • 3.3.7
  • 3.1.10
  • 2.9.51

Workarounds

No workarounds available.

References

GHSA-mh98-763h-m9v4 https://github.com/juju/juju/blob/725800953aaa29dbeda4f806097bf838e61644dd/worker/uniter/paths.go#L222

Affected versions

Go

PackageVulnerableFixed in
github.com/juju/juju
< 0.0.0-20240820065804-2f2ec128ef5a
0.0.0-20240820065804-2f2ec128ef5a

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

github.com/juju/juju Go → 0.0.0-20240820065804-2f2ec128ef5a

go
go get github.com/juju/juju@v0.0.0-20240820065804-2f2ec128ef5a && go mod tidy

Severity breakdown

CVSS 4.0 0.0

CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:L/VI:N/VA:N/SC:N/SI:H/SA:H

Attack vector
Local
Attack complexity
Low
Attack requirements
None
Privileges required
Low
User interaction
None
Confidentiality (vulnerable system)
Low
Integrity (vulnerable system)
None
Availability (vulnerable system)
None
Confidentiality (subsequent systems)
None
Integrity (subsequent systems)
High
Availability (subsequent systems)
High

CVSS 3.1 6.5

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

Attack vector
Local
Attack complexity
High
Privileges required
Low
User interaction
None
Scope
Unchanged
Confidentiality
Low
Integrity
High
Availability
High

Weakness

CWE-284: Improper Access Control

The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.

How to prevent it
  • Architecture and Design, Operation: Very carefully manage the setting, management, and handling of privileges. Explicitly manage trust zones in the software.
  • Architecture and Design: Compartmentalize the system to have "safe" areas where trust boundaries can be unambiguously drawn. Do not allow sensitive data to go outside of the trust boundary and always be careful when interfacing with a compartment outside of the safe area. Ensure that appropriate compartmentalization is built into the system design, and the compartmentalization allows for and reinforces privilege separation functionality. Architects and designers should rely on the principle of least privilege to decide the appropriate time to use privileges and the time to drop privileges.

References

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
GHSA-7m55-2hr4-pw78
Juju: In-Memory Token Store for Discharge Tokens Lacks Concurrency Safety and Persistence
Medium Also affects github.com/juju/juju
GHSA-w5fq-8965-c969
Juju: CloudSpec method leaking cloud credentials
Medium Also affects github.com/juju/juju
GHSA-245v-p8fj-vwm2
Juju has a resource poisoning vulnerability
Medium Also affects github.com/juju/juju
GHSA-j6f6-jp3p-53mw
Juju: Read All Controller Logs From Compromised Workload
Medium Also affects github.com/juju/juju
GHSA-gvrj-cjch-728p
Juju has Improper TLS Client/Server authentication and certificate verification on Database Cluster
Critical Also affects github.com/juju/juju
GHSA-5cj2-rqqf-hx9p
Juju affected by Confused Deputy IDOR attack via Predictable user specified ID in Juju Secrets
Medium Also affects github.com/juju/juju
GHSA-439w-v2p7-pggc
Juju has unauthorized access to out-of-scope Kubernetes secrets
High Also affects github.com/juju/juju
GHSA-89x7-5m5m-mcmm
Juju has unauthorized update of out-of-scope Vault secrets
Medium Also affects github.com/juju/juju
Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor