sec_rgy_unix_getgrgid-Returns a UNIX style group entry for the account matching the specified group ID
#include <dce/rgynbase.h>
void sec_rgy_unix_getgrgid(
sec_rgy_handle_t context,
signed32 gid,
signed32 max_number,
sec_rgy_cursor_t *item_cursor,
sec_rgy_unix_group_t *group_entry,
signed32 *number_members,
sec_rgy_member_t member_list[],
error_status_t *status);
Input
- context
An opaque handle bound to a registry server. Use sec_rgy_site_open() to acquire a bound handle.
- gid
A 32-bit integer specifying the group ID to match.
- max_number
The maximum number of members to be returned by the call. This must be no larger than the allocated size of the member_list array.
Input/Output
- item_cursor
An opaque pointer indicating a specific PGO item entry in the registry database. The sec_rgy_unix_getgrgid() routine returns the PGO item indicated by item_cursor, and advances the cursor to point to the next item in the database. When the end of the list of entries is reached, the routine returns sec_rgy_no_more_entries. Use sec_rgy_cursor_reset() to refresh the cursor.
Output
- group_entry
A UNIX style group entry structure returned with information about the account matching gid.
- number_members
An signed 32-bit integer containing the total number of member names returned in the member_list array.
- member_list[]
An array of character strings to receive the returned member names. The size allocated for the array is given by max_number. If this value is less than the total number of members in the membership list, multiple calls must be made to return all of the members.
- status
On successful completion, the routine returns error_status_ok. Otherwise, it returns an error.
The sec_rgy_unix_getgrgid() routine returns the next UNIX group structure that matches the input UNIX group ID. The structure is in the following form:The structure includes
typedef struct { sec_rgy_name_t name; signed32 gid; sec_rgy_member_buf_t members; } sec_rgy_unix_group_t;
- The name of the group.
- The group's UNIX ID.
- A string containing the names of the group members. This string is limited in size by the size of the sec_rgy_member_buf_t type defined in rgynbase.h.
The routine also returns an array of member names, limited in size by the number_members parameter.
This call is supplied in source code form.
- /usr/include/dce/rgynbase.idl
The idl file from which dce/rgynbase.h was derived.
- error_status_ok
The call was successful.
- sec_rgy_no_more_entries
The cursor is at the end of the list of entries.
- sec_rgy_server_unavailable
The DCE Registry Server is unavailable.
Contents | Next section | Index |