kcred_setpag or kcred_setpag64 Kernel Service

Purpose

Copies a process authentication group ID into a credentials structure.

Syntax

#include <sys/cred.h>

int kcred_setpag ( crp, which, pag )
struct ucred * cr;
int which;
int pag;

int kcred_setpag64 ( crp, which, pag )
struct ucred * cr;
int which;
uint64 * pag;

Parameters

Item Description
crp Pointer to a credentials structure
which PAG ID to set
pag Process authentication group

Description

The kcred_setpag or kcred_setpag64 kernel service initializes the specified PAG in the credentials structure referenced by crp with pag. The value of which must be a defined PAG ID. The PAG ID for the Distributed Computing Environment (DCE) is 0. Crp must be a valid, referenced credentials structure. crp may be a reference to the current credentials of a process.

Execution Environment

The kcred_setpag or kcred_setpag64 kernel service can be called from the process environment only.

Return Values

Item Description
0 Success.
-1 An error has occurred.