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