1 .TH "hx509 printing functions" 3 "11 Jan 2012" "Version 1.5.2" "Heimdalx509library" \" -*- nroff -*-
5 hx509 printing functions \-
10 .RI "void \fBhx509_print_stdout\fP (void *ctx, const char *fmt, va_list va)"
13 .RI "int \fBhx509_oid_sprint\fP (const heim_oid *oid, char **str)"
16 .RI "void \fBhx509_oid_print\fP (const heim_oid *oid, hx509_vprint_func func, void *ctx)"
19 .RI "void \fBhx509_bitstring_print\fP (const heim_bit_string *b, hx509_vprint_func func, void *ctx)"
22 .RI "int \fBhx509_cert_keyusage_print\fP (hx509_context context, hx509_cert c, char **s)"
25 .RI "int \fBhx509_validate_ctx_init\fP (hx509_context context, hx509_validate_ctx *ctx)"
28 .RI "void \fBhx509_validate_ctx_set_print\fP (hx509_validate_ctx ctx, hx509_vprint_func func, void *c)"
31 .RI "void \fBhx509_validate_ctx_add_flags\fP (hx509_validate_ctx ctx, int flags)"
34 .RI "void \fBhx509_validate_ctx_free\fP (hx509_validate_ctx ctx)"
37 .RI "int \fBhx509_validate_cert\fP (hx509_context context, hx509_validate_ctx ctx, hx509_cert cert)"
40 .SH "Detailed Description"
43 .SH "Function Documentation"
45 .SS "void hx509_bitstring_print (const heim_bit_string * b, hx509_vprint_func func, void * ctx)"
47 Print a bitstring using a hx509_vprint_func function. To print to stdout use \fBhx509_print_stdout()\fP.
51 \fIb\fP bit string to print.
53 \fIfunc\fP hx509_vprint_func to print with.
55 \fIctx\fP context variable to hx509_vprint_func function.
59 .SS "int hx509_cert_keyusage_print (hx509_context context, hx509_cert c, char ** s)"
61 Print certificate usage for a certificate to a string.
65 \fIcontext\fP A hx509 context.
67 \fIc\fP a certificate print the keyusage for.
69 \fIs\fP the return string with the keysage printed in to, free with \fBhx509_xfree()\fP.
74 An hx509 error code, see \fBhx509_get_error_string()\fP.
78 .SS "void hx509_oid_print (const heim_oid * oid, hx509_vprint_func func, void * ctx)"
80 Print a oid using a hx509_vprint_func function. To print to stdout use \fBhx509_print_stdout()\fP.
84 \fIoid\fP oid to print
86 \fIfunc\fP hx509_vprint_func to print with.
88 \fIctx\fP context variable to hx509_vprint_func function.
92 .SS "int hx509_oid_sprint (const heim_oid * oid, char ** str)"
94 Print a oid to a string.
98 \fIoid\fP oid to print
100 \fIstr\fP allocated string, free with \fBhx509_xfree()\fP.
105 An hx509 error code, see \fBhx509_get_error_string()\fP.
109 .SS "void hx509_print_stdout (void * ctx, const char * fmt, va_list va)"
111 Helper function to print on stdout for:
113 \fBhx509_oid_print()\fP,
115 \fBhx509_bitstring_print()\fP,
117 \fBhx509_validate_ctx_set_print()\fP.
122 \fIctx\fP the context to the print function. If the ctx is NULL, stdout is used.
124 \fIfmt\fP the printing format.
126 \fIva\fP the argumet list.
130 .SS "int hx509_validate_cert (hx509_context context, hx509_validate_ctx ctx, hx509_cert cert)"
132 Validate/Print the status of the certificate.
136 \fIcontext\fP A hx509 context.
138 \fIctx\fP A hx509 validation context.
140 \fIcert\fP the cerificate to validate/print.
145 An hx509 error code, see \fBhx509_get_error_string()\fP.
149 .SS "void hx509_validate_ctx_add_flags (hx509_validate_ctx ctx, int flags)"
151 Add flags to control the behaivor of the \fBhx509_validate_cert()\fP function.
155 \fIctx\fP A hx509 validation context.
157 \fIflags\fP flags to add to the validation context.
162 An hx509 error code, see \fBhx509_get_error_string()\fP.
166 .SS "void hx509_validate_ctx_free (hx509_validate_ctx ctx)"
168 Free an hx509 validate context.
172 \fIctx\fP the hx509 validate context to free.
176 .SS "int hx509_validate_ctx_init (hx509_context context, hx509_validate_ctx * ctx)"
178 Allocate a hx509 validation/printing context.
182 \fIcontext\fP A hx509 context.
184 \fIctx\fP a new allocated hx509 validation context, free with \fBhx509_validate_ctx_free()\fP.
189 An hx509 error code, see \fBhx509_get_error_string()\fP.
193 .SS "void hx509_validate_ctx_set_print (hx509_validate_ctx ctx, hx509_vprint_func func, void * c)"
195 Set the printing functions for the validation context.
199 \fIctx\fP a hx509 valication context.
201 \fIfunc\fP the printing function to usea.
203 \fIc\fP the context variable to the printing function.
208 An hx509 error code, see \fBhx509_get_error_string()\fP.