!4167 【SECURITY】【修复问题】【#I80TKW】修复密态特性的sm2与rsa2048加密函数

Merge pull request !4167 from lorand/919_sm2
This commit is contained in:
opengauss_bot
2023-09-20 08:25:23 +00:00
committed by Gitee
4 changed files with 26 additions and 20 deletions

View File

@ -49,7 +49,13 @@ public:
HMAC_CTX* ctx_worker;
HMAC_CTX* ctx_template;
private:
void free_hmac_ctx(HMAC_CTX** ctx_tmp) const;
void free_hmac_ctx(HMAC_CTX** ctx_tmp)
{
if (*ctx_tmp != NULL) {
HMAC_CTX_free(*ctx_tmp);
*ctx_tmp = NULL;
}
}
};
/*