2020-01-23 20:33:28 +10: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
|
|
|
|
*/
|
|
|
|
|
2020-03-23 05:40:47 +01:00
|
|
|
#include <openssl/core.h>
|
2020-01-23 20:33:28 +10:00
|
|
|
#include <openssl/dh.h>
|
2020-01-24 14:09:33 +10:00
|
|
|
#include "internal/ffc.h"
|
2020-01-23 20:33:28 +10:00
|
|
|
|
2020-02-16 13:03:46 +10:00
|
|
|
DH *dh_new_with_ctx(OPENSSL_CTX *libctx);
|
|
|
|
|
|
|
|
int dh_generate_ffc_parameters(DH *dh, int bits,
|
2020-02-06 22:28:36 +10:00
|
|
|
int qbits, int gindex, BN_GENCB *cb);
|
2020-02-16 13:03:46 +10:00
|
|
|
int dh_generate_public_key(BN_CTX *ctx, DH *dh, const BIGNUM *priv_key,
|
|
|
|
BIGNUM *pub_key);
|
2020-02-06 22:28:36 +10:00
|
|
|
|
2020-01-24 14:09:33 +10:00
|
|
|
FFC_PARAMS *dh_get0_params(DH *dh);
|
2020-01-31 08:18:46 +10:00
|
|
|
int dh_get0_nid(const DH *dh);
|
2020-03-23 05:40:47 +01:00
|
|
|
int dh_key_fromdata(DH *dh, const OSSL_PARAM params[]);
|
2020-02-16 13:03:46 +10:00
|
|
|
|
|
|
|
int dh_check_pub_key_partial(const DH *dh, const BIGNUM *pub_key, int *ret);
|
|
|
|
int dh_check_priv_key(const DH *dh, const BIGNUM *priv_key, int *ret);
|
|
|
|
int dh_check_pairwise(DH *dh);
|
2020-02-29 08:57:34 +01:00
|
|
|
|
|
|
|
const DH_METHOD *dh_get_method(const DH *dh);
|