umAddGroupGoAhead WebServer APIGoAhead EMF

Synopsis

Add a group to the User Management database in the group table.

Prototype

 #include "um.h" 


 int umAddGroup( char_t * group, 
     short privilege, 
     accessMeth_t am, 
     bool_t protect, 
     bool_t disabled);

Parameters

groupgroup name
privilegebit mask for privilege as noted below
amaccess method as noted below
protectdelete protection; value is TRUE if protected
disabledTRUE if group is disabled; FALSE if group is enabled

Description

Privileges are determined by bit-masking the following constants:
PRIV_NONE - user has no privileges
PRIV_READ - user can read files
PRIV_WRITE - user can execute CGIs
PRIV_ADMIN - user can administrate

Access method can be one of:
AM_NONE - Group has no access to anything
AM_FULL - Group has access to all pages; no authorization required
AM_BASIC - group requires at least basic authentication
AM_DIGEST - group requires at least digest authentication
AM_INVALID - not a valid access method

Return Value

umAddGroup returns 0 if successful or -1 on error.

Example

Int nCheck = umAddGroup(T("users"), 0x07, AM_DIGEST, TRUE, FALSE);

See Also

umDeleteGroup()