John Safranek
dbfd5dffaf
added parameter checks
2016-05-24 11:21:06 -07:00
John Safranek
c0cbc97b06
add AES-CMAC
2016-05-23 17:50:36 -07:00
toddouska
504081e602
Merge pull request #421 from ejohnstown/limit-country-code
...
Limit Country Name size
2016-05-19 16:05:15 -07:00
David Garske
c1507957c4
Added a benchmark for ECC encrypt/decrypt when enabled via "HAVE_ECC_ENCRYPT" or "--enable-eccencrypt --enable-hkdf".
2016-05-19 11:42:00 -07:00
John Safranek
bae0fe9b63
MakeCertReq() was not checking return codes correctly for the SetFoo()
...
functions.
2016-05-18 15:14:23 -07:00
John Safranek
5c8daa0ac6
1. SetName() should return error if country code isn't 2 bytes.
...
2. MakeCert() was not checking return codes correctly for the SetFoo()
functions.
3. Added error code for invalid country code length.
2016-05-18 15:04:40 -07:00
John Safranek
03e6f7cca3
RFC 5280 Appendix A.1 states that the Country Name in a certificate
...
shall have a size of 2 octets. Restrict country name length to 2 or 0.
2016-05-18 10:39:18 -07:00
David Garske
2ad9d41641
Performance improvement for fast math mp_clear to use fp_zero (memset) instead of fp_clear(ForceZero). Added new mp_forcezero function for clearing/free'ing sensitive private key data. Changed ECC and RSA to use mp_forcezero to explicitly handle private key clearing.
2016-05-12 11:50:34 -07:00
David Garske
440956f8d4
Fixed new issue with ecc_projective_add_point not free'ing the local x, y, z if fast math was disabled. Formatting cleanup in integer.c.
2016-05-11 08:47:30 -07:00
David Garske
d71d0f2cb4
Fix with fast math disabled so ecc_projective_add_point uses temp local variable for x,y,z result.
2016-05-09 13:29:25 -07:00
David Garske
880b2e454b
Refactor of the ecc_projective_add_point and ecc_projective_dbl_point functions to eliminate duplicate versions. Modified new single functions to work with normal, fast and alt_ecc_size math options. Careful use of mp_clear to retain original performance.
2016-05-09 09:51:11 -07:00
David Garske
1b602d783c
Fast math correction of "sizeof" to use (). Updates to tfm and ecc comments.
2016-05-09 09:51:11 -07:00
David Garske
5cbc4bdf29
Added new "WOLFSSL_DEBUG_MATH", which enables use of "mp_dump" to display information about an mp_int.
2016-05-09 09:51:11 -07:00
David Garske
a4782fcf01
Fix in fast math version of ecc_projective_dbl_point to use a local for x,y,z since ecc_point fp_int's are reduced size and cause math issues with ALT_ECC_SIZE enabled. Added local stack variable cleanups for ecc_projective_add_point.
2016-05-09 09:51:11 -07:00
David Garske
0ddbe0e60e
Enhancement to RSA math function "_fp_exptmod" (non timing resistant version) to support WOLFSSL_SMALL_STACK, which moves the allocation of the 64 fp_int's from the stack to the heap.
2016-05-09 09:51:11 -07:00
David Garske
fa5dd01001
Fixes/improvements to the wolfCrypt ECC tests. Fixed bug with sharedA/sharedB being too small when BENCH_EMBEDDED is used and curve size over 256 bit. Added error message for ECC test failures, to show the curve size used. Fix to wc_ecc_verify_hash test to use digest that is not all zeros as that doesn't work correctly for non-Shamir ECC math. Changed return code for wc_ecc_check_check so its unique.
2016-05-09 09:51:11 -07:00
David Garske
a5d27853fa
Fixes to fp_mul and fp_div to clear any excess digits on the destination. Added compile-time check to confirm FP_SIZE is compatible with TFM_ acceleration defines enabled. Updated comments in other places where excess digits are cleared.
2016-05-09 09:51:11 -07:00
David Garske
7c3fbd7644
Fix for fp_copy() when used with ALT_ECC_SIZE so any excess digits on the destination that we didn't write to are set to zero.
2016-05-09 09:51:11 -07:00
David Garske
9001036e09
Fixes memory leak in the wc_RsaFunction if failure happens when using normal math (not fast math) and RSA_LOW_MEM is not defined.
2016-05-09 09:51:11 -07:00
Chris Conlon
8f3e1165a1
add Whitewood netRandom client library support
2016-05-05 15:31:25 -06:00
toddouska
ee21d33794
Merge pull request #407 from wolfSSL/embOS-port
...
embOS port
2016-05-05 13:27:27 -07:00
toddouska
f9f9546d0e
Merge pull request #408 from cconlon/header-fix
...
fix aes_asm.asm header format
2016-05-04 14:38:23 -07:00
kaleb-himes
6e26cac686
Reworking directories and simplify README
2016-05-04 13:03:05 -07:00
David Garske
822d71431e
Moved mem_track.h into wolfssl/wolfcrypt. Added new WOLFSSL_DEBUG_MEMORY option. Added documentation for using mem_track and new debug memory option.
2016-05-04 10:04:38 -07:00
kaleb-himes
8176c74b3e
Merge branch 'embOS-port' of https://github.com/wolfssl/wolfssl into embOS-port
2016-05-04 08:57:06 -07:00
Chris Conlon
d91ec3ce77
fix aes_asm.asm header format
2016-05-04 09:02:50 -06:00
kaleb-himes
d184f8b1aa
wolfSSL embOS port Initialize
...
self-review complete
Removed autogenerated files
2016-05-03 17:09:55 -06:00
Jacob Barthelmeh
05e56b75f6
scan-build, valgrind issues and fix issue with ExtractDate, struct tm
2016-05-03 09:22:16 -06:00
Jacob Barthelmeh
f88d82375e
add function wolfSSL_ASN1_TIME_to_string
2016-05-03 09:22:15 -06:00
Chris Conlon
78e62eddd7
fix visual studio code analysis warnings
2016-04-28 13:08:50 -06:00
Kaleb Himes
b2af02a783
Merge pull request #383 from kojo1/MDK5
...
fixes for MDK5 compiler
2016-04-26 16:11:59 -06:00
Chris Conlon
27814ca1df
omit NULL AlgorithmIdentifier parameter for ECDSA algoOID types in SetAlgoID
2016-04-21 14:32:28 -06:00
toddouska
86cbabf035
Merge pull request #392 from wolfSSL/aesni-update
...
AES-NI Update
2016-04-20 14:27:52 -07:00
Jacob Barthelmeh
659d6c0689
update oid value for secp160r1
2016-04-19 17:01:39 -06:00
Jacob Barthelmeh
e0a9b365cc
fix NID name in openssl compatibility
2016-04-19 13:17:32 -06:00
toddouska
0dbdc8eab0
Merge pull request #372 from dgarske/mingwfixes
...
MinGW fixes
2016-04-18 12:50:13 -07:00
John Safranek
4506839c6d
back out last commit. it was a pain to use.
2016-04-14 11:57:42 -07:00
John Safranek
526606e42f
added conditional assembly for the intel-format AES_NI decrypt procedures
2016-04-14 11:30:10 -07:00
John Safranek
5340ea0d79
fixed a missing operand swap in the AES-CBC decrypt by 6
2016-04-14 10:47:14 -07:00
Jacob Barthelmeh
f998851642
fix check on RSA key size
2016-04-14 09:33:25 -06:00
John Safranek
6f51c2a8f8
1. Fix bad opcode mnemonics in the intel-format source listing.
...
2. Update the aes.c file to call both format assembly routines the same
way.
2016-04-13 16:42:58 -07:00
John Safranek
c34944e389
added intel-format translations of new att-format AES-NI decrypt routines
2016-04-13 16:02:18 -07:00
John Safranek
9781fa3dc9
relabel jump points in new code with D (decrypt) mnemonics rather than E (encrypt)
2016-04-13 15:51:19 -07:00
John Safranek
57fce85531
modify AES-CBC with AESNI test to check all key sizes for each message size checked
2016-04-13 12:18:59 -07:00
John Safranek
13f002f186
only compile in the AES-CBC decrypt-by-size variant selected by define, default by 8 blocks at a time
2016-04-13 12:00:53 -07:00
John Safranek
451fd878f9
touching whitespace in assembly routines being touched right now
2016-04-13 11:48:25 -07:00
John Safranek
8524afc56a
1. Rename routine AES_CBC_decrypt_ex as AES_CBC_decrypt_by8
...
2. Added routine AES_CBC_decrypt_by6 that does six at a time.
3. Setting HAVE_AES_DECRYPT_BY6 or _BY8 (or not setting it) selects
the 6, 8, or 4 way version of the assembly routine.
4. Modified AES-NI decrypt test to loop checking against the test
bolus from 1 AES block to the whole 24 blocks.
2016-04-12 10:10:55 -07:00
Takashi Kojo
cfd5af341b
fixed test.c compile error and server.c/client.c/ssl.c warnings with MDK5 compiler.
2016-04-12 11:05:30 +09:00
toddouska
85505b99b9
Merge pull request #380 from cconlon/utasker
...
uTasker Port
2016-04-08 15:08:39 -07:00
Chris Conlon
7a0f8672e7
Merge pull request #375 from dgarske/stm32hashfixes
...
Fixes when using the STM32 with STM32F2_HASH defined.
2016-04-08 15:04:46 -06:00