2020-08-02 18:46:00 +08:00
|
|
|
/*
|
|
|
|
* Copyright 2020 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
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef OSSL_CRYPTO_DECODER_H
|
|
|
|
# define OSSL_CRYPTO_DECODER_H
|
|
|
|
|
|
|
|
# include <openssl/decoder.h>
|
|
|
|
|
2020-10-15 17:55:50 +08:00
|
|
|
OSSL_DECODER *ossl_decoder_fetch_by_number(OSSL_LIB_CTX *libctx,
|
2020-08-02 18:46:00 +08:00
|
|
|
int id,
|
|
|
|
const char *properties);
|
|
|
|
|
|
|
|
/*
|
|
|
|
* These are specially made for the 'file:' provider-native loader, which
|
|
|
|
* uses this to install a DER to anything decoder, which doesn't do much
|
|
|
|
* except read a DER blob and pass it on as a provider object abstraction
|
|
|
|
* (provider-object(7)).
|
|
|
|
*/
|
|
|
|
void *ossl_decoder_from_dispatch(int id, const OSSL_ALGORITHM *algodef,
|
|
|
|
OSSL_PROVIDER *prov);
|
|
|
|
|
|
|
|
OSSL_DECODER_INSTANCE *
|
|
|
|
ossl_decoder_instance_new(OSSL_DECODER *decoder, void *decoderctx);
|
|
|
|
void ossl_decoder_instance_free(OSSL_DECODER_INSTANCE *decoder_inst);
|
|
|
|
int ossl_decoder_ctx_add_decoder_inst(OSSL_DECODER_CTX *ctx,
|
|
|
|
OSSL_DECODER_INSTANCE *di);
|
|
|
|
|
|
|
|
int ossl_decoder_ctx_setup_for_EVP_PKEY(OSSL_DECODER_CTX *ctx,
|
2020-10-02 20:21:51 +08:00
|
|
|
EVP_PKEY **pkey, const char *keytype,
|
2020-10-15 17:55:50 +08:00
|
|
|
OSSL_LIB_CTX *libctx,
|
2020-08-02 18:46:00 +08:00
|
|
|
const char *propquery);
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|