ETSI STF525 / Internal Testing test suite
This project provides an internal testing test suite and its associated Test Adapter/Codec
Public Member Functions | Private Attributes | List of all members
sha384 Class Reference

This class provides description of SHA-384 helper methods. More...

#include <sha384.hh>

Public Member Functions

 sha384 ()
 SHA context. More...
 
virtual ~sha384 ()
 Default destructor. More...
 
int generate (const std::vector< unsigned char > p_buffer, std::vector< unsigned char > &p_hash)
 Receive bytes formated data from the lower layers. More...
 
int generate (const unsigned char *p_buffer, const size_t p_length, std::vector< unsigned char > &p_hash)
 

Private Attributes

SHA512_CTX _ctx
 

Detailed Description

This class provides description of SHA-384 helper methods.

Constructor & Destructor Documentation

◆ sha384()

sha384::sha384 ( )
inlineexplicit

SHA context.

Default constructor Create a new instance of the sha384 class

◆ ~sha384()

virtual sha384::~sha384 ( )
inlinevirtual

Default destructor.

Member Function Documentation

◆ generate() [1/2]

int sha384::generate ( const std::vector< unsigned char >  p_buffer,
std::vector< unsigned char > &  p_hash 
)
inline

Receive bytes formated data from the lower layers.

Parameters
[in]p_bufferThe data used to generate the SHA-384 hash
[out]p_hashThe SHA-384 hash value based of the provided data
Returns
0 on success, -1 otherwise
Parameters
[in]p_bufferThe data used to generate the SHA-384 hash
[in]Thelength of the data buffer
[out]p_hashThe SHA-384 hash value based of the provided data
Returns
0 on success, -1 otherwise

◆ generate() [2/2]

int sha384::generate ( const unsigned char *  p_buffer,
const size_t  p_length,
std::vector< unsigned char > &  p_hash 
)
inline

Member Data Documentation

◆ _ctx

SHA512_CTX sha384::_ctx
private

The documentation for this class was generated from the following file: