MQZ_AUTHENTICATE_USER call, authenticate user call, QMgrName parameter, SecurityParms parameter, ApplicationContext parameter, IdentityContext parameter, CorrelationPtr parameter, ComponentData parameter, Continuation parameter, CompCode parameter, Reason parameter" /> MQZ_AUTHENTICATE_USER - Authenticate user

 

MQZ_AUTHENTICATE_USER - Authenticate user

This function is provided by a MQZAS_VERSION_5 authorization service component, and is invoked by the queue manager to authenticate a user, or to set identity context fields. It is invoked when WebSphere MQ's user application context is established. This happens during connect calls at the point where the application's user context is initialized, and at each point where the application's user context is changed. Each time a connect call is made, the application's user context information is reacquired in the IdentityContext field.

The function identifier for this function (for MQZEP) is MQZID_AUTHENTICATE_USER.

 

Syntax

MQZ_AUTHENTICATE_USER (QMgrName, SecurityParms, ApplicationContext,

IdentityContext, CorrelationPtr, ComponentData, Continuation, CompCode, Reason)

 

Parameters

The MQZ_AUTHENTICATE_USER call has the following parameters.

QMgrName (MQCHAR48) - input

Queue manager name.

The name of the queue manager calling the component. This name is padded with blanks to the full length of the parameter; the name is not terminated by a null character.

The queue-manager name is passed to the component for information; the authorization service interface does not require the component to make use of it in any defined manner.

SecurityParms (MQCSP) - input

Security parameters.

Data relating to the user ID, password, and authentication type. If the AuthenticationType attribute of the MQCSP structure is specified as MQCSP_AUTH_USER_ID_AND_PWD, both the user ID and password are compared against the equivalent fields in the IdentityContext (MQZIC) parameter to determine whether they match. For more information, see the WebSphere MQ Application Programming Reference.

During an MQCONN MQI call this parameter contains null, or default values.

ApplicationContext (MQZAC) - input

Application context.

Data relating to the calling application. See MQZAC - Application context for details.

During every MQCONN or MQCONNX MQI call, the user context information in the MQZAC structure is reacquired.

IdentityContext (MQZIC) - input/output

Identity context.

On input to the authenticate user function, this identifies the current identity context. The authenticate user function can change this, at which point the queue manager adopts the new identity context. See MQZIC - Identity context for more details on the MQZIC structure.

CorrelationPtr (MQPTR) - output

Correlation pointer.

Specifies the address of any correlation data. This pointer is subsequently passed on to other OAM calls.

ComponentData (MQBYTE×ComponentDataLength) - input/output

Component data.

This data is kept by the queue manager on behalf of this particular component; any changes made to it by any of the functions provided by this component are preserved, and presented the next time one of this component's functions is called.

The length of this data area is passed by the queue manager in the ComponentDataLength parameter of the MQZ_INIT_AUTHORITY call.

Continuation (MQLONG) - output

Continuation flag.

The following values can be specified:

MQZCI_DEFAULT

Continuation dependent on other components.

MQZCI_STOP

Do not continue with next component.
CompCode (MQLONG) - output

Completion code.

It is one of the following:

MQCC_OK

Successful completion.

MQCC_FAILED

Call failed.
Reason (MQLONG) - output

Reason code qualifying CompCode.

If CompCode is MQCC_OK:

MQRC_NONE

(0, X'000') No reason to report.

If CompCode is MQCC_FAILED:

MQRC_SERVICE_ERROR

(2289, X'8F1') Unexpected error occurred accessing service.

 

C invocation

MQZ_AUTHENTICATE_USER (QMgrName, SecurityParms, ApplicationContext,
                   IdentityContext, &CorrelationPtr, ComponentData,
                   &Continuation, &CompCode, &Reason);

The parameters passed to the service are declared as follows:

MQCHAR48  QMgrName;           /* Queue manager name */
MQCSP     SecurityParms;      /* Security parameters */
MQZAC     ApplicationContext; /* Application context */
MQZIC     IdentityContext;    /* Identity context */
MQPTR     CorrelationPtr;     /* Correlation pointer */
MQBYTE    ComponentData[n];   /* Component data */
MQLONG    Continuation;       /* Continuation indicator set by
                                 component */
MQLONG    CompCode;           /* Completion code */
MQLONG    Reason;             /* Reason code qualifying CompCode */