Source
pub const passwd = switch (native_os) {
// https://github.com/SerenityOS/serenity/blob/7442cfb5072b74a62c0e061e6e9ff44fda08780d/Userland/Libraries/LibC/pwd.h#L15-L23
.linux, .serenity => extern struct {
name: ?[*:0]const u8, // username
passwd: ?[*:0]const u8, // user password
uid: uid_t, // user ID
gid: gid_t, // group ID
gecos: ?[*:0]const u8, // user information
dir: ?[*:0]const u8, // home directory
shell: ?[*:0]const u8, // shell program
},
.netbsd, .openbsd, .macos => extern struct {
name: ?[*:0]const u8, // user name
passwd: ?[*:0]const u8, // encrypted password
uid: uid_t, // user uid
gid: gid_t, // user gid
change: time_t, // password change time
class: ?[*:0]const u8, // user access class
gecos: ?[*:0]const u8, // Honeywell login info
dir: ?[*:0]const u8, // home directory
shell: ?[*:0]const u8, // default shell
expire: time_t, // account expiration
},
else => void,
}