Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disallow malformed path with null byte #266

Merged
merged 1 commit into from
Jun 3, 2024

Conversation

yagehu
Copy link
Contributor

@yagehu yagehu commented May 28, 2024

This commit adds a check when resolving path such that any null bytes in the input path causes errno inval. This is consistent with other runtimes like Wasmtime, Wasmer, Wazero, WasmEdge, and WAMR.

fixes #265

This commit adds a check when resolving path such that any null bytes in
the input path causes errno `inval`.  This is consistent with other
runtimes like Wasmtime, Wasmer, Wazero, WasmEdge, and WAMR.

fixes nodejs#265

Signed-off-by: Yage Hu <me@huyage.dev>
@yagehu
Copy link
Contributor Author

yagehu commented May 31, 2024

@mhdawson can you take a look? Fairly straightforward change. Thanks!

Copy link
Member

@mhdawson mhdawson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mhdawson mhdawson merged commit 7aaa0b4 into nodejs:main Jun 3, 2024
7 checks passed
@yagehu yagehu deleted the yagehu/malformed-path-open branch June 3, 2024 23:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

uvwasi accepts malformed path containing null byte
3 participants