1 | =pod
|
---|
2 |
|
---|
3 | =head1 NAME
|
---|
4 |
|
---|
5 | OSSL_DISPATCH, OSSL_DISPATCH_END - OpenSSL Core type to define a dispatchable function table
|
---|
6 |
|
---|
7 | =head1 SYNOPSIS
|
---|
8 |
|
---|
9 | #include <openssl/core.h>
|
---|
10 |
|
---|
11 | typedef struct ossl_dispatch_st OSSL_DISPATCH;
|
---|
12 | struct ossl_dispatch_st {
|
---|
13 | int function_id;
|
---|
14 | void (*function)(void);
|
---|
15 | };
|
---|
16 |
|
---|
17 | #define OSSL_DISPATCH_END
|
---|
18 |
|
---|
19 | =head1 DESCRIPTION
|
---|
20 |
|
---|
21 | This type is a tuple of function identity and function pointer.
|
---|
22 | Arrays of this type are passed between the OpenSSL libraries and the
|
---|
23 | providers to describe what functionality one side provides to the other.
|
---|
24 |
|
---|
25 | Arrays of this type must be terminated with the OSSL_DISPATCH_END macro.
|
---|
26 |
|
---|
27 | =head2 B<OSSL_DISPATCH> fields
|
---|
28 |
|
---|
29 | =over 4
|
---|
30 |
|
---|
31 | =item I<function_id>
|
---|
32 |
|
---|
33 | OpenSSL defined function identity of the implemented function.
|
---|
34 |
|
---|
35 | =item I<function>
|
---|
36 |
|
---|
37 | Pointer to the implemented function itself. Despite the generic definition
|
---|
38 | of this field, the implemented function it points to must have a function
|
---|
39 | signature that corresponds to the I<function_id>
|
---|
40 |
|
---|
41 | =back
|
---|
42 |
|
---|
43 | Available function identities and corresponding function signatures are
|
---|
44 | defined in L<openssl-core_dispatch.h(7)>.
|
---|
45 | Furthermore, the chosen function identities and associated function
|
---|
46 | signature must be chosen specifically for the operation that it's intended
|
---|
47 | for, as determined by the intended L<OSSL_ALGORITHM(3)> array.
|
---|
48 |
|
---|
49 | Any function identity not recognised by the recipient of this type
|
---|
50 | will be ignored.
|
---|
51 | This ensures that providers built with one OpenSSL version in mind
|
---|
52 | will work together with any other OpenSSL version that supports this
|
---|
53 | mechanism.
|
---|
54 |
|
---|
55 | =begin comment RETURN VALUES doesn't make sense for a manual that only
|
---|
56 | describes a type, but document checkers still want that section, and
|
---|
57 | to have more than just the section title.
|
---|
58 |
|
---|
59 | =head1 RETURN VALUES
|
---|
60 |
|
---|
61 | txt
|
---|
62 |
|
---|
63 | =end comment
|
---|
64 |
|
---|
65 | =head1 SEE ALSO
|
---|
66 |
|
---|
67 | L<crypto(7)>, L<openssl-core_dispatch.h(7)>, L<OSSL_ALGORITHM(3)>
|
---|
68 |
|
---|
69 | =head1 HISTORY
|
---|
70 |
|
---|
71 | B<OSSL_DISPATCH> was added in OpenSSL 3.0.
|
---|
72 |
|
---|
73 | =head1 COPYRIGHT
|
---|
74 |
|
---|
75 | Copyright 2022-2023 The OpenSSL Project Authors. All Rights Reserved.
|
---|
76 |
|
---|
77 | Licensed under the Apache License 2.0 (the "License"). You may not use
|
---|
78 | this file except in compliance with the License. You can obtain a copy
|
---|
79 | in the file LICENSE in the source distribution or at
|
---|
80 | L<https://www.openssl.org/source/license.html>.
|
---|
81 |
|
---|
82 | =cut
|
---|