645 Commits

Author SHA1 Message Date
Karel Miko
5fb4c9f89b another approach for dsa_int_validate_* 2017-09-14 17:21:48 +02:00
Karel Miko
aa5b9dafc4 fix dsa_int_validate_key related compiler warnings 2017-09-14 17:21:48 +02:00
Steffen Jaeckel
1625ce4001 re-factor & re-name internal dsa key validation 2017-09-14 17:21:48 +02:00
Karel Miko
053ba6d600 introducing dsa_verify_key_ex 2017-09-14 17:21:48 +02:00
Karel Miko
2505e3b609 add basic validity tests to dsa_set 2017-09-14 17:21:48 +02:00
Andrew Janke
cfce691a50 initialize ltc_mp to force allocation under all compilers, including clang on macOS 2017-09-14 17:07:49 +02:00
Karel Miko
c927e4315a dsa_verify_hash: fix wycheproof - appending unused 0's 2017-09-02 14:16:52 +02:00
Karel Miko
7e4bd971de dsa_verify_hash: properly handle (=reject) negative r, s 2017-09-02 14:16:52 +02:00
Karel Miko
59857ba5e0 fix DSA dependency on RSA #285 2017-09-01 18:24:15 +02:00
Karel Miko
9ea6247da1 Revert "add basic validity tests to dsa_set"
This reverts commit 9003e87e5aaee40e5e95277172e3c8079663a082.
2017-08-30 00:03:04 +02:00
Karel Miko
9003e87e5a add basic validity tests to dsa_set 2017-08-30 00:01:00 +02:00
Steffen Jaeckel
43e6860925 fix RSA - wycheproof "wrong length" 2017-08-29 17:26:14 +02:00
Karel Miko
fe9af6cfbd RSA: handle wycheproof test vectors - Legacy:missing NULL 2017-08-29 17:26:14 +02:00
Karel Miko
105abdd8cd GCM: 0 size IV is not valid #273 2017-08-28 16:10:30 +02:00
Steffen Jaeckel
33e70b427a CRYPT_INVALID_KEYSIZE isn't only used for block ciphers 2017-08-26 12:03:35 +02:00
Steffen Jaeckel
0afbefc549 bump version 2017-08-23 22:35:32 +02:00
Steffen Jaeckel
bb9d397975 default ChaCha to ChaCha20 2017-08-16 11:49:25 +02:00
Karel Miko
de8a53a2e5 ocb3_test cosmetics
[skip ci]
2017-08-13 18:15:44 +02:00
Karel Miko
2a52c68f2e fix lint issues from #199 2017-08-13 14:54:39 +02:00
Steffen Jaeckel
d5d4cadbde PKA_{D,R}SA shouldn't be public 2017-08-09 16:06:11 +02:00
Steffen Jaeckel
a247583e63 add error-codes to crypt_constants 2017-08-09 16:06:11 +02:00
Steffen Jaeckel
91e5e8350b ltc_dh_set_type can be hidden as well 2017-08-09 16:06:11 +02:00
Steffen Jaeckel
d22b20833e we don't expose internal structs 2017-08-09 16:06:11 +02:00
Steffen Jaeckel
22822417c9 really define LTC_{DE,EN}CRYPT 2017-08-09 16:06:11 +02:00
Larry Bugbee
a3a199e14b update crypt_sizes.c 2017-08-09 16:06:11 +02:00
Larry Bugbee
7a2aabf47e update crypt_constants.c 2017-08-09 16:06:11 +02:00
Karel Miko
b79ae63408 add missing items to crypt_sizes 2017-08-09 16:06:11 +02:00
Karel Miko
0286b36ad6 fix doxygen warnings (as mentioned in #228)
[skip ci]
2017-08-09 09:44:12 +02:00
Steffen Jaeckel
65dc00e23a align HASH_PROCESS() macro 2017-08-08 19:05:59 +02:00
Karel Miko
f647baa778 OCBv3: ocb3_init taglen check 2017-08-07 18:24:59 +02:00
Karel Miko
af63d0a55f OCBv3: improved handling of taglen in ocb3_done 2017-08-07 18:24:59 +02:00
Steffen Jaeckel
ac4687d88d also put LTC_TEST_DBG in crypt_build_settings 2017-08-07 16:18:15 +02:00
Steffen Jaeckel
7a59f71af8 fix warning
warning: 'ltc_asn1_type {aka enum ltc_asn1_type_}' is promoted to 'int' when passed through '...'
        type = va_arg(args, ltc_asn1_type);
note: (so you should pass 'int' not 'ltc_asn1_type {aka enum ltc_asn1_type_}' to 'va_arg')
note: if this code is reached, the program will abort
2017-08-07 16:04:57 +02:00
Steffen Jaeckel
32355d04bb fix endianness detection for some versions of gcc
This fixes #254
2017-08-07 16:04:57 +02:00
Steffen Jaeckel
9f020b17df limit malloc'ed data in eax_decrypt_verify_memory() 2017-08-07 16:04:36 +02:00
Karel Miko
6ac1c5fa34 OCBv3: fix demos/timing failures 2017-08-07 07:48:21 +02:00
Steffen Jaeckel
3ecd18763b OCBv3: better taglen limitation 2017-08-03 13:40:57 +02:00
Steffen Jaeckel
3b4d39ea45 OCBv3: improve a bit when ARGCHK'ing pointers
* it didn't really make sense to check that the _in_ pointer is NULL
* instead we should check that _in_ and _out_ are not NULL when there's
  something to process
2017-08-03 13:40:26 +02:00
Steffen Jaeckel
868c5a82c3 OCBv3: fix handling of empty plaintext 2017-08-03 13:19:12 +02:00
Steffen Jaeckel
0c2ff4a1b0 OCBv3: small review
* better LTC_ARGCHK()
* move unnecessary functions from API to be static
* limit malloc'ed data in ocb3_decrypt_verify_memory()
2017-08-02 18:55:34 +02:00
Steffen Jaeckel
d77cf0e248 OCBv3: implement RFC7253 compliance
This fixes #256
2017-08-02 17:45:59 +02:00
Steffen Jaeckel
1aaa5abb33 ocb3: check the length of the nonce 2017-08-02 14:41:46 +02:00
Steffen Jaeckel
b2448c593a ocb3: properly handle empty AAD
* allow passing "no additional data" to ocb3_decrypt_verify_memory() and
  ocb3_encrypt_authenticate_memory()
* ensure that the caller didn't want to add AAD
2017-08-01 14:44:37 +02:00
Steffen Jaeckel
4805c89adb add ARGTYPE to crypt_build_settings 2017-08-01 14:21:11 +02:00
Steffen Jaeckel
129bc7175f beautify dh & rsa 2017-07-21 10:16:19 +02:00
Steffen Jaeckel
61eb98b76e add compile-time check for sprng requirements 2017-07-20 12:47:19 +02:00
Steffen Jaeckel
a46d6eb819 remove define of LTC_NO_FILE when defining LTC_NOTHING
it doesn't make sense to define this opt-out option especially
since there's no way to undefine it again.
2017-07-19 16:44:37 +02:00
Karel Miko
909b4954a9 fix MS Windows/64bit related warnings 2017-07-14 19:59:03 +02:00
Steffen Jaeckel
535358ec28 bump version 2017-07-13 14:57:45 +02:00
Steffen Jaeckel
24e69b2956 more printf() clean-up
* remove last occurences in non-test code
* minimize in tests
2017-07-11 15:29:45 +02:00