Lookup supplementary groups during peer credential lookup #968

Open
opened 2025-08-19 18:00:29 +00:00 by raito · 0 comments
Owner

When running "highly" hardened workloads with DynamicUser=true from systemd, primary UID/GID are not stable.

Therefore, bestowing allowed user or trusted user privileges to these workloads is non-trivial.

To avoid this, a simple trick would be to use a supplementary group and thread it via systemd and making Lix accept connections from that supplementary group.

Unfortunately, Lix does not perform any lookup of supplementary groups and only know about primary UID/GIDs.

Describe the solution you'd like

PAM lookup at peer credential lookup time to obtain richer information about the pending connection.

Describe alternatives you've considered

Static allocations which is the classical workaround.

Additional context

This came up while setting up Renovate for lix-project/nixos-module in a safe way.

cc @delroth

## Is your feature request related to a problem? Please describe. When running "highly" hardened workloads with `DynamicUser=true` from systemd, primary UID/GID are not stable. Therefore, bestowing allowed user or trusted user privileges to these workloads is non-trivial. To avoid this, a simple trick would be to use a supplementary group and thread it via systemd and making Lix accept connections from that supplementary group. Unfortunately, Lix does not perform any lookup of supplementary groups and only know about primary UID/GIDs. ## Describe the solution you'd like PAM lookup at peer credential lookup time to obtain richer information about the pending connection. ## Describe alternatives you've considered Static allocations which is the classical workaround. ## Additional context This came up while setting up Renovate for lix-project/nixos-module in a safe way. cc @delroth
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: lix-project/lix#968
No description provided.