35 lines
791 B
C++
35 lines
791 B
C++
/***
|
|
Copyright (C) 2022 J Reece Wilson (a/k/a "Reece"). All rights reserved.
|
|
|
|
File: HMAC.hpp
|
|
Date: 2022-9-18
|
|
Author: Reece
|
|
***/
|
|
#pragma once
|
|
|
|
namespace Aurora::Crypto::HMAC
|
|
{
|
|
struct IHMACContext
|
|
{
|
|
/**
|
|
* @brief Processes an arbitrary amount of bytes
|
|
* @param input
|
|
*/
|
|
virtual void Ingest(const Memory::MemoryViewRead &input) = 0;
|
|
|
|
/**
|
|
* @brief Finalizes the hash stream
|
|
* @return
|
|
*/
|
|
virtual Memory::MemoryViewRead Finalize() = 0;
|
|
|
|
/**
|
|
* @brief
|
|
*/
|
|
virtual void Reset() = 0;
|
|
};
|
|
|
|
AUKN_SHARED_API(HMAC, IHMACContext,
|
|
Aurora::Hashing::EHashType algorithm,
|
|
const Memory::MemoryViewRead &sharedSecret);
|
|
} |