Skip to content

Rework setting of user and group ID.#11

Merged
partim merged 4 commits intomainfrom
rework-set-user
Sep 1, 2025
Merged

Rework setting of user and group ID.#11
partim merged 4 commits intomainfrom
rework-set-user

Conversation

@partim
Copy link
Member

@partim partim commented Aug 29, 2025

This PR updates setting of user and group ID along the lines of what Unbound does.

This requires a bit of trickery to be portable. I hope the commentary in the code is sufficient to explain what’s going on.

This PR builds on #9 and supersedes it.

@ximon18
Copy link
Member

ximon18 commented Aug 29, 2025

I'll test this branch with the nameshed-hsm-relay branch that was failing the rpmlint checks during packaging to verify that this PR fixes the issue.

@partim partim requested a review from ximon18 August 29, 2025 14:56
@ximon18
Copy link
Member

ximon18 commented Aug 29, 2025

It passes when used in my packaging run, e.g. see here.

@partim partim merged commit 6175761 into main Sep 1, 2025
24 checks passed
@partim partim deleted the rework-set-user branch September 1, 2025 09:42
partim added a commit that referenced this pull request Sep 29, 2025
New

* Reworked setting of user and group. If not provided explicitly, the
  group will now be set to the user’s group. The list of supplemental
  groups will be initialized from the user’s group list. ([#11])
* Allow manually creating the process configuration so it can be used
  without the _clap_ argument parser. ([#12])
* Added support for systemd’s socket activation. ([#13])
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.

2 participants