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

Detect root #3

Open
insanitybit opened this issue Feb 6, 2022 · 0 comments
Open

Detect root #3

insanitybit opened this issue Feb 6, 2022 · 0 comments

Comments

@insanitybit
Copy link
Owner

There are two reasons one might run dlfile as root.

  1. By mistake. Happens all the time with curl and other cli tools.
  2. On purpose so that dlfile can write out to a privileged file.

I think in an ideal world (2) wouldn't happen. Instead dlfile would pipe the data to /dev/stdout and then another tool would handle the writing of the file. That said, it's probably worth supporting it.

Further, given root, we can perform more sandboxing. I don't want dlfile to be a setuid or something like that, but if we do run as root we can access namespaces, chroot, etc. This would significantly improve the sandbox.

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

No branches or pull requests

1 participant