Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
dh.h
00001 /* dh.h for openSSL */ 00002 00003 00004 #ifndef CYASSL_DH_H_ 00005 #define CYASSL_DH_H_ 00006 00007 00008 #include <cyassl/openssl/ssl.h> 00009 #include <cyassl/openssl/bn.h> 00010 00011 00012 #ifdef __cplusplus 00013 extern "C" { 00014 #endif 00015 00016 00017 00018 00019 typedef struct CYASSL_DH { 00020 CYASSL_BIGNUM* p; 00021 CYASSL_BIGNUM* g; 00022 CYASSL_BIGNUM* pub_key; /* openssh deference g^x */ 00023 CYASSL_BIGNUM* priv_key; /* openssh deference x */ 00024 void* internal; /* our DH */ 00025 char inSet; /* internal set from external ? */ 00026 char exSet; /* external set from internal ? */ 00027 } CYASSL_DH; 00028 00029 00030 CYASSL_API CYASSL_DH* CyaSSL_DH_new(void); 00031 CYASSL_API void CyaSSL_DH_free(CYASSL_DH*); 00032 00033 CYASSL_API int CyaSSL_DH_size(CYASSL_DH*); 00034 CYASSL_API int CyaSSL_DH_generate_key(CYASSL_DH*); 00035 CYASSL_API int CyaSSL_DH_compute_key(unsigned char* key, CYASSL_BIGNUM* pub, 00036 CYASSL_DH*); 00037 00038 typedef CYASSL_DH DH; 00039 00040 #define DH_new CyaSSL_DH_new 00041 #define DH_free CyaSSL_DH_free 00042 00043 #define DH_size CyaSSL_DH_size 00044 #define DH_generate_key CyaSSL_DH_generate_key 00045 #define DH_compute_key CyaSSL_DH_compute_key 00046 00047 00048 #ifdef __cplusplus 00049 } /* extern "C" */ 00050 #endif 00051 00052 #endif /* header */
Generated on Tue Jul 12 2022 20:12:50 by
