Skip to content

Conversation

s3lph
Copy link

@s3lph s3lph commented Nov 23, 2024

At the moment, the uid/gid for the ydotoold socket ownership must be provided numerically.

This PR extends the socket owner string parsing with the following logic:

  1. Try to parse uid and gid as int
    • If the entire string is consumed (i.e. it was fully numerical), treat it as uid/gid => done
  2. Otherwise, treat it as a username or groupname and look it up via getpwnam/getgrnam
    • If the name is not found, exit
    • Otherwise use the found user's uid / group's gid

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.

1 participant