Restrict sysroot fallback to exclude system paths#241
Merged
Conversation
doanbaotrung
force-pushed
the
system-path-leaks
branch
2 times, most recently
from
July 23, 2026 07:39
f929172 to
5f7bd78
Compare
doanbaotrung
force-pushed
the
system-path-leaks
branch
from
July 23, 2026 09:25
5444a4b to
3ba3664
Compare
jserv
marked this pull request as draft
July 23, 2026 11:15
doanbaotrung
marked this pull request as ready for review
July 23, 2026 12:12
doanbaotrung
force-pushed
the
system-path-leaks
branch
from
July 23, 2026 12:28
3ba3664 to
4bb69b2
Compare
jserv
reviewed
Jul 23, 2026
When absolute paths do not exist in the guest sysroot, translation falls back to the host literal path. For standard system directories (such as /usr, /bin, /lib, /sbin, /var, /opt, and /etc), this fallback leaks guest actions to the host. On macOS, system directories are protected by System Integrity Protection (SIP) and root ownership, causing permission failures (EPERM/EACCES) when guest tools attempt writes or backups. Prevent fallback for system paths. Keep fallback for network configurations like /etc/resolv.conf to support DNS resolution. Fix sysprog21#238
doanbaotrung
force-pushed
the
system-path-leaks
branch
from
July 23, 2026 12:34
4bb69b2 to
b1e4a21
Compare
Contributor
|
Thank @doanbaotrung for contributing! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When absolute paths do not exist in the guest sysroot, translation falls back to the host literal path. For standard system directories (such as /usr, /bin, /lib, /sbin, /var, /opt, and /etc), this fallback leaks guest actions to the host.
On macOS, system directories are protected by System Integrity Protection (SIP) and root ownership, causing permission failures (EPERM/EACCES) when guest tools attempt writes or backups.
Prevent fallback for system paths. Keep fallback for network configurations like /etc/resolv.conf to support DNS resolution.
Fix #238
Summary by cubic
Restricts sysroot fallback so guest paths under system directories never escape to the host, including dot/dot-dot variants. Fixes #238 and avoids SIP permission errors on macOS while keeping DNS working.
Written for commit b1e4a21. Summary will update on new commits.