![]() |
TrinityCore
|
#include <CryptoHash.h>
Public Types | |
| using | Digest = std::array< uint8, DIGEST_LENGTH > |
Public Member Functions | |
| GenericHash () | |
| GenericHash (GenericHash const &right) | |
| GenericHash (GenericHash &&right) noexcept | |
| ~GenericHash () | |
| GenericHash & | operator= (GenericHash const &right) |
| GenericHash & | operator= (GenericHash &&right) noexcept |
| void | UpdateData (uint8 const *data, size_t len) |
| void | UpdateData (std::string_view str) |
| void | UpdateData (std::string const &str) |
| void | UpdateData (char const *str) |
| template<typename Container > | |
| void | UpdateData (Container const &c) |
| void | Finalize () |
| Digest const & | GetDigest () const |
Static Public Member Functions | |
| static Digest | GetDigestOf (uint8 const *data, size_t len) |
| template<typename... Ts, std::enable_if_t< std::conjunction_v< std::negation< std::is_integral< Ts > >... >, int32 > = 0> | |
| static Digest | GetDigestOf (Ts &&... pack) |
Static Public Attributes | |
| static constexpr size_t | DIGEST_LENGTH = DigestLength |
Private Attributes | |
| EVP_MD_CTX * | _ctx |
| Digest | _digest = { } |
Definition at line 43 of file CryptoHash.h.
| using Trinity::Impl::GenericHash< HashCreator, DigestLength >::Digest = std::array<uint8, DIGEST_LENGTH> |
Definition at line 47 of file CryptoHash.h.
|
inline |
Definition at line 66 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::_ctx, and ASSERT.
|
inline |
Definition at line 72 of file CryptoHash.h.
|
inlinenoexcept |
Definition at line 77 of file CryptoHash.h.
|
inline |
Definition at line 82 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::_ctx, and Trinity::Impl::GenericHashImpl::DestroyCTX().
|
inline |
Definition at line 122 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::_ctx, Trinity::Impl::GenericHash< HashCreator, DigestLength >::_digest, ASSERT, and Trinity::Impl::GenericHash< HashCreator, DigestLength >::DIGEST_LENGTH.
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::GetDigestOf(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::GetDigestOf(), and WorldSocket::HandleAuthSessionCallback().
|
inline |
Definition at line 130 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::_digest.
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::GetDigestOf(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::GetDigestOf(), and WorldSocket::HandleAuthSessionCallback().
|
inlinestatic |
|
inlinestatic |
Definition at line 49 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::Finalize(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::GetDigest(), and Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
Referenced by Trinity::Crypto::SRP::GruntSRP6::CalculateServerEvidence(), Trinity::Crypto::SRP::BnetSRP6v1Base::CalculateX(), Trinity::Crypto::SRP::GruntSRP6::CalculateX(), Trinity::Crypto::SRP::GruntSRP6::DoVerifyClientEvidence(), Battlenet::AccountMgr::GetSrpUsername(), Battlenet::LoginRESTService::HandlePostLogin(), Battlenet::LoginRESTService::HandlePostLoginSrpChallenge(), Battlenet::LoginRESTService::MigrateLegacyPasswordHashes(), Trinity::Crypto::SRP::GruntSRP6::SHA1Interleave(), and UpdateFetcher::Update().
|
inlinenoexcept |
Definition at line 101 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::_ctx, Trinity::Impl::GenericHash< HashCreator, DigestLength >::_digest, and Trinity::Impl::GenericHashImpl::MakeCTX().
|
inline |
Definition at line 90 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::_ctx, Trinity::Impl::GenericHash< HashCreator, DigestLength >::_digest, and ASSERT.
|
inline |
Definition at line 118 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
|
inline |
Definition at line 120 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
|
inline |
Definition at line 117 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
|
inline |
Definition at line 116 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData().
|
inline |
Definition at line 111 of file CryptoHash.h.
References Trinity::Impl::GenericHash< HashCreator, DigestLength >::_ctx, and ASSERT.
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::GetDigestOf(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::GetDigestOf(), and WorldSocket::HandleAuthSessionCallback().
|
private |
Definition at line 133 of file CryptoHash.h.
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::Finalize(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::GenericHash(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::operator=(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::operator=(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::UpdateData(), and Trinity::Impl::GenericHash< HashCreator, DigestLength >::~GenericHash().
|
private |
Definition at line 134 of file CryptoHash.h.
Referenced by Trinity::Impl::GenericHash< HashCreator, DigestLength >::Finalize(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::GetDigest(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::operator=(), and Trinity::Impl::GenericHash< HashCreator, DigestLength >::operator=().
|
staticconstexpr |
Definition at line 46 of file CryptoHash.h.
Referenced by Trinity::Crypto::SRP::GruntSRP6::CalculateServerEvidence(), Trinity::Crypto::SRP::GruntSRP6::DoVerifyClientEvidence(), Trinity::Impl::GenericHash< HashCreator, DigestLength >::Finalize(), and Trinity::Crypto::SRP::GruntSRP6::SHA1Interleave().