]>
Commit | Line | Data |
---|---|---|
fcc25beb DDO |
1 | =pod |
2 | ||
3 | =head1 NAME | |
4 | ||
5 | ossl_cmp_bodytype_to_string, | |
6 | ossl_cmp_msg_get_bodytype, | |
7 | ossl_cmp_msg_set_bodytype, | |
8 | ossl_cmp_msg_create, | |
9 | ossl_cmp_msg_load, | |
10 | ossl_cmp_msg_gen_ITAV_push0, | |
11 | ossl_cmp_msg_gen_ITAVs_push1 | |
12 | - functions manipulating CMP messages | |
13 | ||
14 | =head1 SYNOPSIS | |
15 | ||
16 | #include "cmp_int.h" | |
17 | ||
18 | const char *ossl_cmp_bodytype_to_string(int type); | |
19 | int ossl_cmp_msg_get_bodytype(const OSSL_CMP_MSG *msg); | |
20 | int ossl_cmp_msg_set_bodytype( OSSL_CMP_MSG *msg, int type); | |
21 | OSSL_CMP_MSG *ossl_cmp_msg_create(OSSL_CMP_CTX *ctx, int bodytype); | |
22 | OSSL_CMP_MSG *ossl_cmp_msg_load(const char *file); | |
23 | int ossl_cmp_msg_gen_ITAV_push0(OSSL_CMP_MSG *msg, OSSL_CMP_ITAV *itav); | |
24 | int ossl_cmp_msg_gen_ITAVs_push1(OSSL_CMP_MSG *msg, | |
25 | STACK_OF(OSSL_CMP_ITAV) *itavs); | |
26 | ||
27 | =head1 DESCRIPTION | |
28 | ||
29 | ossl_cmp_bodytype_to_string() returns the name of the given body type as string, | |
30 | or "illegal body type" on error. | |
31 | ||
32 | ossl_cmp_msg_get_bodytype() returns the body type of the given PKIMessage, | |
33 | or -1 on error. | |
34 | ||
35 | ossl_cmp_msg_set_bodytype() sets the type of the message contained in | |
36 | the PKIMessage body field. | |
37 | Returns 1 on success, 0 on error. | |
38 | ||
39 | ossl_cmp_msg_create() creates and initializes a OSSL_CMP_MSG structure, | |
40 | using B<ctx> for the header and B<bodytype> for the body. | |
41 | Returns pointer to created OSSL_CMP_MSG on success, NULL on error. | |
42 | ||
43 | OSSL_CMP_MSG *ossl_cmp_msg_load() loads a OSSL_CMP_MSG from a B<file>. | |
44 | Returns pointer to created OSSL_CMP_MSG on success, NULL on error. | |
45 | ||
46 | ossl_cmp_msg_gen_ITAV_push0() pushes the B<itav> to the body of the | |
47 | PKIMessage B<msg> of GenMsg or GenRep type. Consumes the B<itavs> pointer. | |
48 | Returns 1 on success, 0 on error. | |
49 | ||
50 | ossl_cmp_msg_gen_ITAVs_push1() adds a copy of the B<itavs> stack to the body | |
51 | of the PKIMessage B<msg> of GenMsg or GenRep type. | |
52 | Does not consume the B<itavs> pointer nor its elements. | |
53 | Returns 1 on success, 0 on error. | |
54 | ||
55 | =head1 NOTES | |
56 | ||
57 | CMP is defined in RFC 4210 (and CRMF in RFC 4211). | |
58 | ||
59 | =head1 RETURN VALUES | |
60 | ||
61 | See the individual functions above. | |
62 | ||
63 | =head1 SEE ALSO | |
64 | ||
7e765f46 | 65 | L<OSSL_CMP_CTX_new(3)>, L<OSSL_CMP_exec_IR_ses(3)> |
fcc25beb DDO |
66 | |
67 | =head1 HISTORY | |
68 | ||
69 | The OpenSSL CMP support was added in OpenSSL 3.0. | |
70 | ||
71 | =head1 COPYRIGHT | |
72 | ||
73 | Copyright 2007-2020 The OpenSSL Project Authors. All Rights Reserved. | |
74 | ||
75 | Licensed under the Apache License 2.0 (the "License"). You may not use | |
76 | this file except in compliance with the License. You can obtain a copy | |
77 | in the file LICENSE in the source distribution or at | |
78 | L<https://www.openssl.org/source/license.html>. | |
79 | ||
80 | =cut |