Hi Max,
On 03.07.2016 23:41, Max Qian wrote:
diff --git a/include/wincrypt.h b/include/wincrypt.h index 55c9509..19af6ca 100644 --- a/include/wincrypt.h +++ b/include/wincrypt.h @@ -1583,6 +1583,7 @@ typedef const CERT_CRL_CONTEXT_PAIR *PCCERT_CRL_CONTEXT_PAIR; #define ALG_SID_AGREED_KEY_ANY 3 #define ALG_SID_KEA 4 #define ALG_SID_ECDH 5 +#define ALG_SID_ECDH_EPHEM 6 /* RC2 SIDs */ #define ALG_SID_RC4 1 #define ALG_SID_RC2 2 @@ -1639,6 +1640,7 @@ typedef const CERT_CRL_CONTEXT_PAIR *PCCERT_CRL_CONTEXT_PAIR; #define CALG_KEA_KEYX (ALG_CLASS_KEY_EXCHANGE | ALG_TYPE_DH | ALG_SID_KEA) #define CALG_HUGHES_MD5 (ALG_CLASS_KEY_EXCHANGE | ALG_TYPE_ANY | ALG_SID_MD5) #define CALG_ECDH (ALG_CLASS_KEY_EXCHANGE | ALG_TYPE_DH | ALG_SID_ECDH) +#define CALG_ECDH_EPHEM (ALG_CLASS_KEY_EXCHANGE | ALG_TYPE_DH | ALG_SID_ECDH_EPHEM) #define CALG_RSA_KEYX (ALG_CLASS_KEY_EXCHANGE | ALG_TYPE_RSA | ALG_SID_RSA_ANY) #define CALG_ECMQV (ALG_CLASS_KEY_EXCHANGE | ALG_TYPE_ANY | ALG_SID_ECMQV) #define CALG_DES (ALG_CLASS_DATA_ENCRYPT | ALG_TYPE_BLOCK | ALG_SID_DES)
Do you have a version of PSDK that has this definition? I can't see it here. If those are not in MS headers, we shouldn't have them unless we have a strong reason. When I asked you about adding a comment, I was hoping for something like
/* MSDN mentions CALG_ECDH_EPHEM, but it's not available in headers. */ case ....: return CALG_ECDH;
Thanks, Jacek