Skip to content

Editor spawning and file writing for sudoedit #1199

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

Merged
merged 3 commits into from
Jul 21, 2025

Conversation

bjorn3
Copy link
Collaborator

@bjorn3 bjorn3 commented Jul 16, 2025

This makes sudoedit functional, though still missing some security checks.

Unlike original sudo, all interactions with the editor process are done from an unprivileged helper process. This way for example replacing the temporary file with a symlink as user is harmless from a security perspective without needing an explicit O_NOFOLLOW. The unprivileged helper process can't be tricked into reading files that the user couldn't already read.

@bjorn3 bjorn3 requested a review from squell July 16, 2025 14:12
@squell squell added this to the Sudoedit milestone Jul 16, 2025
@squell
Copy link
Member

squell commented Jul 21, 2025

(For future reference, security checks are in #1204)

@bjorn3 bjorn3 enabled auto-merge (rebase) July 21, 2025 13:11
@bjorn3 bjorn3 disabled auto-merge July 21, 2025 13:11
@bjorn3 bjorn3 enabled auto-merge July 21, 2025 13:12
@bjorn3 bjorn3 merged commit a8b1fc8 into trifectatechfoundation:main Jul 21, 2025
17 checks passed
@bjorn3 bjorn3 deleted the sudoedit_impl2 branch July 21, 2025 13:36
squell added a commit that referenced this pull request Jul 22, 2025
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.

2 participants