diff --git a/src/Crypto/Crypto.h b/src/Crypto/Crypto.h index 8daa8eaf..70a16af5 100644 --- a/src/Crypto/Crypto.h +++ b/src/Crypto/Crypto.h @@ -1,4 +1,7 @@ #pragma once + +#include + #include "IHashFunction.h" #include "IStreamCipher.h" #include "IPublicKeyAlgorithm.h" diff --git a/src/Crypto/IHashFunction.h b/src/Crypto/IHashFunction.h index c6780cfa..81dbec51 100644 --- a/src/Crypto/IHashFunction.h +++ b/src/Crypto/IHashFunction.h @@ -1,5 +1,7 @@ #pragma once +#include + class IHashFunction { public: @@ -9,4 +11,4 @@ public: virtual void Init() = 0; virtual void Process(const void* input, size_t inputSize) = 0; virtual void Finish(void* hashBuffer) = 0; -}; \ No newline at end of file +}; diff --git a/src/Crypto/IPublicKeyAlgorithm.h b/src/Crypto/IPublicKeyAlgorithm.h index c9195df9..03969751 100644 --- a/src/Crypto/IPublicKeyAlgorithm.h +++ b/src/Crypto/IPublicKeyAlgorithm.h @@ -1,6 +1,7 @@ #pragma once #include +#include class IPublicKeyAlgorithm { @@ -18,4 +19,4 @@ public: // If needed add a signing method virtual bool Verify(const uint8_t* signedData, size_t signedDataSize, const uint8_t* signature, size_t signatureSize) = 0; -}; \ No newline at end of file +}; diff --git a/src/Crypto/IStreamCipher.h b/src/Crypto/IStreamCipher.h index 36cda6cf..75ad103c 100644 --- a/src/Crypto/IStreamCipher.h +++ b/src/Crypto/IStreamCipher.h @@ -1,5 +1,7 @@ #pragma once + #include +#include class IStreamCipher { diff --git a/src/Crypto/Impl/AlgorithmSalsa20.cpp b/src/Crypto/Impl/AlgorithmSalsa20.cpp index 46bc8d8d..4b2869b7 100644 --- a/src/Crypto/Impl/AlgorithmSalsa20.cpp +++ b/src/Crypto/Impl/AlgorithmSalsa20.cpp @@ -1,7 +1,7 @@ #include "AlgorithmSalsa20.h" #include "salsa20.h" #include -#include +#include class AlgorithmSalsa20::AlgorithmSalsa20Impl { @@ -27,7 +27,7 @@ public: if(ivSize != 8) { - throw std::exception("Salsa20 IV size must be 8"); + throw std::invalid_argument("Salsa20 IV size must be 8"); } Salsa20_IVSetup(&m_context, iv); @@ -84,4 +84,4 @@ void AlgorithmSalsa20::SetIV(const uint8_t* iv, const size_t ivSize) void AlgorithmSalsa20::Process(const void* plainText, void* cipherText, const size_t amount) { m_impl->Process(plainText, cipherText, amount); -} \ No newline at end of file +} diff --git a/src/Utils/Utils/Arguments/CommandLineOption.cpp b/src/Utils/Utils/Arguments/CommandLineOption.cpp index 7c5130e9..d5f77fd6 100644 --- a/src/Utils/Utils/Arguments/CommandLineOption.cpp +++ b/src/Utils/Utils/Arguments/CommandLineOption.cpp @@ -1,5 +1,4 @@ #include "CommandLineOption.h" -#include CommandLineOption::CommandLineOption() { @@ -57,4 +56,4 @@ CommandLineOption* CommandLineOption::Builder::Build() const delete this; return result; -} \ No newline at end of file +}