Go to the documentation of this file.
57 #ifndef OPENSSL_HEADER_DH_H
58 #define OPENSSL_HEADER_DH_H
64 #if defined(__cplusplus)
111 const BIGNUM **out_priv_key);
150 #define DH_GENERATOR_2 2
151 #define DH_GENERATOR_5 5
213 #define DH_CHECK_P_NOT_PRIME 0x01
214 #define DH_CHECK_P_NOT_SAFE_PRIME 0x02
215 #define DH_CHECK_UNABLE_TO_CHECK_GENERATOR 0x04
216 #define DH_CHECK_NOT_SUITABLE_GENERATOR 0x08
217 #define DH_CHECK_Q_NOT_PRIME 0x10
218 #define DH_CHECK_INVALID_Q_VALUE 0x20
219 #define DH_CHECK_INVALID_J_VALUE 0x40
222 #define DH_NOT_SUITABLE_GENERATOR DH_CHECK_NOT_SUITABLE_GENERATOR
223 #define DH_UNABLE_TO_CHECK_GENERATOR DH_CHECK_UNABLE_TO_CHECK_GENERATOR
232 #define DH_CHECK_PUBKEY_TOO_SMALL 0x1
233 #define DH_CHECK_PUBKEY_TOO_LARGE 0x2
234 #define DH_CHECK_PUBKEY_INVALID 0x4
330 #if defined(__cplusplus)
346 #define DH_R_BAD_GENERATOR 100
347 #define DH_R_INVALID_PUBKEY 101
348 #define DH_R_MODULUS_TOO_LARGE 102
349 #define DH_R_NO_PRIVATE_VALUE 103
350 #define DH_R_DECODE_ERROR 104
351 #define DH_R_ENCODE_ERROR 105
353 #endif // OPENSSL_HEADER_DH_H
OPENSSL_EXPORT BIGNUM * BN_get_rfc3526_prime_1536(BIGNUM *ret)
CRYPTO_refcount_t references
const OPENSSL_EXPORT BIGNUM * DH_get0_p(const DH *dh)
OPENSSL_EXPORT int DH_compute_key_hashed(DH *dh, uint8_t *out, size_t *out_len, size_t max_out_len, const BIGNUM *peers_key, const EVP_MD *digest)
CRYPTO_MUTEX method_mont_p_lock
OPENSSL_EXPORT DH * DHparams_dup(const DH *dh)
OPENSSL_EXPORT void DH_free(DH *dh)
OPENSSL_EXPORT int DH_size(const DH *dh)
#define BORINGSSL_MAKE_UP_REF(type, up_ref_func)
OPENSSL_EXPORT DH * DH_parse_parameters(CBS *cbs)
OPENSSL_EXPORT int DH_marshal_parameters(CBB *cbb, const DH *dh)
OPENSSL_EXPORT int DH_generate_parameters_ex(DH *dh, int prime_bits, int generator, BN_GENCB *cb)
OPENSSL_EXPORT int DH_set0_pqg(DH *dh, BIGNUM *p, BIGNUM *q, BIGNUM *g)
OPENSSL_EXPORT int DH_set_length(DH *dh, unsigned priv_length)
OPENSSL_EXPORT int DH_check(const DH *dh, int *out_flags)
OPENSSL_EXPORT unsigned DH_num_bits(const DH *dh)
#define BSSL_NAMESPACE_END
OPENSSL_EXPORT DH * DH_get_rfc7919_2048(void)
static void callback(void *arg, int status, int timeouts, struct hostent *host)
OPENSSL_EXPORT int DH_up_ref(DH *dh)
OPENSSL_EXPORT int DH_set0_key(DH *dh, BIGNUM *pub_key, BIGNUM *priv_key)
OPENSSL_EXPORT void DH_get0_key(const DH *dh, const BIGNUM **out_pub_key, const BIGNUM **out_priv_key)
OPENSSL_EXPORT int DH_compute_key_padded(uint8_t *out, const BIGNUM *peers_key, DH *dh)
const OPENSSL_EXPORT BIGNUM * DH_get0_pub_key(const DH *dh)
BN_MONT_CTX * method_mont_p
OPENSSL_EXPORT int DH_compute_key(uint8_t *out, const BIGNUM *peers_key, DH *dh)
UniquePtr< SSL_SESSION > ret
OPENSSL_EXPORT void DH_get0_pqg(const DH *dh, const BIGNUM **out_p, const BIGNUM **out_q, const BIGNUM **out_g)
OPENSSL_EXPORT DH * DH_new(void)
OPENSSL_EXPORT int DH_check_pub_key(const DH *dh, const BIGNUM *pub_key, int *out_flags)
#define BORINGSSL_MAKE_DELETER(type, deleter)
OPENSSL_EXPORT DH * d2i_DHparams(DH **ret, const unsigned char **inp, long len)
const OPENSSL_EXPORT BIGNUM * DH_get0_priv_key(const DH *dh)
const OPENSSL_EXPORT BIGNUM * DH_get0_q(const DH *dh)
OPENSSL_EXPORT int i2d_DHparams(const DH *in, unsigned char **outp)
const OPENSSL_EXPORT BIGNUM * DH_get0_g(const DH *dh)
OPENSSL_EXPORT int DH_generate_key(DH *dh)
uint32_t CRYPTO_refcount_t
OPENSSL_EXPORT DH * DH_generate_parameters(int prime_len, int generator, void(*callback)(int, int, void *), void *cb_arg)
OPENSSL_EXPORT pem_password_cb * cb
grpc
Author(s):
autogenerated on Thu Mar 13 2025 02:59:12