Fix #321 - decryptKey shows OpenSSL error, which were raised before

This commit is contained in:
Yaroslav Isakov 2022-08-30 12:54:47 +02:00 committed by Christian Hohnstädt
parent f4cb91d2f5
commit d289f83a6d

View File

@ -30,6 +30,11 @@ digest::digest(const EVP_MD *md) : md_nid(default_md)
digest::digest(const QString &name) : md_nid(default_md)
{
QString s(name);
// Workaround for Ed25519
if (s.isEmpty()) {
md_nid = NID_undef;
return;
}
md_nid = OBJ_txt2nid(CCHAR(s.remove(QChar(' '))));
}