PROVIDER(7ossl)
πΈ PROVIDER(7ossl) πΈ β the OpenSSL manual page, but make it make sense
okay so bestie, this is PROVIDER(7ossl), the OpenSSL manual page all about providers β and before you ask, no, it's not about your fave music provider or your streaming subscriptions, it's about OpenSSL's operation implementation providers. Trust me, it's more interesting than it sounds π β¨
This page is literally for provider authors, so if you're writing one of these bad boys, this is your moment. Slay.
π SYNOPSIS π
#include <openssl/provider.h>
short and sweet, literally iconic, no notes π«Ά
π DESCRIPTION π
π« General π«
Bestie, first things first: this page contains information useful to provider authors. That's the whole target audience. If that's you, welcome, you're the main character now.
A provider, in OpenSSL terms, is a unit of code that provides one or more implementations for various operations for diverse algorithms that one might want to perform. It's giving "I contain multitudes" energy.
An operation is something one wants to do β like encryption and decryption, key derivation, MAC calculation, signing and verification, etc. Basically the verbs of cryptographic life.
An algorithm is a named method to perform an operation. Very often, the algorithms revolve around cryptographic operations, but they may also revolve around other types of operation, such as managing certain types of objects. Not everything is crypto, iykyk.
See crypto(7) for further details. go read it, it's the lore π
π¦ Provider π¦
A provider offers an initialization function, as a set of base functions in the form of an OSSL_DISPATCH(3) array, and by extension, a set of OSSL_ALGORITHM(3)s (see openssl-core.h(7)). It may be a dynamically loadable module, or may be built-in, in OpenSSL libraries or in the application. So it can either slide in at runtime or be born into the library. Both valid.
Here's the catch: if it's a dynamically loadable module, the initialization function must be named OSSL_provider_init and must be exported. No exceptions, periodt. If it's built-in, the initialization function may have any name. lucky them.
The initialization function must have the following signature:
int NAME(const OSSL_CORE_HANDLE *handle,
const OSSL_DISPATCH *in, const OSSL_DISPATCH **out,
void **provctx);
Let's break down these parameters like a group chat screenshot:
handleβ the OpenSSL library object for the provider, and it works as a handle for everything the OpenSSL libraries need to know about the provider. For the provider itself, it is passed to some of the functions given in the dispatch arrayin. It's like the provider's official ID card πͺͺinβ a dispatch array of base functions offered by the OpenSSL libraries, and the available functions are further described inprovider-base(7). This is the library saying "here's what I can do for you."*outβ must be assigned a dispatch array of base functions that the provider offers to the OpenSSL libraries. The functions that may be offered are further described inprovider-base(7), and they are the central means of communication between the OpenSSL libraries and the provider. This is the provider's "here's what I can do for you" moment. iconic.*provctxβ should be assigned a provider specific context to allow the provider multiple simultaneous uses. This pointer will be passed to various operation functions offered by the provider. It's the provider's personal little state corner π§
β οΈ important vibe check: note that the provider will not be made available for applications to use until the initialization function has completed and returned successfully. No half-baked entrances. Finish the init, then you can party.
One of the functions the provider offers to the OpenSSL libraries is the central mechanism for the OpenSSL libraries to get access to operation implementations for diverse algorithms. It's referred to with the number OSSL_FUNC_PROVIDER_QUERY_OPERATION and has the following signature:
const OSSL_ALGORITHM *provider_query_operation(void *provctx,
int operation_id,
const int *no_store);
provctxβ the provider specific context that was passed back by the initialization function. same context, different function, consistency queen πoperation_idβ an operation identity (see "Operations" below). You'll see the list, don't worry.no_storeβ a flag back to the OpenSSL libraries which, when nonzero, signifies that the OpenSSL libraries will not store a reference to the returned data in their internal store of implementations. Sono_storenonzero = no keepie, no storing, we're just browsing π
The returned OSSL_ALGORITHM(3) is the foundation of any OpenSSL library API that uses providers for their implementation, most commonly in the fetching type of functions (see "ALGORITHM FETCHING" in crypto(7)). This is the whole reason providers exist, bestie. The foundation. The blueprint. The moment.
π₯ Operations π₯
Operations are referred to with numbers, via macros with names starting with "OSSL_OP_". cute little numeric IDs, very demure.
With each operation comes a set of defined function types that a provider may or may not offer, depending on its needs. You don't have to offer everything β you're not obligated to be an overachiever.
Currently available operations are:
- Digests β In the OpenSSL libraries, the corresponding method object is
EVP_MD. The number for this operation isOSSL_OP_DIGEST. The functions the provider can offer are described inprovider-digest(7). π - Symmetric ciphers β In the OpenSSL libraries, the corresponding method object is
EVP_CIPHER. The number for this operation isOSSL_OP_CIPHER. The functions the provider can offer are described inprovider-cipher(7). π - Message Authentication Code (MAC) β In the OpenSSL libraries, the corresponding method object is
EVP_MAC. The number for this operation isOSSL_OP_MAC. The functions the provider can offer are described inprovider-mac(7). π¬ - Key Derivation Function (KDF) β In the OpenSSL libraries, the corresponding method object is
EVP_KDF. The number for this operation isOSSL_OP_KDF. The functions the provider can offer are described inprovider-kdf(7). π± - Key Exchange β In the OpenSSL libraries, the corresponding method object is
EVP_KEYEXCH. The number for this operation isOSSL_OP_KEYEXCH. The functions the provider can offer are described inprovider-keyexch(7). π€ - Asymmetric Ciphers β In the OpenSSL libraries, the corresponding method object is
EVP_ASYM_CIPHER. The number for this operation isOSSL_OP_ASYM_CIPHER. The functions the provider can offer are described inprovider-asym_cipher(7). ποΈ - Asymmetric Key Encapsulation β In the OpenSSL libraries, the corresponding method object is
EVP_KEM. The number for this operation isOSSL_OP_KEM. The functions the provider can offer are described inprovider-kem(7). π¦ - Encoding β In the OpenSSL libraries, the corresponding method object is
OSSL_ENCODER. The number for this operation isOSSL_OP_ENCODER. The functions the provider can offer are described inprovider-encoder(7). 𧬠- Decoding β In the OpenSSL libraries, the corresponding method object is
OSSL_DECODER. The number for this operation isOSSL_OP_DECODER. The functions the provider can offer are described inprovider-decoder(7). π§ͺ - Random Number Generation β The number for this operation is
OSSL_OP_RAND. The functions the provider can offer for random number generation are described inprovider-rand(7). π² (no method object listed here, and we're not making one up β accuracy queen) - Key Management β The number for this operation is
OSSL_OP_KEYMGMT. The functions the provider can offer for key management are described inprovider-keymgmt(7). π - Signing and Signature Verification β The number for this operation is
OSSL_OP_SIGNATURE. The functions the provider can offer for digital signatures are described inprovider-signature(7). βοΈ - Store Management β The number for this operation is
OSSL_OP_STORE. The functions the provider can offer for store management are described inprovider-storemgmt(7). ποΈ
π Algorithm naming π
Algorithm names are case insensitive. Any particular algorithm can have multiple aliases associated with it. The canonical OpenSSL naming scheme follows this format:
ALGNAME[VERSION?][-SUBNAME[VERSION?]?][-SIZE?][-MODE?]
Let's decode this bracket situation:
VERSIONβ is only present if there are multiple versions of an algorithm (e.g.MD2,MD4,MD5). It may be omitted if there is only one version. If there's only one, why label it, right? exactly.SUBNAMEβ may be present where multiple algorithms are combined together, e.g.MD5-SHA1. collaboration era π€SIZEβ is only present if multiple versions of an algorithm exist with different sizes (e.g.AES-128-CBC,AES-256-CBC). size matters, apparently πMODEβ is only present where applicable. no mode, no label. simple as that.
Other aliases may exist for example where standards bodies or common practice use alternative names or names that OpenSSL has used historically. so if you see a name that looks different, it might just be the historical alias. don't @ me.
π§ Provider dependencies π§
Providers may depend for their proper operation on the availability of (functionality implemented in) other providers. As there is no mechanism to express such dependencies towards the OpenSSL core, provider authors must take care that such dependencies are either completely avoided or made visible to users, e.g., by documentation and/or defensive programming, e.g., outputting error messages if required external dependencies are not available, e.g., when no provider implementing the required functionality has been activated. In particular, provider initialization should not depend on other providers already having been initialized.
Read that again, bestie. No indirect codependency allowed. The core does not know about your provider's situationship with other providers π© communicate it yourself or avoid it entirely.
π Note on naming clashes π
It is possible to register the same algorithm name from within different providers. Users should note that if no property query is specified, or more than one implementation matches the property query then it is unspecified which implementation of a particular algorithm will be returned. unspecified! which means we literally cannot tell you which one you'll get. dramatic, but that's the truth.
Such naming clashes may also occur if algorithms only differ in capitalization as "Algorithm naming" is case insensitive. so AES and aes are the same name for clash purposes. case insensitive means case insensitive, no cap.
π OPENSSL PROVIDERS π
OpenSSL provides a number of its own providers. These are the default, base, fips, legacy and null providers. Five icons, five vibes. See crypto(7) for an overview of these providers. the lore continues there.
π«Ά SEE ALSO π«Ά
EVP_DigestInit_ex(3), EVP_EncryptInit_ex(3), OSSL_LIB_CTX(3), EVP_set_default_properties(3), EVP_MD_fetch(3), EVP_CIPHER_fetch(3), EVP_KEYMGMT_fetch(3), openssl-core.h(7), provider-base(7), provider-digest(7), provider-cipher(7), provider-keyexch(7)
all the friends of this page, go say hi π
β HISTORY β
The concept of providers and everything surrounding them was introduced in OpenSSL 3.0. so if you're on 1.1.1, this whole page is not your era yet, sorry bestie.
π COPYRIGHT π
Copyright 2019-2022 The OpenSSL Project Authors. All Rights Reserved.
Licensed under the Apache License 2.0 (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <https://www.openssl.org/source/license.html>.
like and subscribe, but legally binding πβ¨
okay that's the whole page, you're officially a provider understander now π
Version 3.5.0 β dated 2026-09-25 β page PROVIDER(7ossl)
mwah, go write a provider, bestie πΈπ¦
π¦ where this page comes from
- opensuse-leap 16.0: openssl-3 3.5.0-160000.11.1 Β· Apache-2.0
- opensuse-leap 16.0: openssl-3 3.5.0-160000.11.1 Β· Apache-2.0
- opensuse-leap 16.0: openssl-3 3.5.0-160000.11.1 Β· Apache-2.0
- opensuse-leap 16.0: openssl-3 3.5.0-160000.11.1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms