Paul Bakker
92b8dc0535
Fixed memory leaks in tests
2013-07-03 17:22:31 +02:00
Paul Bakker
891998e0c3
Added extra debug information to memory_buffer_alloc_status()
2013-07-03 17:22:31 +02:00
Paul Bakker
bd5524471a
Removed memory leak in PKCS#12 code
2013-07-03 17:22:31 +02:00
Paul Bakker
4632083c78
Removed memory leaks in PKCS#5 functions
2013-07-03 17:22:31 +02:00
Paul Bakker
e07c431eb3
Test suite automatically uses buffer-based memory allocator if present
...
Eat your own dog-food..
2013-07-03 17:22:31 +02:00
Paul Bakker
6e339b52e8
Memory-allocation abstraction layer and buffer-based allocator added
2013-07-03 17:22:31 +02:00
Paul Bakker
f863485fea
Remove memory leak in PKCS#5 self test
2013-07-03 13:31:52 +02:00
Paul Bakker
abf2f8fcf9
zlib compression/decompression skipped on empty blocks
2013-06-30 14:57:46 +02:00
Paul Bakker
e5bffc319d
Removed redundant includes
2013-06-30 14:53:06 +02:00
Paul Bakker
d2681d82e2
Renamed sha2.{c,h} to sha256.{c,h} and sha4.{c,h} to sha512.{c,h}
2013-06-30 14:49:12 +02:00
Paul Bakker
9e36f0475f
SHA2 renamed to SHA256, SHA4 renamed to SHA512 and functions accordingly
...
The SHA4 name was not clear with regards to the new SHA-3 standard. So
SHA2 and SHA4 have been renamed to better represent what they are:
SHA256 and SHA512 modules.
2013-06-30 14:34:05 +02:00
Paul Bakker
3866b9f4b5
Removed redundant inclusion
2013-06-30 12:53:14 +02:00
Paul Bakker
62534dd1d8
programs/util/strerror now handles decimal and hexidecimal input
2013-06-30 12:45:07 +02:00
Paul Bakker
63899feca8
Removed redundant bugfix from ChangeLog (Already done in 1.2.8)
2013-06-30 12:20:03 +02:00
Paul Bakker
03a8a79516
Programs adapted to use polarssl_strerror() instead of error_strerror()
2013-06-30 12:18:08 +02:00
Paul Bakker
fd3eac5786
Cleaned up ECP error codes
2013-06-29 23:31:33 +02:00
Paul Bakker
5dc6b5fb05
Made supported curves configurable
2013-06-29 23:26:34 +02:00
Paul Bakker
e2ab84f4a1
Renamed error_strerror() to the less conflicting polarssl_strerror()
...
Ability to keep old function error_strerror() as well with
POLARSSL_ERROR_STRERROR_BC. Also works with
POLARSSL_ERROR_STRERROR_DUMMY.
2013-06-29 18:35:41 +02:00
Paul Bakker
89fe7f4388
compat.sh modified to support new ssl_server2 and ssl_client2
...
capabilities
2013-06-29 18:35:41 +02:00
Paul Bakker
c1516be99d
ssl_server2 and ssl_client2 adapted to support maximum protocol version
2013-06-29 18:35:41 +02:00
Paul Bakker
2fbefde1d8
Client and server now filter sent and accepted ciphersuites on minimum
...
and maximum protocol version
2013-06-29 18:35:40 +02:00
Paul Bakker
59c28a2723
SSL v2 handshake should also handle dynamic ciphersuites
2013-06-29 18:35:40 +02:00
Paul Bakker
f8d018a274
Made asn1_get_alg() and asn1_get_alg_null() as generic functions
...
A generic function for retrieving the AlgorithmIdentifier structure with
its parameters and adapted X509, PKCS#5 and PKCS#12 to use them.
2013-06-29 18:35:40 +02:00
Paul Bakker
ce6ae233cb
Macro-ized the final internal OID functions
2013-06-29 18:35:40 +02:00
Paul Bakker
47fce02bd8
Defines around module-dependent OIDs
2013-06-29 18:35:40 +02:00
Paul Bakker
7749a22974
Moved PKCS#12 cipher layer based PBE detection to use OID database
2013-06-29 18:32:16 +02:00
Paul Bakker
dd1150e846
Macro-ized single and double attribute functions in OID database
2013-06-28 17:20:22 +02:00
Paul Bakker
bd51ad538d
Re-ordered OID internals. Made macro for oid_XXX_from_asn1() functions
2013-06-28 16:54:23 +02:00
Paul Bakker
9b5e885611
PKCS#5 PBES2 now uses OID database for algorithm detection
2013-06-28 16:12:50 +02:00
Paul Bakker
6d72f33441
Updated README with simple formatting
2013-06-28 10:39:28 +02:00
Paul Bakker
407a0da160
Moved __cplusplus extern statement to include struct definitions as well.
2013-06-27 14:29:21 +02:00
Paul Bakker
c5a79cca53
Fixed compiler warnings for unused parameter ssl
2013-06-26 15:08:35 +02:00
Paul Bakker
b9d3cfa114
Split up GCM into a start/update/finish cycle
2013-06-26 15:08:29 +02:00
Paul Bakker
534f82c77a
Made ctr_drbg_init_entropy_len() non-static and defined
2013-06-25 16:47:55 +02:00
Paul Bakker
3c5ef71322
Cleanup up non-prototyped functions (static) and const-correctness in programs
2013-06-25 16:37:45 +02:00
Paul Bakker
b6c5d2e1a6
Cleanup up non-prototyped functions (static) and const-correctness
...
More fixes based on the compiler directives -Wcast-qual -Wwrite-strings
-Wmissing-prototypes -Wmissing-declarations. Not everything with regards
to -Wcast-qual has been fixed as some have unwanted consequences for the
rest of the code.
2013-06-25 16:25:17 +02:00
Paul Bakker
169b7f4a13
Fixed gcm.c formatting (removed redundant spaces)
2013-06-25 15:06:54 +02:00
Paul Bakker
bda7cb76fa
Fixed minor comment typo
...
(cherry picked from commit da7fdbd534
)
2013-06-25 15:06:54 +02:00
Paul Bakker
b0713c7e1f
Updated PKCS#12 define dependencies
...
(cherry picked from commit 602c31be23
)
2013-06-25 15:06:54 +02:00
Paul Bakker
f67edd9db8
Made x509parse PKCS#12 and PKCS#5 tests dependent on defines
...
(cherry picked from commit db7ea6f162
)
2013-06-25 15:06:53 +02:00
Paul Bakker
38b50d73a1
Moved PKCS#12 PBE functions to cipher / md layer where possible
...
The 3-key and 2-key Triple DES PBE functions have been replaced with a
single pkcs12_pbe() function that handles both situations (and more).
In addition this allows for some PASSWORD_MISMATCH checking
(cherry picked from commit 14a222cef2
)
2013-06-25 15:06:53 +02:00
Paul Bakker
0e34235644
Fixed values for 2-key Triple DES in cipher layer
...
(cherry picked from commit 2be71faae4
)
2013-06-25 15:06:53 +02:00
Paul Bakker
a4232a7ccb
x509parse_crt() and x509parse_crt_der() return X509 password related codes
...
POLARSSL_ERR_X509_PASSWORD_MISMATCH is returned instead of
POLARSSL_ERR_PEM_PASSWORD_MISMATCH and
POLARSSL_ERR_X509_PASSWORD_REQUIRED instead of
POLARSSL_ERR_PEM_PASSWORD_REQUIRED
Rationale: For PKCS#8 encrypted keys the same are returned
(cherry picked from commit b495d3a2c7
)
2013-06-25 15:06:53 +02:00
Paul Bakker
72823091c2
Removed redundant free()s
...
(cherry picked from commit 1fc7dfe2e2
)
2013-06-25 15:06:53 +02:00
Paul Bakker
cf445ffc4e
Added missing free()
...
(cherry picked from commit ff3a4b010b
)
2013-06-25 15:06:53 +02:00
Paul Bakker
9bcf16c55d
Centralized module option values in config.h
...
Allow user-defined settings without editing header files by using
POLARSSL_CONFIG_OPTIONS in config.h
(cherry picked from commit 6fa5488779
)
Conflicts:
include/polarssl/config.h
2013-06-25 15:06:53 +02:00
Paul Bakker
28144decef
PKCS#5 v2 PBES2 support and use in PKCS#8 encrypted certificates
...
The error code POLARSSL_ERR_X509_PASSWORD_MISMATCH is now properly
returned in case of an encryption failure in the padding. The
POLARSSL_ERR_X509_PASSWORD_REQUIRED error code is only returned for PEM
formatted private keys as for DER formatted ones it is impossible to
distinguish if a DER blob is PKCS#8 encrypted or not.
(cherry picked from commit 1fd4321ba2
)
Conflicts:
include/polarssl/error.h
scripts/generate_errors.pl
2013-06-25 15:06:52 +02:00
Paul Bakker
b0c19a4b3d
PKCS#5 module added. Moved PBKDF2 functionality inside and deprecated
...
old PBKDF2 module.
(cherry picked from commit 19bd297dc8
)
Conflicts:
include/polarssl/error.h
scripts/generate_errors.pl
2013-06-25 15:06:52 +02:00
Paul Bakker
fc4f46fa9a
Fixed bignum.c and bn_mul.h to support Thumb2 and LLVM compiler
...
(cherry picked from commit 52b845be34
)
2013-06-25 15:06:52 +02:00
Paul Bakker
531e294313
Fixed location of brackets in pkcs12.c
...
(cherry picked from commit 67812d396c
)
2013-06-25 15:06:52 +02:00