Module posix.grp

Group Database Operations.

Query the system group database.

Functions

endgrent () Release group database resources.
getgrent () Fetch next group.
getgrgid (gid) Fetch group with given group id.
getgrnam (name) Fetch named group.
setgrent () Rewind next getgrent back to start of database.

Tables

PosixGroup Group record.


Functions

endgrent ()
Release group database resources.

See also:

getgrent ()
Fetch next group.

Returns:

    PosixGroup next group record

See also:

Usage:

      t = P.getgrent ()
      while t ~= nil do
        process (t)
        t = P.getgrent ()
      end
      P.endgrent ()
getgrgid (gid)
Fetch group with given group id.

Parameters:

  • gid int group id

Returns:

    PosixGroup group record for gid

Usage:

    t = P.getgrgid (0)
getgrnam (name)
Fetch named group.

Parameters:

Returns:

    PosixGroup group record for name

Usage:

    t = P.getgrnam "wheel"
setgrent ()
Rewind next getgrent back to start of database.

See also:

Tables

PosixGroup
Group record.

Fields:

  • gr_mem list a list of group members
  • gr_name string name of group
  • gr_gid int unique group id
generated by LDoc 1.4.3 Last updated 2015-01-04 12:06:34