yggdrasil-go/cmd/yggdrasil
Klemens Nanni a0bfd9da44
Rewrite chuser() for simplicity and correctness
- Use unambiguous variable names (w/o package name conflict).
- Fail on invalid input such as the empty string or `:`.
- Do not change group without user, i.e. fail on `:group`.
- Parse input using mnemonic APIs.
- Do not juggle between integer types.
- Unset supplementary groups.
- Use setres[ug]id(2) to match the idiom of OpenBSD base programs.

Includes/Supersedes #1202.
Fixes #927.

I only tested on OpenBSD (so far), hence the split, but other systems
should just work.
2024-11-11 23:02:19 +03:00
..
chuser_openbsd.go Rewrite chuser() for simplicity and correctness 2024-11-11 23:02:19 +03:00
chuser_other.go argument to change uid/gid (#927) 2024-09-22 15:46:54 +00:00
chuser_unix.go Rewrite chuser() for simplicity and correctness 2024-11-11 23:02:19 +03:00
main.go update ironwood dependency 2024-09-28 18:52:04 -05:00