Import code from previous AssetBuilder version

This commit is contained in:
Jan
2019-09-24 10:45:09 +02:00
parent 5609557516
commit 0d8432d4f7
919 changed files with 154412 additions and 26 deletions

19
src/Crypto/Crypto.cpp Normal file
View File

@ -0,0 +1,19 @@
#include "Crypto.h"
#include "Impl/AlgorithmRSA.h"
#include "Impl/AlgorithmSHA1.h"
#include "Impl/AlgorithmSalsa20.h"
IHashFunction* Crypto::CreateSHA1()
{
return new AlgorithmSHA1();
}
IStreamCipher* Crypto::CreateSalsa20(const uint8_t* keyBytes, const size_t keySize)
{
return new AlgorithmSalsa20(keyBytes, keySize);
}
IPublicKeyAlgorithm* Crypto::CreateRSA(const IPublicKeyAlgorithm::HashingAlgorithm hashingAlgorithm, const RSAPaddingMode paddingMode)
{
return new AlgorithmRSA(hashingAlgorithm, paddingMode);
}