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

Prevent parent directory from being opened without being preopened wasi #463

Merged
merged 2 commits into from
May 22, 2019

Conversation

MarkMcCaskey
Copy link
Contributor

@MarkMcCaskey MarkMcCaskey commented May 22, 2019

resolves #462

Because the logic of opening a directory and traversing the tree are separate, we allowed one level of .. to be opened beyond what was preopened

The diff on github isn't clear, but this adds an if and then puts the previous logic in an else block

@MarkMcCaskey
Copy link
Contributor Author

bors r+

bors bot added a commit that referenced this pull request May 22, 2019
463: Prevent parent directory from being opened without being preopened wasi r=MarkMcCaskey a=MarkMcCaskey

resolves  #462

Because the logic of opening a directory and traversing the tree are separate, we allowed one level of `..` to be opened beyond what was preopened

The diff on github isn't clear, but this adds an if and then puts the previous logic in an else block

Co-authored-by: Mark McCaskey <mark@wasmer.io>
@bors
Copy link
Contributor

bors bot commented May 22, 2019

@bors bors bot merged commit dc3ac15 into master May 22, 2019
@bors bors bot deleted the fix/wasi-dir-access-bug branch May 22, 2019 23:10
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.

Reading directory permissions
2 participants