Commit Graph

2862 Commits (79f727d7146e1f28e39c23a33b25182cc71cd9d6)

Author SHA1 Message Date
Jeffrey Walton 05bf4fd54b
Whitespace check-in 2017-08-01 19:58:08 -04:00
Jeffrey Walton ce6c578eb2 Sync with Upstream master 2017-08-01 19:12:26 -04:00
Jeffrey Walton 5fbbc5311c
Add self tests for OldRandomPool
We still need to get the test result cross-validated
2017-08-01 18:57:23 -04:00
Jeffrey Walton 02e3a79444
Add OldRandomPool class (Issue 452)
RandomPool used to be a PGP-style deterministic generator and folks used it as a key generation function. At Crypto++ 5.5 the design changed to harden it agianst rollback attacks. The design change resulted in an upgrade barrier. That is, some folks are stuck at Crypto++ 4.2 or Crypto++ 5.2 because they must interoperate with existing software.

Below is the test program we used for the test vector. It was run against Crypto++ 5.4.

    RandomPool prng;
    SecByteBlock seed(0x00, 384), result(64);
    prng.Put(seed, seed.size());

    prng.GenerateBlock(result, result.size());
    HexEncoder encoder(new FileSink(std::cout));

    std::cout << "RandomPool: ";
    encoder.Put(result, sizeof(result));
    std::cout << std::endl;
2017-08-01 18:53:31 -04:00
Jeffrey Walton 74ef70683d
Discard Clang error messages 2017-08-01 08:58:19 -04:00
Jeffrey Walton b9ab0579d3
Fix Clang compile 2017-08-01 05:55:06 -04:00
Jeffrey Walton 667d62b3ae
Fix MSVC break when moving MM_SET_EPI64X 2017-08-01 05:48:44 -04:00
Jeffrey Walton d41bee1f4e
Fix Clang compile 2017-08-01 02:30:12 -04:00
Jeffrey Walton 1356456f05
Finish AESNI cut-in
Remove specialized MMX and ISSE support. SSE2 is now the floor
2017-08-01 01:20:30 -04:00
Jeffrey Walton 142fe88ae1
Initial AES cleanup after cross-platofrm testing 2017-07-31 23:17:18 -04:00
Jeffrey Walton 9a050ae559
Fix function pointer names
The ARM function pointers still had the _ARMV8A suffix, not the _ARMV8 suffix
2017-07-31 22:49:35 -04:00
Jeffrey Walton dece762045
Cleanup includes for BLAKE2 and GCM 2017-07-31 21:56:39 -04:00
Jeffrey Walton 87e7b85224
Initial Rijndael cut-in 2017-07-31 20:58:27 -04:00
Jeffrey Walton 2a17350d64
Sync with Upstream master 2017-07-31 19:32:43 -04:00
Jeffrey Walton 475232abff Sync with Upstream master 2017-07-31 19:28:57 -04:00
Jeffrey Walton 2171a3a379
Update DLL_SRCS list
Also see http://groups.google.com/forum/#!topic/cryptopp-users/Q8_6mSS5ZSw on the mailing list
2017-07-31 19:04:48 -04:00
Jeffrey Walton 249a5ed869
Consitently use _ARMV8 as Aarch32/Aarch64 function suffix 2017-07-31 18:06:07 -04:00
Jeffrey Walton e06c1561de
Fix missing GCM_ReverseHashBufferIfNeeded_NEON under NEON 2017-07-31 14:21:11 -04:00
Jeffrey Walton 9d8a89256d
Cleanup ARMv7 and ARMv8 2017-07-31 07:13:34 -04:00
Jeffrey Walton 9159992938
Update test script 2017-07-31 05:36:29 -04:00
Jeffrey Walton 51cff62bd0
Fix ARMv7 2017-07-31 05:22:35 -04:00
Jeffrey Walton eafdae9025
Const-ify hashKey 2017-07-31 04:27:22 -04:00
Jeffrey Walton 6145d52b22
Add GCM_SetKeyWithoutResync_PMULL 2017-07-31 04:16:39 -04:00
Jeffrey Walton 48f46bb852
Update comments 2017-07-31 03:55:10 -04:00
Jeffrey Walton 205e116bcd
Fix Intel SHA code path activation 2017-07-31 03:48:45 -04:00
Jeffrey Walton 2b9319cd8a
Fix Aarch64 build. Cleanup Windows build 2017-07-31 03:08:02 -04:00
Jeffrey Walton a8462328f4
Fix Aarch64 build. Cleanup Windows build 2017-07-31 03:07:32 -04:00
Jeffrey Walton 1fdd08d690
Fix ARM build under Windows Phone 2017-07-31 02:09:15 -04:00
Jeffrey Walton 7e1c21957f
Clear LNK2001 for ARIA tables in ARIATab namespace
cryptlib.lib(aria.obj) : error LNK2001: unresolved external symbol "unsigned int const * const CryptoPP::ARIATab::X2" (?X2@ARIATab@CryptoPP@@3QBIB) [C:\projects\cryptopp\cryptest.vcxproj]
cryptlib.lib(aria-simd.obj) : error LNK2001: unresolved external symbol "unsigned int const * const CryptoPP::ARIATab::X2" (?X2@ARIATab@CryptoPP@@3QBIB) [C:\projects\cryptopp\cryptest.vcxproj]
...
2017-07-31 01:17:15 -04:00
Jeffrey Walton a495018af2
Fix GCM under SSSE3 and CLMUL 2017-07-31 00:40:03 -04:00
Jeffrey Walton 6576bc30b8
Add ariatab.cpp 2017-07-30 23:06:06 -04:00
Jeffrey Walton 24fa16d15c
Fix ARIA under SSSE3 2017-07-30 22:56:18 -04:00
Jeffrey Walton 5e9e228727
Fix ARIA under SSSE3 2017-07-30 22:55:50 -04:00
Jeffrey Walton 6169b5d4d6
Cleaned up ARM related defines, like CRYPTOPP_ARM_NEON_AVAILABLE
We only need to base it on the compiler in config.h. config.h activates the code path guarded by HasNEON(). The source file that actially provides the NEON implementation will be compiled with -fpu=neon or -march=armv8-a.
Since we are providing the specialized implementation in a sequestered source file (and not a header file), we can probably avoid the defines like CRYPTOPP_ARM_NEON_AVAILABLE altogether.
2017-07-30 19:14:47 -04:00
Jeffrey Walton b4f6882237
Fixed ARMv7a and NEON detection. Initial cut-in of GCM 2017-07-30 03:16:58 -04:00
Jeffrey Walton 4b51eadc73
Removed stray XXX in blake2-simd.cpp 2017-07-30 00:20:20 -04:00
Jeffrey Walton 8338d90c10
Add ARIA, BLAKE2 and SHA support for ARMv7, ARMv8 and Intel 2017-07-29 23:40:56 -04:00
Jeffrey Walton 61691dd906
Remove duplicate test from cryptest.sh 2017-07-29 16:46:28 -04:00
Jeffrey Walton fd4c7546b5
Update TestScripts/cryptest.sh. Rename X86_SHA256_HashBlocks → SHA256_HashBlocks_SSE2 2017-07-29 15:16:04 -04:00
Jeffrey Walton d5a6d8f81b
Cut-in SHA for Intel and ARMv8a 2017-07-29 14:18:30 -04:00
Jeffrey Walton 3e7496803e
Move CRC32 probe code from cpu.cpp to crc-simd.cpp 2017-07-29 03:49:48 -04:00
Jeffrey Walton 368f344667
Fix define/include 2017-07-29 01:00:30 -04:00
Jeffrey Walton fe9e21ddd7
Cut-in CRC test for SSE4.2 and ARMv8a
Also see https://groups.google.com/forum/#!topic/cryptopp-users/-1fZCx8JSRE
2017-07-29 00:24:07 -04:00
Marcel Raad b5191dde6f sockets: fix Windows 2000 build (#450)
Commit 4630a5dab6 broke compilation for
Windows 2000 and earlier as getaddrinfo was introduced in Windows XP.
Fix this by including <wspiapi.h> when targeting Windows 2000 and
earlier, which falls back to an inline implementation of getaddrinfo
when necessary.
Some MinGW flavors still target Windows 2000 by default.

Ref:
https://msdn.microsoft.com/en-us/library/windows/desktop/ms738520.aspx,
section "Support for getaddrinfo on Windows 2000 and older versions"
2017-07-28 15:14:59 -04:00
Marcel Raad d44a81f91c Enforce LF line endings for shell scripts (#451)
This tells git to check out *.sh files with LF line endings. Otherwise,
Cygwin and Windows 10's Bash cannot run them.
2017-07-28 15:14:29 -04:00
Jeffrey Walton 3fc7b104e6
Update documentation 2017-07-28 12:35:25 -04:00
Jeffrey Walton 46993f10f4
Update documentation 2017-07-28 11:50:11 -04:00
Jeffrey Walton ade3b319a9
Assign t and v together in Sosemanuk (Issue 449)
This saved about 0.1 cpb, and increased throughput to 1536 MiB/s
2017-07-28 01:34:53 -04:00
Jeffrey Walton ed4c345ce8
Clear Clang -Wsequence-point warning (Issue 449) 2017-07-28 00:33:45 -04:00
Jeffrey Walton d0cd32f405
Make SecBlock<T,A> data members protected
Also see http://github.com/weidai11/cryptopp/issues/448
2017-07-27 20:28:23 -04:00