Steffen Jaeckel
54d7c6782b
clean-up macros
...
no need to enable them separately now
2019-06-09 20:41:04 +02:00
Steffen Jaeckel
233f8af490
draft-ietf-curdle-pkix is meanwhile rfc8410
2019-06-09 20:41:02 +02:00
Steffen Jaeckel
52a24ca3a3
add Curve25519 API
2019-06-09 20:40:40 +02:00
Steffen Jaeckel
5ed32b73e6
improve ecc_test() output
2019-04-10 11:26:32 +02:00
Steffen Jaeckel
ee13f6ffec
let ssh_test() NOP silently
2018-12-31 17:22:28 +01:00
Steffen Jaeckel
b7874c5864
fix warnings when using other ARGTYPE's
2018-12-29 22:37:09 +01:00
Steffen Jaeckel
f95be00582
unconditonally create ssh_test()
2018-12-29 18:08:31 +01:00
Steffen Jaeckel
f6f70aa2ec
fix ssh tests when compiled w/o MPI provider
2018-12-29 18:08:07 +01:00
Karel Miko
ae2ab2083b
ecc_test cleanup
2018-11-07 09:25:08 +01:00
Karel Miko
dee704d063
padding_depad + PKCS7 - reject invalid pad 0
2018-10-29 07:26:40 +01:00
Karel Miko
2adc261612
wycheproof failing PKCS7 depadding test
2018-10-29 07:26:40 +01:00
Karel Miko
c2cdaaab4d
make LTC_ECCSIG_RFC7518 strict (again)
2018-10-13 18:48:49 +02:00
Russ Williams
b4b50cc0c6
Initial commit of SSH+ECDSA signature format
...
Wrap signature format in #ifdef LTC_SSH
Update docs
Code review fixes
Replace strcmp/memcmp with XSTRCMP/XMEMCMP for check-source
Fix for check-defines
XSTRCMP/XMEMCMP != 0
GCC7.3 wants only literal strings for sprintf format
Code review changes
Rework SSH decoding and tests
Fix encoding and tests
COMPARE_TESTVECTOR macro
Single return point in ssh_decode_sequence_multi
Actually use XSTRNCPY rather than just defining it
More code review fixes
Code review tweaks
Ensure it's not possible to read past buffer end
Keep track of size remaining, not end pointer
2018-10-12 10:22:10 +01:00
Steffen Jaeckel
f81bdc46e7
add more rsa-pkcs8 PBES2-RC2 test-files
2018-10-06 23:04:51 +02:00
Steffen Jaeckel
c96639bef6
add rsa-pkcs8 PBES2 AES and SHA512-224/256 test-files
2018-10-06 23:04:51 +02:00
Steffen Jaeckel
cbe65fe59a
add rsa-pkcs8 PBE-SHA1-3DES test-file
2018-10-06 23:04:51 +02:00
Karel Miko
8349eda5a5
fix LTC_EASY test failure
2018-10-06 23:04:51 +02:00
Karel Miko
e5a2683f5b
RSA - pkcs8 test keys
2018-10-06 23:04:51 +02:00
Karel Miko
2dd8bcdfe9
rsa_import_pkcs8 tests
2018-10-06 23:04:51 +02:00
Karel Miko
bf04bf18a4
add ecc_import_pkcs8
2018-10-06 23:04:51 +02:00
Karel Miko
59bc3b5885
make ecc_verify_hash_ex less strict (as it was before ecc_recover_key addition)
2018-10-05 07:44:15 +02:00
Karel Miko
ef20f2e656
remove unused macros
2018-10-04 23:29:12 +02:00
Russ Williams
88d9b6db26
Make ECC signature format explicit
...
Optionally return recovery ID from ecc_sign_hash()
Update documentation
Update tests for ECC recovery
Fix (v,r,s) signature format, regenerate recovery test
Fix over-freeing of private key
Code review fixes to docs
Rename LTC_ECCSIG_BLOCKCHAIN to LTC_ECCSIG_ETH to reflect original definition
Rename to LTC_ECCSIG_ETH27 to make clear it's using the Ethereum +27 convention
Code review changes - calculate recovery ID only if needed, type safety on signature format enum
Use enum for sigformat in docs, and add explanatory note for recid<0
Range checks on v, check RFC7518 signatures' length based on size of key. Fix for when order>prime.
Limit LET_ECCSIG_ETH27 to secp256k1 curve only
2018-09-29 21:07:41 +01:00
Russ Williams
76190521e3
Implementation of ecc_recover_key to obtain public key from hash+signature
...
Workaround for TFM missing sqrtmod_prime
Fix unused variable warnings with USE_TFM, make TomsFastMath a runtime check
Disable ecc_recover_key if no ecc_mul2add available
Wrap ecc_recover_key and its test in #ifdef LTC_ECC_SHAMIR
Fix unused variables when built without LTC_ECC_SHAMIR
Code review tweaks
Code review tweaks - remove sigformat, tidy up (de)allocation
Code review tweaks
2018-09-23 09:03:30 +01:00
Steffen Jaeckel
1a90da844c
only print der flexi-test on higher debug level
...
it's smashing the stack for some inputs :>
2018-09-07 11:58:54 +02:00
Steffen Jaeckel
6584569872
add another OID testcase for root-node 3
2018-09-07 08:24:25 +02:00
Steffen Jaeckel
079ed04b17
add OID testcase from x.690
2018-09-07 08:24:25 +02:00
Karel Miko
4fb0562a3b
fix -Wmissing-declarations -Wmissing-prototypes -Wmissing-noreturn
2018-07-07 19:54:08 +02:00
Karel Miko
4bec98f88c
rename ecc_get_curve to ecc_find_curve
2018-07-04 10:43:15 +02:00
Karel Miko
611ca6bf14
rename ecc_set_dp (+related) to ecc_set_curve
2018-07-04 10:41:10 +02:00
Karel Miko
fc056a645d
fix "make test" built with no math provider or multiple providers
2018-07-03 00:12:08 +02:00
Karel Miko
05d397d634
ECC improved import/export
2018-06-11 10:00:37 +02:00
Steffen Jaeckel
d9215be060
Remove katja
2018-06-03 19:19:58 +02:00
Steffen Jaeckel
7cfc0c93e6
use tomcrypt_private.h
2018-06-03 15:07:28 +02:00
buggywhip
8144209695
add XSalsa20
2018-05-31 11:58:21 -07:00
Steffen Jaeckel
0011f7f927
add generic test_process_dir()
2018-05-23 10:33:47 +02:00
Karel Miko
24c0eb84f9
ECC curves y^2 = x^3 + ax + b
2018-05-22 23:02:44 +02:00
Karel Miko
29af2d95cc
fix getting current time on MS Windows + improve gettimeofday/clock_gettime usage on UNIX
2018-05-04 16:42:47 +02:00
Steffen Jaeckel
62c2124b82
implement DER resursion limit
2018-04-11 11:15:21 +02:00
Steffen Jaeckel
ca91ae5a1f
add fortuna_add_random_event()
2018-04-09 23:30:27 +02:00
Karel Miko
6d33ecdbf9
consistent NUL byte handling in baseNN_encode
2018-03-28 07:46:31 +02:00
Karel Miko
229aec965c
enhanced base64 related tests
2018-03-27 21:06:30 +02:00
Karel Miko
b10bf8fa0d
make base64_decode relaxed mode less relaxed
2018-03-27 21:06:30 +02:00
Steffen Jaeckel
ed5025398b
check input of base16_decode()
2018-03-27 10:08:29 +02:00
Steffen Jaeckel
73e5330c47
add inlen parameter to base16_decode()
2018-03-27 10:08:29 +02:00
Karel Miko
065c89108e
base64_* use char *
for Base64 strings
2018-03-26 16:42:19 +02:00
Karel Miko
981f3ef844
base32_encode - make the output NUL-terminated
2018-03-25 22:17:46 +02:00
Karel Miko
7a7b773b3c
Revert "make base64_decode relaxed mode less relaxed"
...
This reverts commit e7117ea9df
.
2018-03-25 19:41:43 +02:00
Karel Miko
e7117ea9df
make base64_decode relaxed mode less relaxed
2018-03-25 15:46:49 +02:00
Steffen Jaeckel
6a48f7d184
add padding tests
2018-03-23 22:01:41 +01:00
Steffen Jaeckel
979a36b9bb
add possibility to seed PRNG as if it's imported
2018-03-23 15:16:13 +01:00
Steffen Jaeckel
9d72e81ce8
use 'char*' in base32
...
... instead of 'unsigned char*'
2018-03-22 16:12:56 +01:00
Steffen Jaeckel
3d99d9b443
add base16_{de,en}code()
2018-03-22 16:12:56 +01:00
Steffen Jaeckel
b026c23b0a
use do_compare_testvector() where possible
2018-03-22 16:12:56 +01:00
Steffen Jaeckel
e1cba4da7d
fix der_test and rsa_test when compiling for msvc
2018-03-22 16:12:56 +01:00
Steffen Jaeckel
e36e512459
use DO() macro in file_test
2018-03-22 16:12:56 +01:00
Steffen Jaeckel
ecd3fb714d
add do_compare_testvector()
2018-03-22 14:39:16 +01:00
Steffen Jaeckel
7fb108d884
add full-debug build to ci-tests
2018-03-10 17:37:54 +01:00
Steffen Jaeckel
3cfdd4bfdb
fix compilation with debug output enabled
2018-03-10 11:34:05 +01:00
Karel Miko
3cd8044290
Keccak
2018-03-08 07:18:33 +01:00
Steffen Jaeckel
9d03c38ea4
add flags to der_decode_sequence()
2018-02-25 20:42:26 +01:00
Steffen Jaeckel
7e2d163d1d
add testvectors from [1]
...
[1] https://misc.daniel-marschall.de/asn.1/oid_facts.html
2018-02-25 20:42:26 +01:00
Steffen Jaeckel
3431763275
update/add more DER tests
2018-02-25 20:42:26 +01:00
Steffen Jaeckel
b75c3ce9db
remove LTC_ASN1_CONSTRUCTED and LTC_ASN1_CONTEXT_SPECIFIC
2018-02-25 20:42:26 +01:00
Steffen Jaeckel
64875d3a8f
add ASN.1-length functions
2018-02-25 20:42:26 +01:00
Steffen Jaeckel
a898fde5b7
better debug output
2018-01-11 18:06:23 +01:00
Larry Bugbee
8ef60f7b47
add rabbit
2017-12-17 08:05:41 -08:00
Steffen Jaeckel
35c4d157d0
as of POSIX.1-2008 gettimeofday() is obsolete
2017-12-16 16:02:00 +01:00
Larry Bugbee
108ddf5b50
add Sosemanuk
2017-11-20 02:41:30 -08:00
Larry Bugbee
4341424ce9
Add Salsa20
2017-10-23 15:45:02 -07:00
Karel Miko
854a145c92
Base32: alpha_id >> id
2017-10-20 20:00:46 +02:00
Karel Miko
8674eb3097
base32_decode + base32_encode
2017-10-20 19:51:40 +02:00
Karel Miko
152513477b
fix return value of register_all_*()
2017-10-18 22:35:16 +02:00
Karel Miko
5a63e7ef7d
Serpent cipher
2017-10-18 17:21:46 +02:00
Steffen Jaeckel
735566993b
add crypt_mp_init()
2017-10-18 08:46:17 +02:00
Steffen Jaeckel
fdc6cd2013
improve tests and timing in regards to MPI provider selection
2017-10-18 08:46:17 +02:00
Karel Miko
a2dd766ed5
IDEA cipher
2017-10-16 21:20:33 +02:00
Steffen Jaeckel
e438dbc3bf
add ltc_mp_digit to sizes and tests
2017-10-03 18:43:32 +02:00
Steffen Jaeckel
c702ac6f1c
improve rsa_test a bit
2017-10-02 01:18:19 +02:00
Karel Miko
67f9064b71
missing rsa_free in _rsa_issue_301 test
2017-10-01 22:56:47 +02:00
Steffen Jaeckel
30b3a9a986
remove {MIN,MAX}_RSA_SIZE
2017-10-01 22:56:47 +02:00
Steffen Jaeckel
0500aaec45
add tests for MAX_RSA_SIZE sized openssl-standard RSA keys
2017-10-01 22:56:47 +02:00
Steffen Jaeckel
efa089e211
fixup #290
2017-10-01 22:56:47 +02:00
Karel Miko
98536fa5bf
add missing dsa_free to _dsa_wycheproof_test - fixes #303
2017-10-01 15:40:19 +02:00
Steffen Jaeckel
a9d9466694
beautify some strings
...
[skip-ci]
2017-09-20 15:06:28 +02:00
Karel Miko
66abefc54b
add dsa_wycheproof_test + fix old dsa tests
2017-09-20 11:59:03 +02:00
Karel Miko
3b663a199f
fix char* vs. const char* (tests related part)
2017-09-18 09:24:19 +02:00
Steffen Jaeckel
1fa8caff6c
fix call to gettimeofday()
...
as of `man gettimeofday`
"The use of the timezone structure is obsolete;
the tz argument should normally be specified as NULL."
2017-08-16 11:52:40 +02:00
Steffen Jaeckel
a65cfb8dbe
make it possible to 'make all' w/o an MPI provider
2017-08-07 21:11:42 +02:00
Steffen Jaeckel
28ecdd5d12
minor improvements
...
[skip ci]
2017-08-07 16:33:38 +02:00
Karel Miko
e20e204b8c
dh_set_key + dsa_set_key API change described in #248
2017-07-11 00:13:26 +02:00
Steffen Jaeckel
a6aef23438
dh_make_key() is now dh_generate_key()
2017-07-04 10:30:39 +02:00
Steffen Jaeckel
3c2e0d6686
dsa_make_key_ex() is now dsa_generate_key()
2017-07-04 10:25:38 +02:00
Steffen Jaeckel
dbeaefd65b
remove LTC_{DH,DSA}_KEY_INITIALIZER
2017-07-04 10:25:38 +02:00
Steffen Jaeckel
d64880eeb1
add dsa_set_pqg_dsaparam()
2017-06-28 16:07:54 +02:00
Steffen Jaeckel
35e0c5fc71
clean-up a bit around DSA
...
* comments
* dsa_test()
* order of alloc/free of key parts
2017-06-28 16:07:32 +02:00
Steffen Jaeckel
0aad68c20d
clean-up some PK tests
...
no need to test the same functionality multiple times
these tests were multiplied for the XX_import_radix() functions which
are gone now.
2017-06-28 14:44:06 +02:00
Steffen Jaeckel
cfff656e25
re-factor dsa_make_key() etc.
2017-06-28 14:40:30 +02:00
Steffen Jaeckel
ed149c9396
add tests for radix_to_bin()
2017-06-28 14:40:30 +02:00
Steffen Jaeckel
c493a2a0a3
re-factor dh_export_radix() to dh_export_key()
2017-06-27 22:09:21 +02:00