-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Allow numeric uids/gids in allowed-users and trusted-users #8510
base: master
Are you sure you want to change the base?
Conversation
It might not make much of a difference, but |
Also, this closes #8444. |
@cole-h Yeah I was being imprecise. I meant Linux-style sandboxing, which macOS doesn't have. So it always fails on macOS and it fails on Linux when sandboxing is disabled. |
Can we use |
This is a nice thing, I hope we can get it merged soon! |
`whoami` doesn't work when auto-uid-allocation is enabled and sandboxing is disabled, since then the build UID doesn't have a matching entry in /etc/passwd.
Gentle ~bump on this since we're having to move our UID/GID on macOS for compatibility with the early Sequoia beta. It would be nice to get out of the permanent-user game before we need to move again :) See: |
Motivation
Also, don't use
whoami
. It doesn't work when auto-uid-allocation is enabled and sandboxing is disabled, since then the build UID doesn't have a matching entry in/etc/passwd
.This also does some cleanups in
PeerInfo
, replacing the bool guards withstd::optional
. There was at least a theoretical possibility that we were using uninitialized uid/gid fields.Context
Checklist for maintainers
Maintainers: tick if completed or explain if not relevant
tests/**.sh
src/*/tests
tests/nixos/*
Priorities
Add 👍 to pull requests you find important.