1 #ifndef CRYPTOPP_FIPS140_H
2 #define CRYPTOPP_FIPS140_H
11 NAMESPACE_BEGIN(CryptoPP)
17 explicit SelfTestFailure(
const std::string &s) : Exception(OTHER_ERROR, s) {}
27 CRYPTOPP_DLL
void CRYPTOPP_API
DoPowerUpSelfTest(
const char *moduleFilename,
const byte *expectedModuleMac);
42 CRYPTOPP_DLL
bool CRYPTOPP_API IntegrityCheckModule(
const char *moduleFilename,
const byte *expectedModuleMac,
SecByteBlock *pActualMac = NULL,
unsigned long *pMacFileLocation = NULL);
45 bool PowerUpSelfTestInProgressOnThisThread();
47 void SetPowerUpSelfTestInProgressOnThisThread(
bool inProgress);
52 void SignaturePairwiseConsistencyTest_FIPS_140_Only(
const PK_Signer &signer,
const PK_Verifier &verifier);
55 #define CRYPTOPP_DUMMY_DLL_MAC "MAC_51f34b8db820ae8"
base class for all exceptions thrown by Crypto++
interface for message authentication codes
interface for public-key signers
interface for public-key encryptors
bool FIPS_140_2_ComplianceEnabled()
returns whether FIPS 140-2 compliance features were enabled at compile time
interface for public-key decryptors
exception thrown when a crypto algorithm is used after a self test fails
void SimulatePowerUpSelfTestFailure()
set the power-up self test status to POWER_UP_SELF_TEST_FAILED
void DoDllPowerUpSelfTest()
perform the power-up self test using the filename of this DLL and the embedded module MAC ...
PowerUpSelfTestStatus GetPowerUpSelfTestStatus()
return the current power-up self test status
interface for public-key signature verifiers
void DoPowerUpSelfTest(const char *moduleFilename, const byte *expectedModuleMac)
perform the power-up self test, and set the self test status
PowerUpSelfTestStatus
enum values representing status of the power-up self test