Jeffrey Walton
fb5e731fd9
Sync with Upstream master
2017-08-16 22:17:09 -04:00
Jeffrey Walton
609b0ca9e8
Disable Carryless Multiplies for Clang
...
Clang causes too many problems. Early versions of the compiler simply crashes. Later versions of the compiler still have trouble with Intel ASM and still produce incorrect results on occassion. Additionally, we have to special case the integrated assemvler. Its making a mess of the code and causing self test failures
2017-08-16 22:16:53 -04:00
Jeffrey Walton
df280a509a
Disable Carryless Multiplies for Clang
...
Clang causes too many problems. Early versions of the compiler simply crashes. Later versions of the compiler still have trouble with Intel ASM and still produce incorrect results on occassion. Additionally, we have to special case the integrated assemvler. Its making a mess of the code and causing self test failures
2017-08-16 22:10:53 -04:00
Jeffrey Walton
a25e63fcb7
Fix sources after sync with upstream
2017-08-14 03:19:20 -04:00
Jeffrey Walton
011429583d
Fix sources after sync with upstream master
2017-08-13 07:06:19 -04:00
Jeffrey Walton
e0ec92b541
Sync with Upstream master
2017-08-13 06:54:28 -04:00
Jeffrey Walton
863bf9133c
Cleanup casts due to Clang
2017-08-13 06:32:09 -04:00
Jeffrey Walton
d8e56b8250
Sync with Upstream master
2017-08-13 05:01:57 -04:00
Jeffrey Walton
f02bf91ee5
Revert 95ee8975b4 and 7d21cdd54e (Issue 408)
...
This broke some OS X builds. We need more testing. Ugh...
2017-08-13 04:31:17 -04:00
Jeffrey Walton
95ee8975b4
Use blockSize in error message thrown
2017-08-12 20:29:33 -04:00
Jeffrey Walton
5f3a3f29e8
Sync with Upstream master
2017-08-12 19:28:59 -04:00
Jeffrey Walton
5e6e6c4eaa
Sync with Upstream master
2017-08-12 19:24:00 -04:00
Jeffrey Walton
7d21cdd54e
Convert GCM to use runtime blocksize checking (Issue 408)
...
GCM is still only defined for 16-byte ciphers, but this is where we need to be when we add the larger polynomials
2017-08-12 16:14:29 -04:00
Jeffrey Walton
22b7d74e1f
Test Apple ARM64 runtime detection
...
This is a compile test
2017-08-11 11:57:30 -04:00
Jeffrey Walton
69b3a7a664
Fix compile on Solaris 11.3 under GCC and SunCC
2017-08-09 00:14:54 -04:00
Jeffrey Walton
b9ab0579d3
Fix Clang compile
2017-08-01 05:55:06 -04:00
Jeffrey Walton
142fe88ae1
Initial AES cleanup after cross-platofrm testing
2017-07-31 23:17:18 -04:00
Jeffrey Walton
dece762045
Cleanup includes for BLAKE2 and GCM
2017-07-31 21:56:39 -04:00
Jeffrey Walton
9d8a89256d
Cleanup ARMv7 and ARMv8
2017-07-31 07:13:34 -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
a495018af2
Fix GCM under SSSE3 and CLMUL
2017-07-31 00:40:03 -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
8338d90c10
Add ARIA, BLAKE2 and SHA support for ARMv7, ARMv8 and Intel
2017-07-29 23:40:56 -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
5efb019d8b
Add C++ nullptr support (Issue 383)
2017-03-01 06:10:06 -05:00
Jeffrey Walton
81b1a18063
Change file preamble to include "originally written by Wei Dai"
...
We have made a fair number of changes, and we don't want WD to receive credit for issues he was not part of
2017-01-27 07:05:45 -05:00
Jeffrey Walton
14f5305c92
VEXT_8 -> VEXT_U8
2017-01-22 20:53:19 -05:00
Jeffrey Walton
f2132a81c1
Comments and whitespace checkin
2017-01-20 19:41:20 -05:00
Jeffrey Walton
74328f93a8
Fix "error: impossible constraint in asm" under Aarch64 (Issue 366)
2017-01-20 18:48:11 -05:00
Jeffrey Walton
4f725eddc1
Call vrev64q_u8 after vld1q_u8
2017-01-19 07:37:54 -05:00
Jeffrey Walton
bbf13b77e7
Switch to vext and remove unnecessary casts
2017-01-19 06:22:38 -05:00
Jeffrey Walton
b129818c35
Add GCC inline ASM for PMULL and PMULL2
...
The macros that invoke GCC inline ASM have better code generation and speedup GCM ops by about 70 MiB/s on an Opteron 1100. The intrinsics are still available for Windows platforms and Visual Studio 2017 and above
2017-01-19 02:38:00 -05:00
Jeffrey Walton
4f2bb7664f
Avoid C-style casts for NEON vectors
...
Switch to ARM vector casts like vreinterpretq_u8_u64
2017-01-16 17:12:44 -05:00
Jeffrey Walton
c80502102a
Breakout __ARM_FEATURE_CRYPTO into PMULL, AES and SHA for Apple Clang (Issue 362)
...
It appears Apple Clang disgorges carryless multiply (PMULL) from Crypto (AES and SHA). The breakout added CRYPTOPP_BOOL_ARM_PMULL_INTRINSICS_AVAILABLE for PMULL, and retained CRYPTOPP_BOOL_ARM_CRYPTO_INTRINSICS_AVAILABLE for AES and SHA only
2017-01-15 00:22:14 -05:00
Jeffrey Walton
56a91ca197
Remove last of macros targtting _MSC_VER 1200 (Issue 342)
2016-12-03 21:31:22 -05:00
Jeffrey Walton
33a59b8bd1
Reference 226 and 284 bugs in workaround since the gyrations are not readily apparent
2016-09-18 11:57:57 -04:00
Jeffrey Walton
2d0e388d9a
Fix SunCC 12.5 failed validation in gcm.cpp (Issue 284)
2016-09-18 11:45:12 -04:00
Jeffrey Walton
4fb75a8f4d
Fix SunCC 12.3 - 12.5 crash in gcm.cpp
...
/opt/developerstudio12.5/bin/CC -DNDEBUG -g2 -O2 -m64 -native -KPIC -template=no%extdef -c gcm.cpp
assertion failed in function pr_post_process_node() @ preopt.c:3868
assert(nd_eq_(scope_first_stmt_(node), first_s))
CC: ube failed for gcm.cpp
2016-09-18 10:26:57 -04:00
Jeffrey Walton
8f33054545
Revert "Fix SunCC 12.3 - 12.5 crash in gcm.cpp"
...
This reverts commit 519b41e47e . Additional testing cruft was included in the commit.
2016-09-18 10:23:10 -04:00
Jeffrey Walton
519b41e47e
Fix SunCC 12.3 - 12.5 crash in gcm.cpp
...
$ /opt/developerstudio12.5/bin/CC -DNDEBUG -g2 -O2 -D__SSE2__ -D__SSE3__ -D__SSSE3__ -xarch=ssse3 -Wno-deprecated-declarations -m64 -native -KPIC -template=no%extdef -c gcm.cpp
assertion failed in function pr_post_process_node() @ preopt.c:3868
assert(nd_eq_(scope_first_stmt_(node), first_s))
CC: ube failed for gcm.cpp
2016-09-18 10:21:59 -04:00
Jeffrey Walton
6847978f0a
Merge 'master' into 'trap'
2016-09-16 11:28:23 -04:00
Jeffrey Walton
399a1546de
Add CRYPTOPP_ASSERT (Issue 277, CVE-2016-7420)
...
trap.h and CRYPTOPP_ASSERT has existed for over a year in Master. We deferred on the cut-over waiting for a minor version bump (5.7). We have to use it now due to CVE-2016-7420
2016-09-16 11:27:15 -04:00
Jeffrey Walton
69f3d9483e
Fixed gcm.cpp compile under MSC/Visual Studio
2016-09-16 08:09:04 -04:00
Jeffrey Walton
9b5dc3c765
Fix gcm.cpp compile under i686 Linux after 97282f61cd
2016-09-13 10:01:39 -04:00
Jeffrey Walton
97282f61cd
Fix gcm.cpp compile under x86_64 Linux after 4f7fb2067d
2016-09-12 22:29:13 -04:00
Jeffrey Walton
32375fe322
Fixed comments in macro magic
2016-09-12 19:17:18 -04:00
Jeffrey Walton
abd14a4b0a
Improved comments in macro magic
2016-09-12 19:05:09 -04:00