CVE-2023-46122
What it is
sbt is a build tool for Scala, Java, and others. Given a specially crafted zip or JAR file, `IO.unzip` allows writing of arbitrary file. This would have potential to overwrite `/root/.ssh/authorized_keys`. Within sbt's main code, `IO.unzip` is used in `pullRemoteCache` task and `Resolvers.remote`; however many projects use `IO.unzip(...)` directly to implement custom tasks. This vulnerability has been patched in version 1.9.7.
At a glance
- Exploitability
- Can be exploited locally on the machine with a low-privilege account, but needs a user to act. Limited direct impact.
- Exploit odds
- 0.4% chance of exploitation in the next 30 days (EPSS).
- Fix
- A patch, advisory or fixed version is referenced. Upgrade or apply it.
Timeline
- PublishedDisclosed publicly on CVE.org and NVD
- Last updatedMost recent change to the record
Why it ranks here
- Exploited in the wild: no, CISA does not list it.
- Exploit odds: 0.4% in the next 30 days (EPSS).
- Severity: 3.9 LOW (CVSS).
- Fix: a patch or advisory is linked.
Details
- Published
- Last modified
- Exploit probability
- 0.4% · EPSS, next 30 days
- Weakness
- CWE-22 · Path traversal
- Record status
- Modified
Affected
- scala-sbt Io < 1.9.7
- scala-sbt Sbt < 1.9.7
Attack profile CVSS 3.1 · 3.9
- Attack vector
- Local
- Complexity
- Low
- Privileges needed
- Low
- User interaction
- Required
- Scope
- Unchanged
- Confidentiality
- None
- Integrity
- Low
- Availability
- Low
Raw vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:N/I:L/A:L
Is it in your code?
Hand this to your coding agent. It searches your project for the affected products and checks versions. Nothing leaves your machine.
Read https://cve-list.com/agent/cve/CVE-2023-46122.md and follow it. Check whether this project is affected by CVE-2023-46122. Read only. Don't change anything and don't upload my code. Tell me yes, no or not sure, with the file as proof.
Fix and advisories
- https://github.com/sbt/io/commit/124538348db0713c80793cb57b915f97ec13188a
- https://github.com/sbt/io/issues/358
- https://github.com/sbt/io/pull/360
- https://github.com/sbt/sbt/security/advisories/GHSA-h9mw-grgx-2fhf
- https://github.com/sbt/io/commit/124538348db0713c80793cb57b915f97ec13188a
- https://github.com/sbt/io/issues/358
- https://github.com/sbt/io/pull/360
- https://github.com/sbt/sbt/security/advisories/GHSA-h9mw-grgx-2fhf
References
- https://github.com/sbt/io/commit/124538348db0713c80793cb57b915f97ec13188a
- https://github.com/sbt/io/issues/358
- https://github.com/sbt/io/pull/360
- https://github.com/sbt/sbt/security/advisories/GHSA-h9mw-grgx-2fhf
- https://github.com/sbt/io/commit/124538348db0713c80793cb57b915f97ec13188a
- https://github.com/sbt/io/issues/358
- https://github.com/sbt/io/pull/360
- https://github.com/sbt/sbt/security/advisories/GHSA-h9mw-grgx-2fhf