11#include <botan/data_src.h>
12#include <botan/exceptn.h>
13#include <botan/pk_keys.h>
14#include <botan/secmem.h>
23class RandomNumberGenerator;
68 std::string_view pass,
69 std::chrono::milliseconds msec = std::chrono::milliseconds(300),
70 std::string_view pbe_algo = "");
87 std::string_view pass,
88 std::chrono::milliseconds msec = std::chrono::milliseconds(300),
89 std::string_view pbe_algo = "");
107 std::string_view pass,
109 std::string_view cipher = "",
110 std::string_view pbkdf_hash = "");
129 std::string_view pass,
131 std::string_view cipher = "",
132 std::string_view pbkdf_hash = "");
151 std::string_view pass,
152 std::chrono::milliseconds pbkdf_msec,
153 size_t* pbkdf_iterations,
154 std::string_view cipher = "",
155 std::string_view pbkdf_hash = "");
176 std::string_view pass,
177 std::chrono::milliseconds pbkdf_msec,
178 size_t* pbkdf_iterations,
179 std::string_view cipher = "",
180 std::string_view pbkdf_hash = "");
214 const std::function<std::
string()>& get_passphrase);
222std::unique_ptr<
Private_Key>
load_key(std::span<const uint8_t> source, std::string_view pass);
PKCS8_Exception(std::string_view error)
secure_vector< uint8_t > private_key_info() const
int(* final)(unsigned char *, CTX *)
#define BOTAN_PUBLIC_API(maj, min)
std::vector< uint8_t > BER_encode(const Private_Key &key, RandomNumberGenerator &rng, std::string_view pass, std::chrono::milliseconds msec, std::string_view pbe_algo)
std::unique_ptr< Private_Key > copy_key(const Private_Key &key)
std::string PEM_encode_encrypted_pbkdf_iter(const Private_Key &key, RandomNumberGenerator &rng, std::string_view pass, size_t pbkdf_iterations, std::string_view cipher, std::string_view pbkdf_hash)
std::string PEM_encode(const Private_Key &key)
std::string PEM_encode_encrypted_pbkdf_msec(const Private_Key &key, RandomNumberGenerator &rng, std::string_view pass, std::chrono::milliseconds pbkdf_msec, size_t *pbkdf_iterations, std::string_view cipher, std::string_view pbkdf_hash)
std::vector< uint8_t > BER_encode_encrypted_pbkdf_iter(const Private_Key &key, RandomNumberGenerator &rng, std::string_view pass, size_t pbkdf_iterations, std::string_view cipher, std::string_view pbkdf_hash)
std::vector< uint8_t > BER_encode_encrypted_pbkdf_msec(const Private_Key &key, RandomNumberGenerator &rng, std::string_view pass, std::chrono::milliseconds pbkdf_msec, size_t *pbkdf_iterations, std::string_view cipher, std::string_view pbkdf_hash)
std::unique_ptr< Private_Key > load_key(DataSource &source, const std::function< std::string()> &get_pass)
std::vector< T, secure_allocator< T > > secure_vector