mirror of
https://github.com/guanzhi/GmSSL.git
synced 2026-06-17 18:33:39 +08:00
sm2 test vector
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
/* crypto/sm2/sm2_locl.h */
|
||||
/* ====================================================================
|
||||
* Copyright (c) 2015 The GmSSL Project. All rights reserved.
|
||||
* Copyright (c) 2015-2016 The GmSSL Project. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
@@ -58,15 +58,16 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
typedef struct sm2_data_st {
|
||||
int (*init)(EC_KEY *);
|
||||
ENGINE *engine;
|
||||
int flags;
|
||||
const ECDSA_METHOD *sign_meth;
|
||||
const ECDH_METHOD *kap_meth; /* FIXME: SM2 KAP is different from ECDH */
|
||||
CRYPTO_EX_DATA ex_data;
|
||||
} SM2_DATA;
|
||||
|
||||
struct sm2sign_method {
|
||||
const char *name;
|
||||
SM2_SIG *(*sm2_do_sign)(const unsigned char *dgst, int dgstlen);
|
||||
int (*sm2_sign_setup)(void);
|
||||
int (*sm2_do_verify)(void);
|
||||
int flag;
|
||||
void *app_data;
|
||||
};
|
||||
SM2_DATA *sm2_check(EC_KEY *eckey);
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
Reference in New Issue
Block a user