PanamaMAC< B > Class Template Reference

#include <panama.h>

Inheritance diagram for PanamaMAC< B >:

HermeticHashFunctionMAC< PanamaHash< B > > AlgorithmImpl< SimpleKeyingInterfaceImpl< TwoBases< MessageAuthenticationCode, VariableKeyLength< 32, 0, UINT_MAX > > >, PanamaHash< B > > SimpleKeyingInterfaceImpl< TwoBases< MessageAuthenticationCode, VariableKeyLength< 32, 0, UINT_MAX > > > TwoBases< MessageAuthenticationCode, VariableKeyLength< 32, 0, UINT_MAX > > MessageAuthenticationCode VariableKeyLength< 32, 0, UINT_MAX > HashTransformation SimpleKeyingInterface Algorithm Clonable List of all members.

Detailed Description

template<class B = LittleEndian>
class PanamaMAC< B >

Panama MAC.

Definition at line 99 of file panama.h.

Public Member Functions

 PanamaMAC ()
 PanamaMAC (const byte *key, unsigned int length)
void SetKey (const byte *key, size_t length, const NameValuePairs &params=g_nullNameValuePairs)
 set or reset the key of this object
void Restart ()
 discard the current state, and restart with a new message
void Update (const byte *input, size_t length)
 process more input
void TruncatedFinal (byte *digest, size_t digestSize)
 truncated version of Final()
unsigned int DigestSize () const
 size of the hash returned by Final()
unsigned int BlockSize () const
 block size of underlying compression function, or 0 if not block based
unsigned int OptimalBlockSize () const
 input to Update() should have length a multiple of this for optimal speed
unsigned int OptimalDataAlignment () const
 returns how input should be aligned for optimal performance
std::string AlgorithmName () const
 returns name of this algorithm, not universally implemented yet
size_t MinKeyLength () const
 returns smallest valid key length in bytes */
size_t MaxKeyLength () const
 returns largest valid key length in bytes */
size_t DefaultKeyLength () const
 returns default (recommended) key length in bytes */
size_t GetValidKeyLength (size_t n) const
 returns the smallest valid key length in bytes that is >= min(n, GetMaxKeyLength())
TwoBases< MessageAuthenticationCode,
VariableKeyLength<
32, 0, UINT_MAX > >::IV_Requirement 
IVRequirement () const
 returns the minimal requirement for secure IVs

Static Public Member Functions

static std::string __cdecl StaticAlgorithmName ()

Protected Member Functions

void KeyHash ()
void AssertValidKeyLength (size_t length)

Protected Attributes

PanamaHash< B > m_hash
bool m_keyed
SecByteBlock m_key


Member Function Documentation

void HermeticHashFunctionMAC< PanamaHash< B > , PanamaHash< B > >::SetKey ( const byte *  key,
size_t  length,
const NameValuePairs params = g_nullNameValuePairs 
) [inline, virtual, inherited]

set or reset the key of this object

Parameters:
params is used to specify Rounds, BlockSize, etc

Implements SimpleKeyingInterface.

Definition at line 49 of file panama.h.

References SecBlock< T, A >::Assign(), HermeticHashFunctionMAC< T_Hash, T_Info >::m_key, and HermeticHashFunctionMAC< T_Hash, T_Info >::Restart().

Referenced by PanamaMAC< B >::PanamaMAC().


The documentation for this class was generated from the following file:
Generated on Thu Nov 23 16:17:13 2006 for Crypto++ by  doxygen 1.5.1-p1