summaryrefslogtreecommitdiff
path: root/lib/libcrypto/asn1
AgeCommit message (Collapse)Author
2014-07-10Inline the only use of the HEX_SIZE macro and nuke both DECIMAL_SIZE andJoel Sing
HEX_SIZE. ok beck@ miod@
2014-07-10Stop including standard headers via cryptlib.h - pull in the headers thatJoel Sing
are needed in the source files that actually require them. ok beck@ miod@
2014-07-10make asn1 free safe to call with null pointers of any type.Ted Unangst
ok jsing miod
2014-07-10delete some casts. ok miodTed Unangst
2014-07-09ASN1_STRING_free can handle NULL, so callers don't need to check. ok miodTed Unangst
2014-07-09remove unused, private version strings except SSL_version_strBrent Cook
Also remove unused des_ver.h, which exports some of these strings, but is not installed. ok miod@ tedu@
2014-06-27Remove M_ASN1_New* macros which are only used in X509_PKEY_new() are obfuscateMiod Vallat
it to hide memory leaks in the error paths, and fix aforementioned memory leaks. ok jsing@ logan@ deraadt@
2014-06-24Unifdef -UNO_SYS_TYPES_HMiod Vallat
2014-06-24Remove previously commented out wrong code, as well as the comment saying thisMiod Vallat
is incorrect code.
2014-06-22nuke unused test programs; ok jsingTheo de Raadt
2014-06-12tags as requested by miod and teduTheo de Raadt
2014-06-09do not include dso.h where it is not needed; ok miodTheo de Raadt
2014-06-07malloc() result does not need a cast.Theo de Raadt
ok miod
2014-06-01There is no need for is{upper,lower}() tests before to{lower,uppper}(),Theo de Raadt
since all other characters are mapped through transparently. ok jsing
2014-05-31Change the actual default for returned asn1 strings to be utf8 in the code,Bob Beck
rather than only in the config file, to trip people up later. Found, and fix pleaded for by <spider@skuggor.se> who apparently spent hours chasing it down. ok miod@
2014-05-31Add a comment documenting where libssl depends upon the current (objectionable)Miod Vallat
behaviour of this code, to prevent people from blindly changing it.
2014-05-30more: no need for null check before freeTheo de Raadt
ok tedu guenther
2014-05-30remove CONST_STRICT. ok beck deraadtTed Unangst
2014-05-30no need for null check before free. from Brendan MacDonellTed Unangst
2014-05-29convert 53 malloc(a*b) to reallocarray(NULL, a, b). that is 53Theo de Raadt
potential integer overflows easily changed into an allocation return of NULL, with errno nicely set if need be. checks for an allocations returning NULL are commonplace, or if the object is dereferenced (quite normal) will result in a nice fault which can be detected & repaired properly. ok tedu
2014-05-29Everything sane has stdio, and FILE *. we don't need ifdefs for this.Bob Beck
ok to firebomb from tedu@
2014-05-25remove unused shit. from Alexander SchrijverTed Unangst
2014-05-24We have shared global variables - unifdef OPENSSL_EXPORT_VAR_AS_FUNCTION.Joel Sing
ok miod@ beck@
2014-05-24Almost nothing actually needs to include <openssl/e_os2.h>, however byJoel Sing
including it they get <openssl/opensslconf.h>. So instead of pulling in <openssl/e_os2.h>, just pull in <openssl/opensslconf.h>. "go ahead" miod@
2014-05-24Expand OPENSSL_{GLOBAL,EXTERN} macros that I missed last time around,Joel Sing
since they are hiding in the #define forest. ok miod@
2014-05-22if (x) free(x) -> free(x); semantic patch generated with coccinelle, carefullyMiod Vallat
eyeballed before applying. Contributed by Cyril Roelandt on tech@
2014-05-22KNF.Joel Sing
2014-05-22KNF.Joel Sing
2014-05-22No uses of UTF8_{getc,putc}() in ports, so remove them from the public header.Philip Guenther
ok miod@
2014-05-20Bring UTF8_{getc,putc} up-to-date: it's been a decade since 5- and 6-bytePhilip Guenther
encodings and encoding of surrogate pair code points were banned. Add checks for those, both to those functions and to the code decoding the BMP and UNIV encodings. ok miod@
2014-05-18If you need to allocate `a + b' bytes of memory, then don't allocate `a + b*2',Miod Vallat
this is confusing and unnecessary. Help (coz I got confused) and ok guenther@ beck@
2014-05-18Make sure UTF8_getc() is invoked with the proper buffer size.Miod Vallat
ok beck@ guenther@
2014-05-15Fix memory leaks upon failure.Miod Vallat
ok beck@
2014-05-15Replace ASN1_GENERALIZEDTIME_adj(), ASN1_UTCTIME_adj() andMiod Vallat
ASN1_TIME_to_generalizedtime() with wrappers around their former implementations, making sure memory allocated is freed in all failure cases. help and ok from beck@ and Brendan MacDonell.
2014-05-12Bring back ASN1_seq_pack(), ASN1_seq_unpack(), ASN1_pack_string() andMiod Vallat
ASN1_unpack_string() from the NO_ASN1_OLD purge; turns out that some Ruby extensions still use them, unfortunately, so we need to give them some more time to catch up on ``recent'' interfaces. Riding on the libcrypto major bump.
2014-05-04i give up. reuse problem is unfixable. dlg says puppet crashes.Ted Unangst
2014-04-27Use C99 initializers for the various FOO_METHOD structs. More readable, andMiod Vallat
avoid unreadable/unmaintainable constructs like that: const EVP_PKEY_ASN1_METHOD cmac_asn1_meth = { EVP_PKEY_CMAC, EVP_PKEY_CMAC, 0, "CMAC", "OpenSSL CMAC method", 0,0,0,0, 0,0,0, cmac_size, 0, 0,0,0,0,0,0,0, cmac_key_free, 0, 0,0 }; ok matthew@ deraadt@
2014-04-27static const char * = "" -> static const char[] = "", to produce shorter code.Miod Vallat
No functional change.
2014-04-27Unifdef -U OPENSSL_BUILD_SHLIBCRYPTO, since all it causes under Unix is toMiod Vallat
redefine OPENSSL_EXTERN from `extern' to `extern'.
2014-04-26Replace all use of ERR_add_error_data with ERR_asprintf_error_data.Bob Beck
This avoids a lot of ugly gymnastics to do snprintfs before sending the bag of strings to ERR, and eliminates at least one place in dso_dlfctn.c where it was being called with the incorrect number of arguments and using random things off the stack as addresses of strings. ok krw@, jsing@
2014-04-23Unifdef -UPEDANTIC. ok beck@ tedu@Miod Vallat
2014-04-23Remove duplicate pointer assignment in ASN1_primitive_free(); Dirk EnglingMiod Vallat
2014-04-23Casting from a const unsigned char ** to a const unsigned char ** seems...Joel Sing
unnecessary. Remove the temporary ugly casts - the comments even call them that! ok guenther@
2014-04-23Make sure ret->name is NULL'ed before return when freeing.Bob Beck
from Dirk Engling <erdgeist@erdgeist.org>
2014-04-23Rather than sprinkling magical numbers everywhere, we can use sizeof()Bob Beck
for the size of a fixed size array. From Dirk Engling <erdgeist@erdgeist.org>
2014-04-22null a pointer to prevent double free. from Dirk EnglingTed Unangst
2014-04-22fix memory leaks. from Dirk EnglingTed Unangst
2014-04-21improve realloc/calloc/malloc patterns; ok guentherTheo de Raadt
2014-04-21Delete #if 0'd time related functions which are totally expired.Theo de Raadt
No point even seeing these when we do the 2038 audit later on...
2014-04-21fix accidentally deleted deref.Bob Beck