Sean Parkinson
c739b4d474
ECDSA sign: cleanup comments and variables
...
Remove mod at end as mulmod does this.
Change mp_add to mp_addmod_ct to keep the size of numbers to less than
order for mp_mulmod.
2021-01-27 09:39:11 +10:00
Sean Parkinson
9c34ecc130
ECDSA: don't modify the e mp_int (hash) value
...
Multiple loops of generating signatures require the same e value.
2021-01-22 12:51:21 +10:00
David Garske
07f459b8d7
Merge pull request #3650 from kojo1/RsaSetRNG
...
add wc_RsaSetRNG to doc
2021-01-21 16:21:00 -08:00
David Garske
aa64a8e835
Merge pull request #3672 from embhorn/zd11547
...
Fix FIPS compile errors
2021-01-21 16:08:53 -08:00
toddouska
a8cfc23683
Merge pull request #3642 from SparkiDev/ecdsa_set_k_one_loop
...
ECDSA set k: WOLFSSL_ECDSA_SET_K_ONE_LOOP only tries k and fails when…
2021-01-21 15:56:36 -08:00
toddouska
5837d5e8de
Merge pull request #3649 from dgarske/stm_aesgcm_perf
...
STM32 AES GCM crypto hardware performance improvements
2021-01-21 15:55:58 -08:00
toddouska
22e6d52b7b
Merge pull request #3667 from SparkiDev/sp_fixes_4
...
SP int: fix _sp_mul_d inclusion checks
2021-01-21 15:49:03 -08:00
toddouska
b825e51d23
Merge pull request #3664 from SparkiDev/sp_math_all_ppc64
...
SP math all: Fixes for PPC64 compiler
2021-01-21 15:48:34 -08:00
toddouska
848ae3e514
Merge pull request #3668 from SparkiDev/jenkins_fixes_2
...
Compress: fix unused vars
2021-01-21 15:46:30 -08:00
Eric Blankenhorn
fd8527c15e
Fix FIPS compile errors
2021-01-21 15:27:42 -06:00
Sean Parkinson
55be60a63e
Compress: fix unused vars
...
configure: C_EXTRA_FLAGS="-fdebug-types-section -g1" --disable-memory
--enable-mcapi --enable-ecc --enable-sha512 --with-libz
2021-01-20 13:09:43 +10:00
Sean Parkinson
e3182ff06e
SP int: fix _sp_mul_d inclusion checks
...
configuration: --disable-asn --disable-filesystem --disable-shared --enable-cryptonly --enable-sp=smallrsa2048 --enable-sp-math --disable-dh --disable-ecc --disable-sha224 --enable-rsavfy --enable-rsapss
2021-01-20 12:38:10 +10:00
David Garske
9044f709c1
Add support for STM32_AESGCM_PARTIAL build option to speedup platforms that allow AAD header sizes that are not a multiple of 4 bytes. ZD 11364.
2021-01-19 13:54:53 -08:00
David Garske
ea5af87de3
Revert of uint32_t and uint8_t changes in PR #3658 , which caused warnings.
2021-01-19 13:54:26 -08:00
David Garske
9ea5041d9d
Benchmark for GMAC (AES GCM GHASH).
2021-01-19 13:42:25 -08:00
Sean Parkinson
523119289b
SP math all: Fixes for PPC64 compiler
2021-01-19 21:30:36 +10:00
Sean Parkinson
7d869a43b4
ECDSA set k: WOLFSSL_ECDSA_SET_K_ONE_LOOP only tries k and fails when it fails
2021-01-19 14:07:03 +10:00
Sean Parkinson
949af909bf
SP int: make sp_copy more available
2021-01-19 11:01:00 +10:00
Sean Parkinson
6a5e802cc4
Disable algs: fix code to compile with various algs off/on
...
benchmark.c: Only X25519/Ed25519/X448/Ed448 now compiles
asn.c/asn.h: Only DSA now compiles
2021-01-19 09:54:21 +10:00
toddouska
5b7e6ccc14
Merge pull request #3613 from SparkiDev/sp_rand_prime_len
...
SP rand_prime: fix length check
2021-01-18 15:23:15 -08:00
toddouska
267b00e0a2
Merge pull request #3620 from haydenroche5/zd11434
...
Clamp the normalization value at the end of sp_mont_norm.
2021-01-18 15:21:03 -08:00
toddouska
85faf974aa
Merge pull request #3621 from SparkiDev/sp_mac_arm64
...
SP arm64 MAC: stop non-ct mod inv from using x29
2021-01-18 15:19:46 -08:00
toddouska
87a0ee5ef4
Merge pull request #3622 from SparkiDev/sp_int_fixes_2
...
SP math all: doco fix and don't assign 0 to o
2021-01-18 15:19:06 -08:00
toddouska
1e9394d5a8
Merge pull request #3627 from elms/EVP/ofb_rc4_size
...
EVP: return proper cipher type and block size
2021-01-18 15:13:55 -08:00
toddouska
563e3c6b60
Merge pull request #3628 from SparkiDev/even_mp_test
...
RSA/DH test: even number error check fixup
2021-01-18 13:39:54 -08:00
toddouska
d514cc31b3
Merge pull request #3631 from SparkiDev/rsa_vfy_only_sp_fixes
...
RSA: verify only build fixes
2021-01-18 13:38:52 -08:00
toddouska
3bae6e2dc2
Merge pull request #3633 from SparkiDev/ecc_gen_z_fix
...
ECC gen z: convert blinding value to Montgomery form before using
2021-01-18 13:36:13 -08:00
Sean Parkinson
ac76ef8ee7
Curve25519: replace uint64_t with word64
...
Remove usages of stdint.h types
Added a sword type for signed words.
2021-01-18 17:30:36 +10:00
John Safranek
0ac43bb095
Merge pull request #3618 from haydenroche5/ocsp_self_signed_issue
...
Modify ParseCertRelative to ensure issuerKeyHash gets parsed and copi…
2021-01-14 14:22:06 -08:00
Takashi Kojo
e21fddf553
add wc_RsaSetRNG to doc
2021-01-14 10:42:49 +09:00
Daniel Pouzzner
1e49bc2e82
asn.c/asn.h: fix --disable-ecc --enable-dsa.
2021-01-13 13:55:06 -06:00
Daniel Pouzzner
f8013580df
sp_int.c: fix 4 instances of "Value stored to 'o' is never read" found by LLVM9 scan-build.
2021-01-12 15:01:28 -06:00
Daniel Pouzzner
fb82114866
sp_int.c: pay attention to the return value from sp_copy(), for general hygiene and to eliminate an inlining-related warning in sp_todecimal().
2021-01-12 14:58:29 -06:00
Elms
8fec1de07c
EVP: address CTR block size
2021-01-11 12:03:01 -08:00
Elms
a6535528f3
EVP: add tests for openssl block size (including RC4)
2021-01-11 12:03:01 -08:00
Elms
0cccf58fec
EVP: return proper cipher type for AES OFB
2021-01-11 12:03:01 -08:00
Hayden Roche
a3cc4110b0
Clamp the normalization value at the end of sp_mont_norm.
2021-01-11 09:59:11 -06:00
Sean Parkinson
f955c92008
ECC gen z: convert blinding value to Montgomery form before using
2021-01-07 11:30:58 +10:00
John Safranek
d4e13796c2
M1 Support
...
We separate out 64-bit desktop support based on the Intel check. With
the advent of the new Apple chip, ARM can also be a desktop processor.
Detect it like we do the Intel 64-bit, and treat it similarly with
respect to fast and normal math.
2021-01-06 09:21:07 -08:00
Sean Parkinson
cd0670cbd7
RSA: verify only build fixes
...
configuration: --disable-ecc --disable-dh --disable-aes --disable-aesgcm
--disable-sha512 --disable-sha384 --disable-sha --disable-poly1305
--disable-chacha --disable-md5 --disable-sha3 --enable-cryptonly
--disable-inline --enable-rsavfy --disable-asn --disable-oaep
--disable-rng --disable-filesystem --enable-sp=rsa2048 --enable-sp-math
Fixes to make code build again.
2021-01-06 11:58:15 +10:00
Sean Parkinson
10722fba14
RSA/DH test: even number error check fixup
...
Configuration: --enable-sp=3072
Test only enabled when SP is used.
Return codes checked are those we expect from SP.
Code, with configuration, is compiled so that 2048-bit operations are
not going to SP and the error returns were not correct.
2021-01-06 09:39:24 +10:00
Sean Parkinson
1b94309a6c
SP math all: doco fix and don't assign 0 to o
...
o is not used after that point so no need to zero it.
2021-01-05 10:40:34 +10:00
Sean Parkinson
2a2b194d71
SP arm64 MAC: non-ct mod inv not use so many registers
2021-01-05 10:23:14 +10:00
Chris Conlon
54f072fd8d
Merge pull request #3607 from douzzer/WOLFSSL_TEST_SUBROUTINE
...
test.c: add WOLFSSL_TEST_SUBROUTINE macro to make subtests optionally static
2021-01-04 10:10:56 -07:00
Hayden Roche
96ece3ac7d
Modify ParseCertRelative to ensure issuerKeyHash gets parsed and copied into the
...
decoded cert for self-signed CA certs.
The bit of code that does this copy was previously inside a conditional that's
only entered if the certificate is not self-signed. The primary purpose of this
conditional is to set the maxPathLen field. It's possible that the copying of
the issuerKeyHash was mistakenly included in the "else" block here, when it
should be outside.
2021-01-04 10:34:09 -06:00
Sean Parkinson
413bde9146
Merge pull request #3608 from tmael/sp_squre
...
Fix SP integer square
2021-01-04 16:29:40 +10:00
Sean Parkinson
faf7d307b4
Merge pull request #3606 from dgarske/zd11438
...
Fix for possible ECC sign memory leak with custom "k"
2021-01-04 15:39:53 +10:00
Tesfa Mael
01c27068c1
Correct SP x->used with sp_clamp()
2021-01-03 20:08:06 -08:00
Sean Parkinson
40ab08be45
SP rand_prime: fix length check
...
-ve length indicates to use a BBS prime (last two bits set)
2021-01-04 12:31:59 +10:00
Daniel Pouzzner
9dc8721032
linuxkm: on kernels >= 4.12, use kvmalloc()/kvfree() and a partial implementation of realloc() leveraging them, rather than kmalloc()/kfree()/krealloc(). this makes large allocations possible and relatively safe. note that the realloc() implementation fails gracefully when the supplied pointer is larger than the page size, but otherwise works normally.
2020-12-31 00:30:35 -06:00