xref: /titanic_41/usr/src/common/net/wanboot/auxutil.h (revision 6f45ec7b0b964c3be967c4880e8867ac1e7763a5)
1 /*
2  * Copyright 2002, 2003 Sun Microsystems, Inc.  All rights reserved.
3  * Use is subject to license terms.
4  */
5 
6 #ifndef	_AUXUTIL_H
7 #define	_AUXUTIL_H
8 
9 #pragma ident	"%Z%%M%	%I%	%E% SMI"
10 
11 #ifdef	__cplusplus
12 extern "C" {
13 #endif
14 
15 #undef	NULL
16 #define	NULL ((void *) 0)
17 
18 ASN1_BMPSTRING *asc2bmpstring(const char *, int);
19 
20 uchar_t *utf82ascstr(ASN1_UTF8STRING *);
21 
22 int set_results(STACK_OF(EVP_PKEY) **, STACK_OF(EVP_PKEY) **, STACK_OF(X509) **,
23     STACK_OF(X509) **, STACK_OF(X509) **, STACK_OF(X509) **,
24     STACK_OF(EVP_PKEY) **, STACK_OF(EVP_PKEY) **);
25 
26 int find_attr(int, ASN1_STRING *, STACK_OF(EVP_PKEY) *, EVP_PKEY **,
27     STACK_OF(X509) *, X509 **);
28 
29 int find_attr_by_nid(STACK_OF(X509_ATTRIBUTE) *, int);
30 
31 int get_key_cert(int, STACK_OF(EVP_PKEY) *, EVP_PKEY **, STACK_OF(X509) *,
32     X509 **);
33 
34 X509_ATTRIBUTE *type2attrib(ASN1_TYPE *, int);
35 
36 ASN1_TYPE *attrib2type(X509_ATTRIBUTE *);
37 
38 int move_certs(STACK_OF(X509) *, STACK_OF(X509) *);
39 
40 int print_time(FILE *, ASN1_TIME *);
41 
42 
43 #ifdef	__cplusplus
44 }
45 #endif
46 
47 #endif	/* _AUXUTIL_H */
48