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

Fix resolve path #61

Merged
merged 2 commits into from
Mar 15, 2024
Merged

Conversation

fischerling
Copy link
Contributor

Sorry for all the followup fixes. Hopefully, resolve_path is now done for the foreseeable future.

Opening the current path component was done because the opened
file could be used for a call to vfs_stat as well as vfs_readlink.

However, a path may contain traversable directories which can not
be opened with vfs_open because they are neither readable nor writeable.

The following path /traversable/foo can not be resolved by uid 1000, if
the traversable directory has the following permissions:

	d--x--x--x 1000 1000 traversable

This is fixed by using vfs_fstat and the current absolute path to
retrieve the attributes of the current path component.
@Galfurian Galfurian merged commit 4e32e79 into mentos-team:develop Mar 15, 2024
18 checks passed
@Galfurian Galfurian added the bug Something isn't working label Apr 5, 2024
@fischerling fischerling deleted the fix-resolve-path branch July 20, 2024 18:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants