1KRB5_RD_ERROR(3) BSD Library Functions Manual KRB5_RD_ERROR(3)
2
4 krb5_rd_error, krb5_free_error, krb5_free_error_contents,
5 krb5_error_from_rd_error — parse, free and read error from KRB-ERROR mes‐
6 sage
7
9 Kerberos 5 Library (libkrb5, -lkrb5)
10
12 #include <krb5.h>
13
14 krb5_error_code
15 krb5_rd_error(krb5_context context, const krb5_data *msg,
16 KRB_ERROR *result);
17
18 void
19 krb5_free_error(krb5_context context, krb5_error *error);
20
21 void
22 krb5_free_error_contents(krb5_context context, krb5_error *error);
23
24 krb5_error_code
25 krb5_error_from_rd_error(krb5_context context, const krb5_error *error,
26 const krb5_creds *creds);
27
29 Usually applications never needs to parse and understand Kerberos error
30 messages since higher level functions will parse and push up the error in
31 the krb5_context. These functions are described for completeness.
32
33 krb5_rd_error() parses and returns the kerboeros error message, the
34 structure should be freed with krb5_free_error_contents() when the caller
35 is done with the structure.
36
37 krb5_free_error() frees the content and the memory region holding the
38 structure iself.
39
40 krb5_free_error_contents() free the content of the KRB-ERROR message.
41
42 krb5_error_from_rd_error() will parse the error message and set the error
43 buffer in krb5_context to the error string passed back or the matching
44 error code in the KRB-ERROR message. Caller should pick up the message
45 with krb5_get_error_string(3) (don't forget to free the returned string
46 with krb5_free_error_string()).
47
49 krb5(3), krb5_set_error_string(3), krb5_get_error_string(3), krb5.conf(5)
50
51HEIMDAL July 26, 2004 HEIMDAL