CVE-2024-27933

Source
https://nvd.nist.gov/vuln/detail/CVE-2024-27933
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2024-27933.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2024-27933
Aliases
Published
2024-03-21T02:52:22Z
Modified
2024-10-08T04:07:11.114681Z
Summary
[none]
Details

Deno is a JavaScript, TypeScript, and WebAssembly runtime. In version 1.39.0, use of raw file descriptors in op_node_ipc_pipe() leads to premature close of arbitrary file descriptors, allowing standard input to be re-opened as a different resource resulting in permission prompt bypass. Node child_process IPC relies on the JS side to pass the raw IPC file descriptor to op_node_ipc_pipe(), which returns a IpcJsonStreamResource ID associated with the file descriptor. On closing the resource, the raw file descriptor is closed together.

Use of raw file descriptors in op_node_ipc_pipe() leads to premature close of arbitrary file descriptors. This allow standard input (fd 0) to be closed and re-opened for a different resource, which allows a silent permission prompt bypass. This is exploitable by an attacker controlling the code executed inside a Deno runtime to obtain arbitrary code execution on the host machine regardless of permissions.

This bug is known to be exploitable. There is a working exploit that achieves arbitrary code execution by bypassing prompts from zero permissions, additionally abusing the fact that Cache API lacks filesystem permission checks. The attack can be conducted silently as stderr can also be closed, suppressing all prompt outputs.

Version 1.39.1 fixes the bug.

References

Affected packages

Git / github.com/denoland/deno

Affected ranges

Type
GIT
Repo
https://github.com/denoland/deno
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed
Fixed

Affected versions

std/0.*

std/0.34.0
std/0.35.0
std/0.36.0
std/0.37.0
std/0.38.0
std/0.39.0
std/0.40.0
std/0.41.0
std/0.42.0
std/0.50.0
std/0.51.0
std/0.52.0
std/0.53.0
std/0.54.0
std/0.55.0
std/0.56.0
std/0.57.0
std/0.58.0
std/0.59.0
std/0.60.0
std/0.61.0
std/0.62.0
std/0.63.0
std/0.64.0
std/0.65.0
std/0.66.0
std/0.67.0
std/0.68.0
std/0.69.0
std/0.70.0
std/0.71.0
std/0.72.0
std/0.73.0
std/0.74.0
std/0.75.0
std/0.76.0
std/0.77.0
std/0.78.0
std/0.79.0
std/0.80.0
std/0.81.0
std/0.82.0
std/0.83.0
std/0.84.0
std/0.85.0

v0.*

v0.0.1
v0.0.3
v0.1.0
v0.1.1
v0.1.10
v0.1.11
v0.1.12
v0.1.2
v0.1.3
v0.1.4
v0.1.5
v0.1.6
v0.1.7
v0.1.8
v0.1.9
v0.10.0
v0.11.0
v0.12.0
v0.13.0
v0.14.0
v0.15.0
v0.16.0
v0.17.0
v0.18.0
v0.19.0
v0.2.0
v0.2.1
v0.2.10
v0.2.11
v0.2.2
v0.2.3
v0.2.4
v0.2.5
v0.2.6
v0.2.7
v0.2.8
v0.2.9
v0.20.0
v0.21.0
v0.22.0
v0.23.0
v0.24.0
v0.25.0
v0.26.0
v0.27.0
v0.28.0
v0.28.1
v0.29.0
v0.3.0
v0.3.1
v0.3.10
v0.3.11
v0.3.2
v0.3.3
v0.3.4
v0.3.5
v0.3.6
v0.3.7
v0.3.8
v0.3.9
v0.30.0
v0.30.1
v0.31.0
v0.32.0
v0.33.0
v0.34.0
v0.35.0
v0.36.0
v0.37.0
v0.37.1
v0.38.0
v0.39.0
v0.4.0
v0.40.0
v0.41.0
v0.42.0
v0.5.0
v0.6.0
v0.7.0
v0.8.0
v0.9.0

v1.*

v1.0.0
v1.0.0-rc1
v1.0.0-rc2
v1.0.0-rc3
v1.0.1
v1.0.2
v1.0.3
v1.0.4
v1.0.5
v1.1.0
v1.1.1
v1.1.2
v1.1.3
v1.10.0
v1.10.1
v1.10.3
v1.11.0
v1.11.1
v1.11.2
v1.12.0
v1.12.1
v1.12.2
v1.13.0
v1.13.1
v1.13.2
v1.14.0
v1.14.1
v1.14.2
v1.15.0
v1.15.1
v1.15.2
v1.15.3
v1.16.0
v1.16.1
v1.16.2
v1.17.0
v1.18.0
v1.19.0
v1.2.0
v1.2.1
v1.2.2
v1.2.3
v1.20.0
v1.20.1
v1.21.0
v1.22.0
v1.23.0
v1.24.0
v1.25.0
v1.26.0
v1.27.0
v1.28.0
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