Parses /etc/master.passwd
Author: Matt Dainty ma@bodgit-n-s carper.com tt
MasterPasswd | Parses /etc/master.passwd |
Reference | |
USEFUL PRIMITIVES | |
Comments and empty lines | |
ENTRIES | |
password | pw_passwd |
uid | pw_uid |
gid | pw_gid |
class | pw_class |
change | pw_change |
expire | pw_expire |
name | pw_gecos; the user’s full name |
home | pw_dir |
shell | pw_shell |
entry | struct passwd |
pw_passwd
let password = [ label "password" . sto_to_col? . colon ]
pw_uid
let uid = [ label "uid" . store integer . colon ]
pw_gid
let gid = [ label "gid" . store integer . colon ]
pw_class
let class = [ label "class" . sto_to_col? . colon ]
pw_change
let change_date = [ label "change_date" . store integer? . colon ]
pw_expire
let expire_date = [ label "expire_date" . store integer? . colon ]
pw_gecos; the user’s full name
let name = [ label "name" . sto_to_col? . colon ]
pw_dir
let home = [ label "home" . sto_to_col? . colon ]
pw_shell
let shell = [ label "shell" . sto_to_eol? ]
struct passwd
let entry = [ key username . colon . password . uid . gid . class . change_date . expire_date . name . home . shell . eol ]