HP Open Source Security for OpenVMS Volume 3: Kerberos > Chapter 6 KRB5 (Kerberos V5) Application Programming Interface

krb5_copy_creds — Copy a credentials structure

 » Table of Contents

 » Glossary

 » Index

C Prototype

krb5_error_code krb5_copy_creds(
krb5_context context,
const krb5_creds *incred,
krb5_creds **outcred );

Arguments

context (input/output) 

The context structure.

incred (input)  

The credentials structure to be copied.

outcred (output)  

A pointer to a copy of the credentials structure.

Description

This routine copies a credentials structure, filling in *outcred to point to the newly allocated copy, which should be freed with krb5_free_creds.

Return Values

This routine returns the following KRB5 status code:

0

Successful completion.
ENOMEMInsufficient memory.