summaryrefslogtreecommitdiffstats
path: root/cryptopp562/fips140.h
diff options
context:
space:
mode:
authorMalfurious <m@lfurio.us>2024-10-24 06:44:24 -0400
committerMalfurious <m@lfurio.us>2024-10-24 06:44:24 -0400
commit512aa4c77b3dc0d72db713a9215ff65a98a99ec3 (patch)
tree6db82e0109dc987b5b021f81d4e8a0926eb75ff7 /cryptopp562/fips140.h
parent428471d39fb8c205a9fad899c88c30a2cb7df685 (diff)
parent10affea371406c0ae4c080e5a19390a8e9bd154b (diff)
downloadcompass-512aa4c77b3dc0d72db713a9215ff65a98a99ec3.tar.gz
compass-512aa4c77b3dc0d72db713a9215ff65a98a99ec3.zip
Merge branch 'mbedtls'
Replace Crypto++ 5.6.2 with Mbed TLS 3.6.0 Newer compilers are starting to show the age of the crypto library we've been using, as it is sometimes a pain to recompile compass lately. So, the tracked version of Crypto++ was at least due for an upgrade. However, I plan to soon begin reimplementing compass in C. So, I'm taking this opportunity to first just migrate the cryptography library to a newer C alternative. This branch does so, and integrates its use into the current C++ version of compass. * mbedtls: Remove unnecessary exception handler catch block Refactor random password generation to use mbedtls entropy source Refactor SHA256 function to use mbedtls Refactor AES functions to use mbedtls Add Mbedtls library Remove Crypto++ library
Diffstat (limited to 'cryptopp562/fips140.h')
-rw-r--r--cryptopp562/fips140.h59
1 files changed, 0 insertions, 59 deletions
diff --git a/cryptopp562/fips140.h b/cryptopp562/fips140.h
deleted file mode 100644
index a3e5386..0000000
--- a/cryptopp562/fips140.h
+++ /dev/null
@@ -1,59 +0,0 @@
-#ifndef CRYPTOPP_FIPS140_H
-#define CRYPTOPP_FIPS140_H
-
-/*! \file
- FIPS 140 related functions and classes.
-*/
-
-#include "cryptlib.h"
-#include "secblock.h"
-
-NAMESPACE_BEGIN(CryptoPP)
-
-//! exception thrown when a crypto algorithm is used after a self test fails
-class CRYPTOPP_DLL SelfTestFailure : public Exception
-{
-public:
- explicit SelfTestFailure(const std::string &s) : Exception(OTHER_ERROR, s) {}
-};
-
-//! returns whether FIPS 140-2 compliance features were enabled at compile time
-CRYPTOPP_DLL bool CRYPTOPP_API FIPS_140_2_ComplianceEnabled();
-
-//! enum values representing status of the power-up self test
-enum PowerUpSelfTestStatus {POWER_UP_SELF_TEST_NOT_DONE, POWER_UP_SELF_TEST_FAILED, POWER_UP_SELF_TEST_PASSED};
-
-//! perform the power-up self test, and set the self test status
-CRYPTOPP_DLL void CRYPTOPP_API DoPowerUpSelfTest(const char *moduleFilename, const byte *expectedModuleMac);
-
-//! perform the power-up self test using the filename of this DLL and the embedded module MAC
-CRYPTOPP_DLL void CRYPTOPP_API DoDllPowerUpSelfTest();
-
-//! set the power-up self test status to POWER_UP_SELF_TEST_FAILED
-CRYPTOPP_DLL void CRYPTOPP_API SimulatePowerUpSelfTestFailure();
-
-//! return the current power-up self test status
-CRYPTOPP_DLL PowerUpSelfTestStatus CRYPTOPP_API GetPowerUpSelfTestStatus();
-
-typedef PowerUpSelfTestStatus (CRYPTOPP_API * PGetPowerUpSelfTestStatus)();
-
-CRYPTOPP_DLL MessageAuthenticationCode * CRYPTOPP_API NewIntegrityCheckingMAC();
-
-CRYPTOPP_DLL bool CRYPTOPP_API IntegrityCheckModule(const char *moduleFilename, const byte *expectedModuleMac, SecByteBlock *pActualMac = NULL, unsigned long *pMacFileLocation = NULL);
-
-// this is used by Algorithm constructor to allow Algorithm objects to be constructed for the self test
-bool PowerUpSelfTestInProgressOnThisThread();
-
-void SetPowerUpSelfTestInProgressOnThisThread(bool inProgress);
-
-void SignaturePairwiseConsistencyTest(const PK_Signer &signer, const PK_Verifier &verifier);
-void EncryptionPairwiseConsistencyTest(const PK_Encryptor &encryptor, const PK_Decryptor &decryptor);
-
-void SignaturePairwiseConsistencyTest_FIPS_140_Only(const PK_Signer &signer, const PK_Verifier &verifier);
-void EncryptionPairwiseConsistencyTest_FIPS_140_Only(const PK_Encryptor &encryptor, const PK_Decryptor &decryptor);
-
-#define CRYPTOPP_DUMMY_DLL_MAC "MAC_51f34b8db820ae8"
-
-NAMESPACE_END
-
-#endif