source: UsbWattMeter/trunk/wolfssl-3.7.0/wolfssl/openssl/dsa.h@ 164

Last change on this file since 164 was 164, checked in by coas-nagasima, 6 years ago

TOPPERS/ECNLサンプルアプリ「USB充電器電力計」を追加

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
  • Property svn:mime-type set to text/x-chdr
File size: 1.6 KB
Line 
1/* dsa.h for openSSL */
2
3
4#ifndef WOLFSSL_DSA_H_
5#define WOLFSSL_DSA_H_
6
7#include <wolfssl/openssl/ssl.h>
8#include <wolfssl/openssl/bn.h>
9
10#ifdef __cplusplus
11 extern "C" {
12#endif
13
14struct WOLFSSL_DSA {
15 WOLFSSL_BIGNUM* p;
16 WOLFSSL_BIGNUM* q;
17 WOLFSSL_BIGNUM* g;
18 WOLFSSL_BIGNUM* pub_key; /* our y */
19 WOLFSSL_BIGNUM* priv_key; /* our x */
20 void* internal; /* our Dsa Key */
21 char inSet; /* internal set from external ? */
22 char exSet; /* external set from internal ? */
23};
24
25
26WOLFSSL_API WOLFSSL_DSA* wolfSSL_DSA_new(void);
27WOLFSSL_API void wolfSSL_DSA_free(WOLFSSL_DSA*);
28
29WOLFSSL_API int wolfSSL_DSA_generate_key(WOLFSSL_DSA*);
30WOLFSSL_API int wolfSSL_DSA_generate_parameters_ex(WOLFSSL_DSA*, int bits,
31 unsigned char* seed, int seedLen, int* counterRet,
32 unsigned long* hRet, void* cb);
33
34WOLFSSL_API int wolfSSL_DSA_LoadDer(WOLFSSL_DSA*, const unsigned char*, int sz);
35
36WOLFSSL_API int wolfSSL_DSA_do_sign(const unsigned char* d,
37 unsigned char* sigRet, WOLFSSL_DSA* dsa);
38
39WOLFSSL_API int wolfSSL_DSA_do_verify(const unsigned char* d,
40 unsigned char* sig,
41 WOLFSSL_DSA* dsa, int *dsacheck);
42
43#define DSA_new wolfSSL_DSA_new
44#define DSA_free wolfSSL_DSA_free
45
46#define DSA_generate_key wolfSSL_DSA_generate_key
47#define DSA_generate_parameters_ex wolfSSL_DSA_generate_parameters_ex
48
49
50#ifdef __cplusplus
51 } /* extern "C" */
52#endif
53
54#endif /* header */
Note: See TracBrowser for help on using the repository browser.