CatapultServer
v0.5.0.1 (Elephant)
|
void Sha256Double(const RawBuffer &dataBuffer, Hash256 &hash) noexcept
Calculates double sha256 hash of dataBuffer into hash.
Definition: Hashes.cpp:65
Input is hashed twice: first with SHA-256 and then with RIPEMD-160.
Input is hashed using Sha-3-256.
utils::ByteArray< Hash256_Size, Hash256_tag > Hash256
Definition: src/catapult/types.h:47
void Sha3_256(const RawBuffer &dataBuffer, Hash256 &hash) noexcept
Calculates the 256-bit SHA3 hash of dataBuffer into hash.
Definition: Hashes.cpp:81
Builder for building a hash.
Definition: Hashes.h:61
constexpr std::underlying_type_t< TEnum > to_underlying_type(TEnum value)
Converts a strongly typed enumeration value to its underlying integral value.
Definition: Casting.h:37
void final(OutputType &output) noexcept
Finalize hash calculation. Returns result in output.
Definition: Hashes.cpp:145
void Bitcoin160(const RawBuffer &dataBuffer, Hash160 &hash) noexcept
Calculates bitcoin's hash 160 of dataBuffer into hash (sha256 + ripemd).
Definition: Hashes.cpp:58
Hash256 CalculateSecretLockInfoHash(const Hash256 &secret, const Address &recipient)
Calculates the secret lock info hash from secret and recipient.
Definition: LockHashUtils.cpp:64
void update(const RawBuffer &dataBuffer) noexcept
Updates the state of hash with data inside dataBuffer.
Definition: Hashes.cpp:134
Hash256 CalculateHash(LockHashAlgorithm hashAlgorithm, const RawBuffer &data)
Calculates hashAlgorithm hash of data.
Definition: LockHashUtils.cpp:46
#define CATAPULT_THROW_INVALID_ARGUMENT_1(MESSAGE, PARAM1)
Macro used to throw a catapult invalid argument with a single parameter.
Definition: exceptions.h:183
Input is hashed twice with SHA-256.
Definition: AddressExtractionExtension.cpp:28
LockHashAlgorithm
Lock secret hash algorithm.
Definition: LockHashAlgorithm.h:27
Input is hashed using Keccak-256.
void Keccak_256(const RawBuffer &dataBuffer, Hash256 &hash) noexcept
Calculates the 256-bit Keccak hash of dataBuffer into hash.
Definition: Hashes.cpp:89
BasicRawBuffer< const uint8_t > RawBuffer
A const binary buffer.
Definition: RawBuffer.h:62