Sean Parkinson
befe15ddb9
Add configure option to cache when using small stack
2018-07-17 09:36:49 +10:00
Sean Parkinson
6ef800e5f7
Cache Sha256 for small stack when asked in random
...
Small stack builds see SHA-256 allocating W a lot.
Cache the SHA-256 object in DRBG when WOLFSSL_SMALL_STACK_CACHE is
defined.
Call free function on SHA-256 object now that it is required.
2018-07-17 09:33:24 +10:00
Sean Parkinson
88a2531652
Cache the data allocated in SHA-2 Transform functions
...
SHA-2 algorithms allocate W each call to transform when using
WOLFSSL_SMALL_STACK.
Put a pointer into the SHA-2 object to cache W.
Change code to call the SHA-2 Free functions now that they are required.
Only cache when WOLFSSL_SMALL_STACK_CACHE is defined.
2018-07-17 09:17:39 +10:00
Sean Parkinson
514a949557
Small stack fixes
...
Changes to DH and SSL/TLS code to dynamically allocate large stack
variables when compiled with WOLFSSL_SMALL_STACK.
2018-07-17 09:04:00 +10:00
Sean Parkinson
87f378efb5
Remove special case SHA-384 copy code
...
SHA-384 implementation has a GetHash API and TLS code uses it.
2018-07-17 08:16:46 +10:00
John Safranek
49fefe176e
DTLS and Atomic Encrypt Callback
...
When using the encrypt callback, the DTLS sequence number isn't incremented. Moved the increment to later in the BuildMessage() function.
2018-07-16 13:33:03 -07:00
Carie Pointer
ea769b831c
Fix tab indentation
2018-07-16 13:09:45 -07:00
Carie Pointer
dbe0ac6fec
Update configure to enable des3 when building OpenSSH
2018-07-16 09:49:23 -07:00
John Safranek
00fd7ff8de
Prime Number Testing
...
1. Added some new ifdef clauses to tfc and integer so that
the prime checking is available when using RSA, DSA, or DH.
A couple functions used were dependent on ECC being enabled.
2018-07-13 17:42:35 -07:00
toddouska
f0422bec41
Merge pull request #1681 from dgarske/pk_keygen
...
Added ECC and Curve25519 Key Generation PK callback support
2018-07-13 14:03:13 -07:00
Chris Conlon
f59fb0df8e
add custom print to test.c for PB
2018-07-13 14:58:48 -06:00
Chris Conlon
eeb50099d9
initial Nucleus port with PB changes
2018-07-13 14:58:37 -06:00
toddouska
1337f7ddec
Merge pull request #1674 from dgarske/derchainsz
...
Fix for max cert chain size calculation
2018-07-13 13:53:35 -07:00
kaleb-himes
ddd6563442
Dependencies for SGX project updated
2018-07-13 13:18:15 -06:00
toddouska
6c1778d373
Merge pull request #1669 from cconlon/mqxfixes
...
fixes for MQX classic 4.0 with IAR-EWARM
2018-07-13 11:59:28 -07:00
toddouska
223c71b96c
Merge pull request #1673 from ejohnstown/configure-update
...
Yet Another Configure Update
2018-07-13 11:55:08 -07:00
David Garske
0a19dc0940
Don't run new cert chain test if RSA is disabled (test chain contains RSA certs).
2018-07-13 11:41:06 -07:00
David Garske
2f00c0b465
Added test case for new server ECDHE PK callback.
2018-07-13 10:45:36 -07:00
JacobBarthelmeh
71d8946ee6
Merge pull request #1678 from cariepointer/osp/openssh
...
Move function prototypes from wolfss/ssl.h and openssl/ssl.h to appropriate header files for OpenSSH compatibility
2018-07-13 10:05:18 -06:00
Eric Blankenhorn
9bc0e0c4fc
Static analysis fixes ( #1658 )
...
* Static analysis fixes
* Fixes for zd4071, zd4074, zd4093-zd4094, zd4096, zd4097-zd4104.
* Add test cases.
2018-07-13 09:02:09 -07:00
JacobBarthelmeh
f22f33606a
Merge pull request #1684 from ejohnstown/distcheckfix
...
add missing certificates to the automake include
2018-07-13 09:41:10 -06:00
Sean Parkinson
ffc6cf4eb8
Add support for maximum DH key size
2018-07-13 17:36:42 +10:00
John Safranek
771e349925
Prime Number Testing
...
1. Moved a few functions around in tfm.c and integer.c.
2. Added some new ifdef clauses to tfc and integer so that the prime checking is available when using RSA, DSA, or DH.
3. Added an internal version of function wc_DhSetKey and wc_DsaImportParamsRaw that always checks to see if the prime value is prime. Modified the original function to be a wrapper.
2018-07-12 17:22:44 -07:00
John Safranek
0240cc7795
add missing certificates to the automake include
2018-07-12 17:06:02 -07:00
John Safranek
997a377310
Prime Number Testing
...
1. In wc_DhGenerateParams(), changed the call to mp_prime_is_prime() to
mp_prime_is_prime_ex().
2. In wc_MakeDsaParameters(), changed the call to mp_prime_is_prime() to
mp_prime_is_prime_ex().
3. Added wc_CheckProbablePrime_ex in RSA that also takes an RNG to call
mp_prime_is_prime_ex(). If RNG is NULL, call mp_prime_is_prime().
4. Rewrite wc_CheckProbablePrime() in terms of
wc_CheckProbablePrime_ex().
2018-07-12 15:00:13 -07:00
Carie Pointer
7d5da4d122
Fix typo in function name
2018-07-12 14:40:46 -07:00
David Garske
0ce6cbd4c4
Added API unit test for wolfSSL_CTX_use_certificate_chain_file_format
.
2018-07-12 13:22:21 -07:00
kaleb-himes
1b965491d9
Solve through settings.h instead
2018-07-12 14:09:57 -06:00
John Safranek
f7c5b27bfc
Merge pull request #1675 from toddouska/zero-error
...
make SOCKET_PEER_CLOSED_E consistent between read and 2 write cases
2018-07-12 12:53:48 -07:00
Chris Conlon
cadd556b3a
cast result of bitwise not back to original type to prevent compiler warnings
2018-07-12 13:46:55 -06:00
David Garske
eeece1df1e
Fix for duplicate declaration of EccMakeKey
.
2018-07-12 12:13:10 -07:00
David Garske
81d13e15d5
Added ECC and Curve25519 Key generation callback support for HAVE_PK_CALLBACKS
. The TLS server side ECDHE could not correctly handle PK callback based shared secret calculation using a hardware based generated key. Refactor internal functions to use the callback ctx getter API.
2018-07-12 11:52:54 -07:00
John Safranek
d486df50aa
fix an error where mp_copy was used instead of mp_sub_d
2018-07-12 11:03:41 -07:00
MJSPollard
93d7891701
Added different tls version support for asio
2018-07-12 11:59:58 -06:00
MJSPollard
d8dff3e4de
Merge branch 'master' of https://github.com/wolfSSL/wolfssl into wolfASIO
2018-07-12 11:57:34 -06:00
David Garske
40d0e7f711
Merge pull request #1677 from ejohnstown/gcc-arm-update
...
GCC-ARM README Update
2018-07-12 10:27:07 -07:00
Carie Pointer
c1af8d2190
Move function prototypes from wolfss/ssl.h and openssl/ssl.h to appropriate header files for OpenSSH compatibility
2018-07-12 08:13:51 -07:00
John Safranek
5908230d20
Prime Number Testing
...
1. Fixed variable name typo in DH for the FFDHE 8192-bit q value.
2. Updated some error strings in wolfSSL_BN_is_prime_ex().
3. Changed the calls to mp_prime_is_prime_ex() in fp_randprime() and
mp_randprime() so they go back to the 8 rounds of MR, which is more than
adequate in this situation.
2018-07-11 16:24:41 -07:00
John Safranek
2f638a0ae1
GCC-ARM README Update
...
Added directions for building wolfSSL using the gcc-arm-none-eabi tools.
2018-07-11 16:05:02 -07:00
toddouska
23687f44bc
Merge pull request #1643 from ejohnstown/altnames
...
Subject Alt Name Matching
2018-07-11 13:20:58 -07:00
Todd Ouska
d639939a07
make SOCKET_PEER_CLOSED_E consistent between read and 2 write cases
2018-07-11 13:00:29 -07:00
David Garske
05cfeae3ce
Fix for handling max cert chain size. It was not accounting for the 3 byte header in max size calculation.
2018-07-11 12:32:49 -07:00
John Safranek
eb32935081
Configure Update
...
1. Fix typo.
2. Change the parsing of the -D options to be more POSIX friendly.
Removed the "==" and replaced the multi escaped [] with a test command.
2018-07-11 12:01:05 -07:00
Chris Conlon
0f2b5ca181
fixes for MQX classic 4.0 with IAR-EWARM
2018-07-11 10:54:24 -06:00
toddouska
df6c496c4e
Merge pull request #1671 from SparkiDev/x25519_asm_fix
...
Fix for Curve25519 ASM
2018-07-11 09:50:57 -07:00
toddouska
c1a9945656
Merge pull request #1670 from JacobBarthelmeh/UnitTests
...
check that fp max bits is large enough before test
2018-07-11 09:49:22 -07:00
Sean Parkinson
9281f30deb
Fix for Curve25519 ASM
...
On rare occasions, multiplication and/or squaring result had top bit set
after overflow add - must to be reduced in that case.
2018-07-11 11:53:53 +10:00
John Safranek
239880a9de
Subject Alt Name Matching
...
1. Removed an external test tag from a failure test case. Ends up leaving a thread still running on exit.
2018-07-10 17:07:48 -07:00
David Garske
e2dec618d8
Merge pull request #1667 from ejohnstown/certgentime
...
Cert Gen Time
2018-07-10 14:40:37 -07:00
John Safranek
0e06f6413d
Prime Number Testing
...
1. Update the function wolfSSL_BN_is_prime_ex to use mp_prime_is_prime_ex.
2. Modified fast and normal mp_prime_is_prime_ex() to use random numbers
that are in the range 2 < a < n-2.
2018-07-10 14:30:53 -07:00