HP Open Source Security for OpenVMS Volume 3: Kerberos > Chapter 5 GSSAPI (Generic Security Services Application Programming Interface)

gss_process_context_token — Pass a security context to the security service

  Table of Contents

  Glossary

  Index

C Prototype

OM_uint32 gss_process_context_token(
OM_uint32 * minor_status,
gss_ctx_id_t context_handle,
gss_buffer_t token_buffer );

Arguments

minor_status (output) 

An implementation-specific status code.

context_handle (input) 

The context handle of the context on which the token is to be processed.

token_buffer (input) 

A pointer to the token to process.

Description

This routine provides a way to pass an asynchronous token to the security service. Most context-level tokens are emitted and processed synchronously by gss_init_sec_context and gss_accept_sec_context, and the application is informed as to whether further tokens are expected by the GSS_C_CONTINUE_NEEDED status return. Occasionally, a mechanism may need to emit a context-level token at a point when the peer entity is not expecting a token. For example, the initiator's final call to gss_init_sec_context may emit a token and return a status of GSS_S_COMPLETE, but the acceptor's call to gss_accept_sec_context may fail. The acceptor's mechanism may wish to send a token containing an error indication to the initiator, but the initiator is not expecting a token at this point, believing that the context is fully established. The gss_process_context_token routine provides a way to pass such a token to the mechanism at any time.

Return Values

This routine returns one of the following GSS status codes:

GSS_S_COMPLETE

Successful completion.
GSS_S_DEFECTIVE_TOKENIndicates that consistency checks performed on the token failed.

GSS_S_FAILURE

Failure. See minor_status for more information.

GSS_S_NO_CONTEXT

The context_handle did not refer to a valid context.