Function

gss_wrap

Returns a secure message created by calculating and attaching a MIC to the input message, and then optionally encrypting it.

Declaration

OM_uint32 gss_wrap(OM_uint32 *minor_status, gss_ctx_id_t context_handle, int conf_req_flag, gss_qop_t qop_req, gss_buffer_t input_message_buffer, int *conf_state, gss_buffer_t output_message_buffer);

Parameters

minor_status

A pointer to the secondary status result that provides additional information in case of failure.

context_handle

The context used to send the message.

conf_req_flag

A flag you set to zero to request that only that the message integrity check be applied, or to anything non-zero to request both integrity checking and confidentiality (encryption) of the message.

qop_req

The quality of protection requested for the encryption. See Quality of Protection Constants for valid values.

input_message_buffer

A buffer containing the message to protect.

conf_state

A pointer the function uses to indicate what protection is actually applied to the message. A value of zero indicates only integrity checking. A non-zero value indicates both integrity checking and confidentiality. Pass NULL to ignore this output.

output_message_buffer

A buffer the function fills with the fully wrapped message, ready for transport to the peer. Release the buffer using a call to gss_release_buffer when you are done with it.

Return Value

A status code set to GSS_S_COMPLETE on success. See Function Status for a complete enumeration of status outputs.

See Also

Message Wrapping and Verification

gss_get_mic

Returns a token that contains the MIC for a message.

gss_verify_mic

Returns an indication of whether the integrity of a message is intact, given its MIC token.

gss_unwrap

Returns the original version of a secure message by optionally decrypting it and then extracting and verifying the attached MIC.

gss_sign

Returns a digital signature for a message.

Deprecated
gss_verify

Returns a flag that indicates the integrity of a message’s digital signature.

Deprecated
gss_seal

Returns a secure message created by calculating and attaching a MIC to the input message, and then optionally encrypting it.

Deprecated
gss_unseal

Returns the original version of a secure message by optionally decrypting it and then extracting and verifying the attached MIC.

Deprecated