summaryrefslogtreecommitdiffstats
path: root/crypto/objects
AgeCommit message (Collapse)Author
2016-05-24Fix a mem leak on an error path in OBJ_NAME_add()Matt Caswell
If lh_OBJ_NAME_insert() fails then the allocated |onp| value is leaked. RT#2238 Reviewed-by: Richard Levitte <levitte@openssl.org> (cherry picked from commit 0a618df059d93bf7fe9e3ec92e04db8bc1eeff07)
2015-09-15RT4044: Remove .cvsignore files.Rich Salz
Reviewed-by: Matt Caswell <matt@openssl.org>
2015-06-08return correct NID for undefined objectDr. Stephen Henson
Reviewed-by: Tim Hudson <tjh@openssl.org> (cherry picked from commit 0fb9990480919163cc375a2b6c0df1d8d901a77b)
2015-06-02RT3230: Better test for C identifierAnnie Yousar
objects.pl only looked for a space to see if the name could be used as a C identifier. Improve the test to match the real C rules. Signed-off-by: Rich Salz <rsalz@akamai.com> Reviewed-by: Matt Caswell <matt@openssl.org> (cherry picked from commit 591b7aef05b22cba09b179e5787a9bf40dfc9508)
2015-05-23Fix the update target and remove duplicate file updatesRichard Levitte
We had updates of certain header files in both Makefile.org and the Makefile in the directory the header file lived in. This is error prone and also sometimes generates slightly different results (usually just a comment that differs) depending on which way the update was done. This removes the file update targets from the top level Makefile, adds an update: target in all Makefiles and has it depend on the depend: or local_depend: targets, whichever is appropriate, so we don't get a double run through the whole file tree. Reviewed-by: Rich Salz <rsalz@openssl.org> (cherry picked from commit 0f539dc1a2f45580435c39dada44dd276e79cb88) Conflicts: Makefile.org apps/Makefile test/Makefile
2015-05-13Call of memcmp with null pointers in obj_cmp()Hanno Böck
The function obj_cmp() (file crypto/objects/obj_dat.c) can in some situations call memcmp() with a null pointer and a zero length. This is invalid behaviour. When compiling openssl with undefined behaviour sanitizer (add -fsanitize=undefined to compile flags) this can be seen. One example that triggers this behaviour is the pkcs7 command (but there are others, e.g. I've seen it with the timestamp function): apps/openssl pkcs7 -in test/testp7.pem What happens is that obj_cmp takes objects of the type ASN1_OBJECT and passes their ->data pointer to memcmp. Zero-sized ASN1_OBJECT structures can have a null pointer as data. RT#3816 Signed-off-by: Matt Caswell <matt@openssl.org> Reviewed-by: Rich Salz <rsalz@openssl.org> (cherry picked from commit 2b8dc08b74fc3c6d4c2fc855cc23bac691d985be)
2015-04-16Code style: space after 'if'Viktor Dukhovni
Reviewed-by: Matt Caswell <gitlab@openssl.org>
2015-03-05Unchecked malloc fixesMatt Caswell
Miscellaneous unchecked malloc fixes. Also fixed some mem leaks on error paths as I spotted them along the way. Reviewed-by: Tim Hudson <tjh@openssl.org> (cherry picked from commit 918bb8652969fd53f0c390c1cd909265ed502c7e) Conflicts: crypto/bio/bss_dgram.c
2015-02-10objects/obj_xref.h: revert reformat.Andy Polyakov
obj_xref.h was erroneously restored to pre-reformat state. Reviewed-by: Matt Caswell <matt@openssl.org>
2015-02-09Bring objects.pl output even closer to new format.Andy Polyakov
Reviewed-by: Matt Caswell <matt@openssl.org> (cherry picked from commit 849037169d98d070c27d094ac341fc6aca1ed2ca)
2015-02-09Harmonize objects.pl output with new format.Andy Polyakov
Reviewed-by: Tim Hudson <tjh@openssl.org> (cherry picked from commit 7ce38623194f6df6a846cd01753b63f361c88e57)
2015-02-04Make objxref.pl output in correct formatDr. Stephen Henson
Reviewed-by: Tim Hudson <tjh@openssl.org> (cherry picked from commit 6922ddee1b7b1bddbe0d59a5bbdcf8ff39343434)
2015-01-26Remove unused eng_rsax and related asm fileRich Salz
Reviewed-by: Andy Polyakov <appro@openssl.org>
2015-01-22Run util/openssl-format-source -v -c .Matt Caswell
Reviewed-by: Tim Hudson <tjh@openssl.org>
2015-01-22Further comment amendments to preserve formatting prior to source reformatMatt Caswell
(cherry picked from commit 4a7fa26ffd65bf36beb8d1cb8f29fc0ae203f5c5) Conflicts: crypto/x509v3/pcy_tree.c Reviewed-by: Tim Hudson <tjh@openssl.org>
2015-01-22mark all block comments that need format preserving so thatTim Hudson
indent will not alter them when reformatting comments (cherry picked from commit 1d97c8435171a7af575f73c526d79e1ef0ee5960) Conflicts: crypto/bn/bn_lcl.h crypto/bn/bn_prime.c crypto/engine/eng_all.c crypto/rc4/rc4_utl.c crypto/sha/sha.h ssl/kssl.c ssl/t1_lib.c Reviewed-by: Tim Hudson <tjh@openssl.org>
2014-11-13Fix cross reference table generator.Dr. Stephen Henson
If the hash or public key algorithm is "undef" the signature type will receive special handling and shouldn't be included in the cross reference table. Reviewed-by: Tim Hudson <tjh@openssl.org> (cherry picked from commit 55f7fb8848b6e4bec291724a479e1580d6f407d6)
2014-08-06Fix OID handling:Emilia Kasper
- Upon parsing, reject OIDs with invalid base-128 encoding. - Always NUL-terminate the destination buffer in OBJ_obj2txt printing function. CVE-2014-3508 Reviewed-by: Dr. Stephen Henson <steve@openssl.org> Reviewed-by: Kurt Roeckx <kurt@openssl.org> Reviewed-by: Tim Hudson <tjh@openssl.org>
2014-07-09Please Clang's sanitizer, addendum.Andy Polyakov
(cherry picked from commit d11c70b2c2a655d112fa72d34c6702e9aa2eff79)
2014-06-27Rebuild OID table.Dr. Stephen Henson
2014-06-27Fix OID encoding for one component.Dr. Stephen Henson
OIDs with one component don't have an encoding. PR#2556 (Bug#1) (cherry picked from commit 95791bf94150f2e3dc96fd2462627aaf354e92e4)
2014-02-26CABForum EV OIDs for Subject Jurisdiction of Incorporation or Registration.Rob Stradling
(cherry picked from commit ffcc832ba6e17859d45779eea87e38467561dd5d)
2014-02-20Show the contents of the RFC6962 Signed Certificate Timestamp List ↵Rob Stradling
Certificate/OCSP Extensions. Add the RFC6962 OIDs to the objects table. (backport from master branch)
2014-02-02Add AES-NI+SHA256 stitch registrations (from master).Andy Polyakov
2014-02-01objxref.pl: improve portability.Andy Polyakov
(cherry picked from commit 71fa3bc5ece9121d1aa9bb513b5641e9ea605e14)
2013-10-01Add new OIDs from RFC5753Dr. Stephen Henson
Add OIDs for KDF schemes from RFC5753 and add cross references for each type and the appropriate digest to use. (cherry picked from commit 6af440ced43d766e418c2eb0cda1525eecd3e62b) Conflicts: crypto/objects/obj_dat.h crypto/objects/obj_mac.num
2013-10-01Add new OID to pSpecified from PKCS#1Dr. Stephen Henson
(cherry picked from commit e423c360fd2670b151c8e61439b36a77c77f77c3) Conflicts: crypto/objects/obj_dat.h crypto/objects/obj_mac.num
2013-01-13Fix some clang warnings.Ben Laurie
2012-06-06Version skew reduction.Ben Laurie
2012-04-22objxref.pl: improve portability [from HEAD].Andy Polyakov
2012-04-22PR: 2239Dr. Stephen Henson
Submitted by: Dominik Oepen <oepen@informatik.hu-berlin.de> Add Brainpool curves from RFC5639. Original patch by Annie Yousar <a.yousar@informatik.hu-berlin.de>
2012-04-07Initial experimental support for X9.42 DH parameter format to handleDr. Stephen Henson
RFC5114 parameters and X9.42 DH public and private keys. (backport from HEAD)
2012-01-02incomplete provisional OAEP CMS decrypt supportDr. Stephen Henson
2011-10-09Backport PSS signature support from HEAD.Dr. Stephen Henson
2011-10-06? crypto/aes/aes-armv4.SDr. Stephen Henson
? crypto/aes/aesni-sha1-x86_64.s ? crypto/aes/aesni-x86_64.s ? crypto/aes/foo.pl ? crypto/aes/vpaes-x86_64.s ? crypto/bn/.bn_lib.c.swp ? crypto/bn/armv4-gf2m.S ? crypto/bn/diffs ? crypto/bn/modexp512-x86_64.s ? crypto/bn/x86_64-gf2m.s ? crypto/bn/x86_64-mont5.s ? crypto/ec/bc.txt ? crypto/ec/diffs ? crypto/modes/a.out ? crypto/modes/diffs ? crypto/modes/ghash-armv4.S ? crypto/modes/ghash-x86_64.s ? crypto/modes/op.h ? crypto/modes/tst.c ? crypto/modes/x.h ? crypto/objects/.obj_xref.txt.swp ? crypto/rand/diffs ? crypto/sha/sha-512 ? crypto/sha/sha1-armv4-large.S ? crypto/sha/sha256-armv4.S ? crypto/sha/sha512-armv4.S Index: crypto/objects/obj_xref.c =================================================================== RCS file: /v/openssl/cvs/openssl/crypto/objects/obj_xref.c,v retrieving revision 1.9 diff -u -r1.9 obj_xref.c --- crypto/objects/obj_xref.c 5 Nov 2008 18:38:58 -0000 1.9 +++ crypto/objects/obj_xref.c 6 Oct 2011 20:30:21 -0000 @@ -110,8 +110,10 @@ #endif if (rv == NULL) return 0; - *pdig_nid = rv->hash_id; - *ppkey_nid = rv->pkey_id; + if (pdig_nid) + *pdig_nid = rv->hash_id; + if (ppkey_nid) + *ppkey_nid = rv->pkey_id; return 1; } @@ -144,7 +146,8 @@ #endif if (rv == NULL) return 0; - *psignid = (*rv)->sign_id; + if (psignid) + *psignid = (*rv)->sign_id; return 1; } Index: crypto/x509/x509type.c =================================================================== RCS file: /v/openssl/cvs/openssl/crypto/x509/x509type.c,v retrieving revision 1.10 diff -u -r1.10 x509type.c --- crypto/x509/x509type.c 26 Oct 2007 12:06:33 -0000 1.10 +++ crypto/x509/x509type.c 6 Oct 2011 20:36:04 -0000 @@ -100,20 +100,26 @@ break; } - i=X509_get_signature_type(x); - switch (i) + i=OBJ_obj2nid(x->sig_alg->algorithm); + if (i && OBJ_find_sigid_algs(i, NULL, &i)) { - case EVP_PKEY_RSA: - ret|=EVP_PKS_RSA; - break; - case EVP_PKEY_DSA: - ret|=EVP_PKS_DSA; - break; - case EVP_PKEY_EC: - ret|=EVP_PKS_EC; - break; - default: - break; + + switch (i) + { + case NID_rsaEncryption: + case NID_rsa: + ret|=EVP_PKS_RSA; + break; + case NID_dsa: + case NID_dsa_2: + ret|=EVP_PKS_DSA; + break; + case NID_X9_62_id_ecPublicKey: + ret|=EVP_PKS_EC; + break; + default: + break; + } } if (EVP_PKEY_size(pk) <= 1024/8)/* /8 because it's 1024 bits we look
2011-09-05make updateBodo Möller
2011-08-23Add RC4-MD5 and AESNI-SHA1 "stitched" implementations [from HEAD].Andy Polyakov
2011-08-11Add XTS OIDs from HEAD.Dr. Stephen Henson
2011-03-23make update (1.0.1-stable)Richard Levitte
This meant a slight renumbering in util/libeay.num due to symbols appearing in 1.0.0-stable. However, since there's been no release on this branch yet, it should be harmless.
2010-11-17sync OIDs with HEADDr. Stephen Henson
2010-01-25PR: 2149Dr. Stephen Henson
Submitted by: Douglas Stebila <douglas@stebila.ca> Fix wap OIDs.
2009-11-10PR: 2091Dr. Stephen Henson
Submitted by: Martin Kaiser <lists@kaiser.cx>, Stephen Henson Approved by: steve@openssl.org If an OID has no short name or long name return the numerical representation.
2009-04-06Use basename of objxref.pl not whole path in generated header.Dr. Stephen Henson
2009-04-04Fix for VC++ 6 which chokes on the empty argument.Dr. Stephen Henson
2009-04-01Make update fixing duplicate ASN1 error codes.Dr. Stephen Henson
2009-03-25Update from stable branch.Dr. Stephen Henson
2009-02-10Add error checking to obj_xref.pl and add command line support for dataDr. Stephen Henson
file locations.
2008-11-12Revert the size_t modifications from HEAD that had led to moreGeoff Thorpe
knock-on work than expected - they've been extracted into a patch series that can be completed elsewhere, or in a different branch, before merging back to HEAD.
2008-11-05Update obsolete email address...Dr. Stephen Henson
2008-11-01More size_tification.Ben Laurie