Core/Crypto: Transitional Cryptography update for OpenSSL 1.1

Support for both OpenSSL 1.0 LTS and OpenSSL 1.1 versions.

Many Linux distributions are still on 1.0 and will stay on LTS for quite
some time.

Port of CMaNGOS commit: cmangos/mangos-wotlk@e1b0048
This commit is contained in:
Viste(kirill)
2018-05-02 13:57:57 +03:00
parent 783003f0e8
commit 53364abcd7
4 changed files with 48 additions and 32 deletions
+3 -3
View File
@@ -24,11 +24,11 @@ class HmacHash
void UpdateData(const std::string &str);
void UpdateData(const uint8* data, size_t len);
void Finalize();
uint8 *ComputeHash(BigNumber* bn);
uint8 *GetDigest() { return (uint8*)m_digest; }
uint8* ComputeHash(BigNumber* bn);
uint8* GetDigest() { return m_digest; }
int GetLength() const { return SHA_DIGEST_LENGTH; }
private:
HMAC_CTX m_ctx;
HMAC_CTX* m_ctx;
uint8 m_digest[SHA_DIGEST_LENGTH];
};
#endif