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

Skip sudo invocation if running user is sudo #218

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

terrorbyte
Copy link

This one has been floating around for a while #160 and bumped into a situation with systems without sudo.

I did the simple steps of checking if the user was running as root in the sudo context and skipping. I do think it might be a little bit more logical to check for the user before switching between the sudo and non-sudo context, but the code changes were longer. If that's preferred I'll switch it up.

This is also probably my first steps for adding support for other privesc methods (as sudo-rs is broken right now due to the lack of -p support).

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.

1 participant