[GH-ISSUE #367] Parse /etc/login.def for UID_MIN #264

Closed
opened 2026-05-05 05:27:37 -06:00 by gitea-mirror · 6 comments
Owner

Originally created by @chiraag-nataraj on GitHub (Mar 16, 2016).
Original GitHub issue: https://github.com/netblue30/firejail/issues/367

Maybe I'm misunderstanding what you mean by "sanitizing" /etc/passwd and /etc/group, but the files seem to be the same as they are outside the sandbox. What exactly does firejail do?

Originally created by @chiraag-nataraj on GitHub (Mar 16, 2016). Original GitHub issue: https://github.com/netblue30/firejail/issues/367 Maybe I'm misunderstanding what you mean by "sanitizing" /etc/passwd and /etc/group, but the files seem to be the same as they are outside the sandbox. What exactly does firejail do?
gitea-mirror 2026-05-05 05:27:37 -06:00
Author
Owner

@netblue30 commented on GitHub (Mar 16, 2016):

Only the current user and group are left in the file. All other users/groups are removed. If you are the only user on the system, the files will be unchanged.

<!-- gh-comment-id:197393344 --> @netblue30 commented on GitHub (Mar 16, 2016): Only the current user and group are left in the file. All other users/groups are removed. If you are the only user on the system, the files will be unchanged.
Author
Owner

@chiraag-nataraj commented on GitHub (Mar 17, 2016):

Ah okay, thanks!

<!-- gh-comment-id:197704651 --> @chiraag-nataraj commented on GitHub (Mar 17, 2016): Ah okay, thanks!
Author
Owner

@thomasjfox commented on GitHub (Jul 26, 2016):

Also every uid < 1000 is kept, at least in firejail up to 0.9.42-rc1.
Later versions might parse /etc/login.defs for UID_MIN.

I stumbled upon this behaviour since the restricted /etc/passwd still contained an additional user account with UID 503.

<!-- gh-comment-id:235383745 --> @thomasjfox commented on GitHub (Jul 26, 2016): Also every uid < 1000 is kept, at least in firejail up to 0.9.42-rc1. Later versions might parse /etc/login.defs for UID_MIN. I stumbled upon this behaviour since the restricted /etc/passwd still contained an additional user account with UID 503.
Author
Owner

@netblue30 commented on GitHub (Jul 29, 2016):

Fixed in git repository.

<!-- gh-comment-id:236185519 --> @netblue30 commented on GitHub (Jul 29, 2016): Fixed in git repository.
Author
Owner

@thomasjfox commented on GitHub (Jul 29, 2016):

On Friday, 29. July 2016 06:51:06 netblue30 wrote:

Fixed in git repository.

pretty cool :) thanks!

<!-- gh-comment-id:236185920 --> @thomasjfox commented on GitHub (Jul 29, 2016): On Friday, 29. July 2016 06:51:06 netblue30 wrote: > Fixed in git repository. pretty cool :) thanks!
Author
Owner

@netblue30 commented on GitHub (Jul 29, 2016):

You're welcome!

<!-- gh-comment-id:236286931 --> @netblue30 commented on GitHub (Jul 29, 2016): You're welcome!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#264
No description provided.