Steffen Jaeckel
171eae5378
asn1: use LTC_SET_ASN1 macro to access ltc_asn1_list elements
2014-08-28 14:02:56 +02:00
Steffen Jaeckel
8ce125f8a8
mp_rand() assumes the number of digits and not the bitsize as parameter
2014-08-28 13:30:26 +02:00
Steffen Jaeckel
d51715db72
pkcs#1 v1.5 decode: fix missing check of PS length in EMSA mode
2014-08-28 13:30:26 +02:00
Steffen Jaeckel
5eb9743410
rsa_verify_hash: fix possible bleichenbacher signature attack
2014-08-28 13:30:26 +02:00
Jonathan Herzog
3324da2601
Fixed small padding error in the PKCS#1 PSS code.
...
The existing LTC code for padding meassages for PSS signatures
contained a small error. In particular, the PSS-passing algorithms is
supposed to be given (bitlength of key - 1) as an argument. The LTC
code passes (bitlength of key), and subtracts 1 in the middle of the
PSS-padding. This subtraction unfortunately comes too late: a
calculation using that argument has already been made. Fortunately,
this bug only appeared if the bit-length of the key was 1 mod 8, and
so is unlikely to show up in practice. Still, this patch fixes the
problem.
Conflicts:
src/pk/pkcs1/pkcs_1_pss_decode.c
2014-08-28 13:30:25 +02:00
Steffen Jaeckel
01c34dc236
trim trailing spaces
2014-08-24 18:25:24 +02:00
Steffen Jaeckel
f8449f55d9
trim trailing spaces
2014-08-07 01:36:03 +02:00
Steffen Jaeckel
155a54ba40
add LTC prefix to most macros
2014-07-17 10:50:36 +02:00
Steffen Jaeckel
98893c077b
fix possible free of not yet allocated key parameters
...
There would have been a call to mp_clear_multi() of all the key parameters
that are not yet allocated, in the case where the calculations of p, q,
tmp1 or tmp2 created an error.
This also includes a proposed improvement from the OLPC project to free
elements in the reverse order as they were allocated.
2014-07-11 16:44:43 +02:00
Steffen Jaeckel
30278d1121
fix possible missing free of rnd and rndi
...
There could have been a 'goto error', which misses the free of rnd and
rndi even if they were initialized.
This could happen in cases where a private key operation was done and
afterwards one of the operations like reading back or conversion, would
have failed (which is likely not to happen)
This also includes a proposed improvement from the OLPC project to free
elements in the reverse order as they were allocated.
2014-06-15 11:51:38 +02:00
Steffen Jaeckel
ea9b2a858a
der_encode_utf8_string: calm coverity
2014-05-25 00:35:03 +02:00
Steffen Jaeckel
50d10790e3
trim trailing spaces
2014-05-25 00:35:03 +02:00
Steffen Jaeckel
dc31ca545f
dsa_make_key: fix free of wrong pointer resulting in double-free
2014-05-09 23:07:40 +02:00
Steffen Jaeckel
c9f93f6571
dsa_make_key: remove surplus semicolon
2014-05-09 22:43:29 +02:00
Karel Miko
e9a0a27917
DSA params+key generation according FIPS-186-4 (part 1)
2014-05-09 17:58:50 +02:00
Karel Miko
77b4b16030
dsa_make_key minor isuue
2014-05-09 17:58:50 +02:00
Karel Miko
a43bb0fda6
dsa_encrypt_key small correction
2014-05-09 17:58:50 +02:00
Karel Miko
655336f0cb
tuning RSA interoperability + small fixes
2014-05-09 17:58:50 +02:00
Karel Miko
67a547086c
DSA sign improvement
2014-05-09 17:58:50 +02:00
Karel Miko
3908c70d68
tuning DSA key generation
2014-05-09 17:58:50 +02:00
Karel Miko
e600ab9d35
dsa_sign_hash: testing k < q
2014-05-09 16:26:24 +02:00
Karel Miko
72022edb8d
dsa_make_key: improved testing x < q
2014-05-09 16:26:24 +02:00
Steffen Jaeckel
26743d0749
ecc_mulmod_timing: fix compiler warnings
2014-05-08 13:06:24 +02:00
Steffen Jaeckel
b10c03aead
flush content of CVS/SVN tags
2014-04-29 21:13:49 +02:00
Steffen Jaeckel
2bdebb3932
dh: remove including of c-files
2014-04-04 00:38:08 +02:00
Steffen Jaeckel
71ccad06bd
dh: remove unused variables
2014-04-04 00:38:07 +02:00
Steffen Jaeckel
0aee5f3217
fix wrong spelled macros
2014-03-04 21:50:18 +01:00
Steffen Jaeckel
84298440f4
trim trailing spaces
2014-03-04 21:50:17 +01:00
Steffen Jaeckel
65fd19c1fb
dh: fix renamed macro
2014-02-25 10:09:35 +01:00
Steffen Jaeckel
e48838559b
der_encode_setof: fix compiler warning when compiling for windows 64bit
2014-02-16 18:41:32 +01:00
Steffen Jaeckel
8e7777b554
trim trailing spaces/clean up
2014-02-16 18:41:28 +01:00
Steffen Jaeckel
bf1ccb629b
fix rsa_sign_saltlen_get_max_ex()
2013-10-14 14:16:44 +02:00
Steffen Jaeckel
aacfec441e
add rsa_sign_saltlen_get_max_ex()
2013-10-14 14:16:42 +02:00
Steffen Jaeckel
73c201da1f
add rsa_get_size()
2013-10-14 14:16:41 +02:00
Steffen Jaeckel
fb65cd0772
fix clang compiler warnings
2013-10-02 01:03:40 +02:00
Steffen Jaeckel
a667a93d52
trim trailing spaces
2013-10-02 01:02:58 +02:00
Steffen Jaeckel
e531af7add
ecc: fix compiler warnings
2013-03-22 15:14:44 +02:00
Steffen Jaeckel
9203472789
dsa: fix compiler warning
2013-03-22 15:14:43 +02:00
Christopher Brown
2cb8c44113
der fixes and additions
2013-02-13 10:01:20 +01:00
Steffen Jaeckel
2cd666f284
rsa_import: prevent double-free
2012-04-24 18:08:13 +02:00
Gregory Pakosz
1346ccdee8
replaced free(in) by XFREE(in) at line 56
2011-07-12 05:56:48 -07:00
Steffen Jaeckel
8dc8a2d551
Added define LTC_RSA_BLINDING to be able to disable rsa blinding
2011-03-21 22:50:49 +01:00
Steffen Jaeckel
380693edd9
fixed error causing segmentation fault
2011-03-21 21:17:59 +01:00
Steffen Jaeckel
25bd5c1275
added missing handling of new type LTC_ASN1_RAW_BIT_STRING in der_encode_sequence_multi()
2011-03-21 21:12:46 +01:00
Nikos Mavrogiannopoulos
fa22e791d4
RSA and DSA public keys are stored using the SubjectPublicKeyInfo format.
2011-03-21 19:24:10 +01:00
Nikos Mavrogiannopoulos
8c2850f8d9
Added RSA blinding (requires mp_rand()).
2011-03-21 08:26:41 +01:00
Nikos Mavrogiannopoulos
ed6897d90f
DSA private keys are being exported to a compatible with OpenSSL and GnuTLS format.
2011-03-21 08:26:27 +01:00
Steffen Jaeckel
6fecec107d
rejoined diffie hellman code from ltc 1.05, thanks to Alexander Kurpiers
2011-01-18 20:06:03 +01:00
Steffen Jaeckel
c3018d69d0
removed gcc compiler warnings
2010-06-16 20:02:11 +02:00
Steffen Jaeckel
59f9c00f98
removed IAR compiler warnings
2010-06-16 20:02:01 +02:00