|
System.Posix.User | Portability | non-portable (requires POSIX) | Stability | provisional | Maintainer | libraries@haskell.org |
|
|
|
|
|
Description |
POSIX user/group support
|
|
Synopsis |
|
|
|
|
User environment
|
|
Querying the user environment
|
|
|
getRealUserID calls getuid to obtain the real UserID
associated with the current process.
|
|
|
getRealGroupID calls getgid to obtain the real GroupID
associated with the current process.
|
|
|
getEffectiveUserID calls geteuid to obtain the effective
UserID associated with the current process.
|
|
|
getEffectiveGroupID calls getegid to obtain the effective
GroupID associated with the current process.
|
|
|
getGroups calls getgroups to obtain the list of
supplementary GroupIDs associated with the current process.
|
|
|
getLoginName calls getlogin to obtain the login name
associated with the current process.
|
|
|
getEffectiveUserName gets the name
associated with the effective UserID of the process.
|
|
The group database
|
|
|
Constructors | GroupEntry | | groupName :: String | The name of this group (gr_name)
| groupPassword :: String | The password for this group (gr_passwd)
| groupID :: GroupID | The unique numeric ID for this group (gr_gid)
| groupMembers :: [String] | A list of zero or more usernames that are members (gr_mem)
|
|
| Instances | |
|
|
|
getGroupEntryForID gid calls getgrgid to obtain
the GroupEntry information associated with GroupID
gid.
|
|
|
getGroupEntryForName name calls getgrnam to obtain
the GroupEntry information associated with the group called
name.
|
|
|
getAllGroupEntries returns all group entries on the system by
repeatedly calling getgrent
|
|
The user database
|
|
|
Constructors | UserEntry | | userName :: String | Textual name of this user (pw_name)
| userPassword :: String | Password -- may be empty or fake if shadow is in use (pw_passwd)
| userID :: UserID | Numeric ID for this user (pw_uid)
| userGroupID :: GroupID | Primary group ID (pw_gid)
| userGecos :: String | Usually the real name for the user (pw_gecos)
| homeDirectory :: String | Home directory (pw_dir)
| userShell :: String | Default shell (pw_shell)
|
|
| Instances | |
|
|
|
getUserEntryForID gid calls getpwuid to obtain
the UserEntry information associated with UserID
uid.
|
|
|
getUserEntryForName name calls getpwnam to obtain
the UserEntry information associated with the user login
name.
|
|
|
getAllUserEntries returns all user entries on the system by
repeatedly calling getpwent
|
|
Modifying the user environment
|
|
|
setUserID uid calls setuid to set the real, effective, and
saved set-user-id associated with the current process to uid.
|
|
|
setGroupID gid calls setgid to set the real, effective, and
saved set-group-id associated with the current process to gid.
|
|
Produced by Haddock version 2.4.2 |