From 4a2309d8058f17b675c178c4996662495981382e Mon Sep 17 00:00:00 2001 From: beck <> Date: Wed, 11 Feb 2015 03:55:42 +0000 Subject: get rid of OPENSSL_NO_CMS code we do not use. ok miod@ --- src/lib/libcrypto/cms/cms.h | 4 +--- src/lib/libcrypto/dsa/dsa_ameth.c | 25 +--------------------- src/lib/libcrypto/ec/ec_ameth.c | 23 +------------------- src/lib/libcrypto/err/err_all.c | 8 +++---- src/lib/libcrypto/gost/gostr341001_ameth.c | 16 +------------- src/lib/libcrypto/gost/gostr341001_pmeth.c | 7 +----- src/lib/libcrypto/pem/pem_lib.c | 11 +--------- src/lib/libcrypto/rsa/rsa_ameth.c | 16 +------------- src/lib/libcrypto/rsa/rsa_pmeth.c | 25 +--------------------- src/lib/libssl/src/crypto/cms/cms.h | 4 +--- src/lib/libssl/src/crypto/dsa/dsa_ameth.c | 25 +--------------------- src/lib/libssl/src/crypto/ec/ec_ameth.c | 23 +------------------- src/lib/libssl/src/crypto/err/err_all.c | 8 +++---- src/lib/libssl/src/crypto/gost/gostr341001_ameth.c | 16 +------------- src/lib/libssl/src/crypto/gost/gostr341001_pmeth.c | 7 +----- src/lib/libssl/src/crypto/pem/pem_lib.c | 11 +--------- src/lib/libssl/src/crypto/rsa/rsa_ameth.c | 16 +------------- src/lib/libssl/src/crypto/rsa/rsa_pmeth.c | 25 +--------------------- 18 files changed, 24 insertions(+), 246 deletions(-) (limited to 'src') diff --git a/src/lib/libcrypto/cms/cms.h b/src/lib/libcrypto/cms/cms.h index 0e4aa6f9fc..f08e2f8457 100644 --- a/src/lib/libcrypto/cms/cms.h +++ b/src/lib/libcrypto/cms/cms.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cms.h,v 1.5 2014/07/10 22:45:56 jsing Exp $ */ +/* $OpenBSD: cms.h,v 1.6 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project. */ @@ -58,9 +58,7 @@ #include -#ifdef OPENSSL_NO_CMS #error CMS is disabled. -#endif #ifdef __cplusplus extern "C" { diff --git a/src/lib/libcrypto/dsa/dsa_ameth.c b/src/lib/libcrypto/dsa/dsa_ameth.c index 20839b6207..8f7a73a481 100644 --- a/src/lib/libcrypto/dsa/dsa_ameth.c +++ b/src/lib/libcrypto/dsa/dsa_ameth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dsa_ameth.c,v 1.14 2014/07/13 12:45:01 miod Exp $ */ +/* $OpenBSD: dsa_ameth.c,v 1.15 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2006. */ @@ -66,9 +66,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "asn1_locl.h" @@ -595,26 +592,6 @@ dsa_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2) 0); } return 1; -#ifndef OPENSSL_NO_CMS - case ASN1_PKEY_CTRL_CMS_SIGN: - if (arg1 == 0) { - int snid, hnid; - X509_ALGOR *alg1, *alg2; - - CMS_SignerInfo_get0_algs(arg2, NULL, NULL, &alg1, &alg2); - if (alg1 == NULL || alg1->algorithm == NULL) - return -1; - hnid = OBJ_obj2nid(alg1->algorithm); - if (hnid == NID_undef) - return -1; - if (!OBJ_find_sigid_by_algs(&snid, hnid, - EVP_PKEY_id(pkey))) - return -1; - X509_ALGOR_set0(alg2, OBJ_nid2obj(snid), V_ASN1_UNDEF, - 0); - } - return 1; -#endif case ASN1_PKEY_CTRL_DEFAULT_MD_NID: *(int *)arg2 = NID_sha1; diff --git a/src/lib/libcrypto/ec/ec_ameth.c b/src/lib/libcrypto/ec/ec_ameth.c index b4ae1c0623..567d16e307 100644 --- a/src/lib/libcrypto/ec/ec_ameth.c +++ b/src/lib/libcrypto/ec/ec_ameth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ec_ameth.c,v 1.14 2014/10/07 04:58:50 miod Exp $ */ +/* $OpenBSD: ec_ameth.c,v 1.15 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2006. */ @@ -65,9 +65,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "asn1_locl.h" @@ -573,24 +570,6 @@ ec_pkey_ctrl(EVP_PKEY * pkey, int op, long arg1, void *arg2) X509_ALGOR_set0(alg2, OBJ_nid2obj(snid), V_ASN1_UNDEF, 0); } return 1; -#ifndef OPENSSL_NO_CMS - case ASN1_PKEY_CTRL_CMS_SIGN: - if (arg1 == 0) { - int snid, hnid; - X509_ALGOR *alg1, *alg2; - CMS_SignerInfo_get0_algs(arg2, NULL, NULL, - &alg1, &alg2); - if (alg1 == NULL || alg1->algorithm == NULL) - return -1; - hnid = OBJ_obj2nid(alg1->algorithm); - if (hnid == NID_undef) - return -1; - if (!OBJ_find_sigid_by_algs(&snid, hnid, EVP_PKEY_id(pkey))) - return -1; - X509_ALGOR_set0(alg2, OBJ_nid2obj(snid), V_ASN1_UNDEF, 0); - } - return 1; -#endif case ASN1_PKEY_CTRL_DEFAULT_MD_NID: *(int *) arg2 = NID_sha1; diff --git a/src/lib/libcrypto/err/err_all.c b/src/lib/libcrypto/err/err_all.c index e809d79496..296c1a5ba3 100644 --- a/src/lib/libcrypto/err/err_all.c +++ b/src/lib/libcrypto/err/err_all.c @@ -1,4 +1,4 @@ -/* $OpenBSD: err_all.c,v 1.20 2015/02/11 03:55:00 beck Exp $ */ +/* $OpenBSD: err_all.c,v 1.21 2015/02/11 03:55:42 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -115,6 +115,9 @@ ERR_load_crypto_strings(void) #ifndef OPENSSL_NO_RSA ERR_load_RSA_strings(); #endif +#ifndef OPENSSL_NO_COMP +#include +#endif #ifndef OPENSSL_NO_DH ERR_load_DH_strings(); #endif @@ -151,9 +154,6 @@ ERR_load_crypto_strings(void) #endif ERR_load_OCSP_strings(); ERR_load_UI_strings(); -#ifndef OPENSSL_NO_CMS - ERR_load_CMS_strings(); -#endif #ifndef OPENSSL_NO_GOST ERR_load_GOST_strings(); #endif diff --git a/src/lib/libcrypto/gost/gostr341001_ameth.c b/src/lib/libcrypto/gost/gostr341001_ameth.c index fea6ef26dd..fb1d57ad6d 100644 --- a/src/lib/libcrypto/gost/gostr341001_ameth.c +++ b/src/lib/libcrypto/gost/gostr341001_ameth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: gostr341001_ameth.c,v 1.6 2015/02/11 03:19:37 doug Exp $ */ +/* $OpenBSD: gostr341001_ameth.c,v 1.7 2015/02/11 03:55:42 beck Exp $ */ /* * Copyright (c) 2014 Dmitry Eremin-Solenikov * Copyright (c) 2005-2006 Cryptocom LTD @@ -61,9 +61,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "asn1_locl.h" #include "gost_locl.h" @@ -656,17 +653,6 @@ pkey_ctrl_gost01(EVP_PKEY *pkey, int op, long arg1, void *arg2) if (arg1 == 0) PKCS7_RECIP_INFO_get0_alg(arg2, &alg3); break; -#ifndef OPENSSL_NO_CMS - case ASN1_PKEY_CTRL_CMS_SIGN: - if (arg1 == 0) - CMS_SignerInfo_get0_algs(arg2, NULL, NULL, &alg1, &alg2); - break; - - case ASN1_PKEY_CTRL_CMS_ENVELOPE: - if (arg1 == 0) - CMS_RecipientInfo_ktri_get0_algs(arg2, NULL, NULL, &alg3); - break; -#endif case ASN1_PKEY_CTRL_DEFAULT_MD_NID: *(int *)arg2 = GostR3410_get_md_digest(digest); return 2; diff --git a/src/lib/libcrypto/gost/gostr341001_pmeth.c b/src/lib/libcrypto/gost/gostr341001_pmeth.c index 8a71f814b2..89e1ae62cd 100644 --- a/src/lib/libcrypto/gost/gostr341001_pmeth.c +++ b/src/lib/libcrypto/gost/gostr341001_pmeth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: gostr341001_pmeth.c,v 1.8 2015/02/11 03:19:37 doug Exp $ */ +/* $OpenBSD: gostr341001_pmeth.c,v 1.9 2015/02/11 03:55:42 beck Exp $ */ /* * Copyright (c) 2014 Dmitry Eremin-Solenikov * Copyright (c) 2005-2006 Cryptocom LTD @@ -597,11 +597,6 @@ pkey_gost01_ctrl(EVP_PKEY_CTX *ctx, int type, int p1, void *p2) case EVP_PKEY_CTRL_PKCS7_DECRYPT: case EVP_PKEY_CTRL_PKCS7_SIGN: case EVP_PKEY_CTRL_DIGESTINIT: -#ifndef OPENSSL_NO_CMS - case EVP_PKEY_CTRL_CMS_ENCRYPT: - case EVP_PKEY_CTRL_CMS_DECRYPT: - case EVP_PKEY_CTRL_CMS_SIGN: -#endif return 1; case EVP_PKEY_CTRL_GOST_PARAMSET: diff --git a/src/lib/libcrypto/pem/pem_lib.c b/src/lib/libcrypto/pem/pem_lib.c index 011e9e36de..9107e9c225 100644 --- a/src/lib/libcrypto/pem/pem_lib.c +++ b/src/lib/libcrypto/pem/pem_lib.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pem_lib.c,v 1.37 2015/02/11 03:19:37 doug Exp $ */ +/* $OpenBSD: pem_lib.c,v 1.38 2015/02/11 03:55:42 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -264,15 +264,6 @@ check_pem(const char *nm, const char *name) !strcmp(name, PEM_STRING_PKCS7)) return 1; -#ifndef OPENSSL_NO_CMS - if (!strcmp(nm, PEM_STRING_X509) && - !strcmp(name, PEM_STRING_CMS)) - return 1; - /* Allow CMS to be read from PKCS#7 headers */ - if (!strcmp(nm, PEM_STRING_PKCS7) && - !strcmp(name, PEM_STRING_CMS)) - return 1; -#endif return 0; } diff --git a/src/lib/libcrypto/rsa/rsa_ameth.c b/src/lib/libcrypto/rsa/rsa_ameth.c index f842a7c70c..a68fcbeb11 100644 --- a/src/lib/libcrypto/rsa/rsa_ameth.c +++ b/src/lib/libcrypto/rsa/rsa_ameth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rsa_ameth.c,v 1.12 2014/07/11 12:59:10 miod Exp $ */ +/* $OpenBSD: rsa_ameth.c,v 1.13 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2006. */ @@ -66,9 +66,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "asn1_locl.h" @@ -420,17 +417,6 @@ rsa_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2) if (arg1 == 0) PKCS7_RECIP_INFO_get0_alg(arg2, &alg); break; -#ifndef OPENSSL_NO_CMS - case ASN1_PKEY_CTRL_CMS_SIGN: - if (arg1 == 0) - CMS_SignerInfo_get0_algs(arg2, NULL, NULL, NULL, &alg); - break; - - case ASN1_PKEY_CTRL_CMS_ENVELOPE: - if (arg1 == 0) - CMS_RecipientInfo_ktri_get0_algs(arg2, NULL, NULL, &alg); - break; -#endif case ASN1_PKEY_CTRL_DEFAULT_MD_NID: *(int *)arg2 = NID_sha1; diff --git a/src/lib/libcrypto/rsa/rsa_pmeth.c b/src/lib/libcrypto/rsa/rsa_pmeth.c index 954190d560..6d38a7c923 100644 --- a/src/lib/libcrypto/rsa/rsa_pmeth.c +++ b/src/lib/libcrypto/rsa/rsa_pmeth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rsa_pmeth.c,v 1.14 2014/07/11 08:44:49 jsing Exp $ */ +/* $OpenBSD: rsa_pmeth.c,v 1.15 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2006. */ @@ -69,9 +69,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "evp_locl.h" #include "rsa_locl.h" @@ -462,26 +459,6 @@ bad_pad: case EVP_PKEY_CTRL_PKCS7_DECRYPT: case EVP_PKEY_CTRL_PKCS7_SIGN: return 1; -#ifndef OPENSSL_NO_CMS - case EVP_PKEY_CTRL_CMS_DECRYPT: - { - X509_ALGOR *alg = NULL; - ASN1_OBJECT *encalg = NULL; - - if (p2) - CMS_RecipientInfo_ktri_get0_algs(p2, NULL, - NULL, &alg); - if (alg) - X509_ALGOR_get0(&encalg, NULL, NULL, alg); - if (encalg && OBJ_obj2nid(encalg) == NID_rsaesOaep) - rctx->pad_mode = RSA_PKCS1_OAEP_PADDING; - } - /* FALLTHROUGH */ - - case EVP_PKEY_CTRL_CMS_ENCRYPT: - case EVP_PKEY_CTRL_CMS_SIGN: - return 1; -#endif case EVP_PKEY_CTRL_PEER_KEY: RSAerr(RSA_F_PKEY_RSA_CTRL, RSA_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE); diff --git a/src/lib/libssl/src/crypto/cms/cms.h b/src/lib/libssl/src/crypto/cms/cms.h index 0e4aa6f9fc..f08e2f8457 100644 --- a/src/lib/libssl/src/crypto/cms/cms.h +++ b/src/lib/libssl/src/crypto/cms/cms.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cms.h,v 1.5 2014/07/10 22:45:56 jsing Exp $ */ +/* $OpenBSD: cms.h,v 1.6 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project. */ @@ -58,9 +58,7 @@ #include -#ifdef OPENSSL_NO_CMS #error CMS is disabled. -#endif #ifdef __cplusplus extern "C" { diff --git a/src/lib/libssl/src/crypto/dsa/dsa_ameth.c b/src/lib/libssl/src/crypto/dsa/dsa_ameth.c index 20839b6207..8f7a73a481 100644 --- a/src/lib/libssl/src/crypto/dsa/dsa_ameth.c +++ b/src/lib/libssl/src/crypto/dsa/dsa_ameth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dsa_ameth.c,v 1.14 2014/07/13 12:45:01 miod Exp $ */ +/* $OpenBSD: dsa_ameth.c,v 1.15 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2006. */ @@ -66,9 +66,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "asn1_locl.h" @@ -595,26 +592,6 @@ dsa_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2) 0); } return 1; -#ifndef OPENSSL_NO_CMS - case ASN1_PKEY_CTRL_CMS_SIGN: - if (arg1 == 0) { - int snid, hnid; - X509_ALGOR *alg1, *alg2; - - CMS_SignerInfo_get0_algs(arg2, NULL, NULL, &alg1, &alg2); - if (alg1 == NULL || alg1->algorithm == NULL) - return -1; - hnid = OBJ_obj2nid(alg1->algorithm); - if (hnid == NID_undef) - return -1; - if (!OBJ_find_sigid_by_algs(&snid, hnid, - EVP_PKEY_id(pkey))) - return -1; - X509_ALGOR_set0(alg2, OBJ_nid2obj(snid), V_ASN1_UNDEF, - 0); - } - return 1; -#endif case ASN1_PKEY_CTRL_DEFAULT_MD_NID: *(int *)arg2 = NID_sha1; diff --git a/src/lib/libssl/src/crypto/ec/ec_ameth.c b/src/lib/libssl/src/crypto/ec/ec_ameth.c index b4ae1c0623..567d16e307 100644 --- a/src/lib/libssl/src/crypto/ec/ec_ameth.c +++ b/src/lib/libssl/src/crypto/ec/ec_ameth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ec_ameth.c,v 1.14 2014/10/07 04:58:50 miod Exp $ */ +/* $OpenBSD: ec_ameth.c,v 1.15 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2006. */ @@ -65,9 +65,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "asn1_locl.h" @@ -573,24 +570,6 @@ ec_pkey_ctrl(EVP_PKEY * pkey, int op, long arg1, void *arg2) X509_ALGOR_set0(alg2, OBJ_nid2obj(snid), V_ASN1_UNDEF, 0); } return 1; -#ifndef OPENSSL_NO_CMS - case ASN1_PKEY_CTRL_CMS_SIGN: - if (arg1 == 0) { - int snid, hnid; - X509_ALGOR *alg1, *alg2; - CMS_SignerInfo_get0_algs(arg2, NULL, NULL, - &alg1, &alg2); - if (alg1 == NULL || alg1->algorithm == NULL) - return -1; - hnid = OBJ_obj2nid(alg1->algorithm); - if (hnid == NID_undef) - return -1; - if (!OBJ_find_sigid_by_algs(&snid, hnid, EVP_PKEY_id(pkey))) - return -1; - X509_ALGOR_set0(alg2, OBJ_nid2obj(snid), V_ASN1_UNDEF, 0); - } - return 1; -#endif case ASN1_PKEY_CTRL_DEFAULT_MD_NID: *(int *) arg2 = NID_sha1; diff --git a/src/lib/libssl/src/crypto/err/err_all.c b/src/lib/libssl/src/crypto/err/err_all.c index e809d79496..296c1a5ba3 100644 --- a/src/lib/libssl/src/crypto/err/err_all.c +++ b/src/lib/libssl/src/crypto/err/err_all.c @@ -1,4 +1,4 @@ -/* $OpenBSD: err_all.c,v 1.20 2015/02/11 03:55:00 beck Exp $ */ +/* $OpenBSD: err_all.c,v 1.21 2015/02/11 03:55:42 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -115,6 +115,9 @@ ERR_load_crypto_strings(void) #ifndef OPENSSL_NO_RSA ERR_load_RSA_strings(); #endif +#ifndef OPENSSL_NO_COMP +#include +#endif #ifndef OPENSSL_NO_DH ERR_load_DH_strings(); #endif @@ -151,9 +154,6 @@ ERR_load_crypto_strings(void) #endif ERR_load_OCSP_strings(); ERR_load_UI_strings(); -#ifndef OPENSSL_NO_CMS - ERR_load_CMS_strings(); -#endif #ifndef OPENSSL_NO_GOST ERR_load_GOST_strings(); #endif diff --git a/src/lib/libssl/src/crypto/gost/gostr341001_ameth.c b/src/lib/libssl/src/crypto/gost/gostr341001_ameth.c index fea6ef26dd..fb1d57ad6d 100644 --- a/src/lib/libssl/src/crypto/gost/gostr341001_ameth.c +++ b/src/lib/libssl/src/crypto/gost/gostr341001_ameth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: gostr341001_ameth.c,v 1.6 2015/02/11 03:19:37 doug Exp $ */ +/* $OpenBSD: gostr341001_ameth.c,v 1.7 2015/02/11 03:55:42 beck Exp $ */ /* * Copyright (c) 2014 Dmitry Eremin-Solenikov * Copyright (c) 2005-2006 Cryptocom LTD @@ -61,9 +61,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "asn1_locl.h" #include "gost_locl.h" @@ -656,17 +653,6 @@ pkey_ctrl_gost01(EVP_PKEY *pkey, int op, long arg1, void *arg2) if (arg1 == 0) PKCS7_RECIP_INFO_get0_alg(arg2, &alg3); break; -#ifndef OPENSSL_NO_CMS - case ASN1_PKEY_CTRL_CMS_SIGN: - if (arg1 == 0) - CMS_SignerInfo_get0_algs(arg2, NULL, NULL, &alg1, &alg2); - break; - - case ASN1_PKEY_CTRL_CMS_ENVELOPE: - if (arg1 == 0) - CMS_RecipientInfo_ktri_get0_algs(arg2, NULL, NULL, &alg3); - break; -#endif case ASN1_PKEY_CTRL_DEFAULT_MD_NID: *(int *)arg2 = GostR3410_get_md_digest(digest); return 2; diff --git a/src/lib/libssl/src/crypto/gost/gostr341001_pmeth.c b/src/lib/libssl/src/crypto/gost/gostr341001_pmeth.c index 8a71f814b2..89e1ae62cd 100644 --- a/src/lib/libssl/src/crypto/gost/gostr341001_pmeth.c +++ b/src/lib/libssl/src/crypto/gost/gostr341001_pmeth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: gostr341001_pmeth.c,v 1.8 2015/02/11 03:19:37 doug Exp $ */ +/* $OpenBSD: gostr341001_pmeth.c,v 1.9 2015/02/11 03:55:42 beck Exp $ */ /* * Copyright (c) 2014 Dmitry Eremin-Solenikov * Copyright (c) 2005-2006 Cryptocom LTD @@ -597,11 +597,6 @@ pkey_gost01_ctrl(EVP_PKEY_CTX *ctx, int type, int p1, void *p2) case EVP_PKEY_CTRL_PKCS7_DECRYPT: case EVP_PKEY_CTRL_PKCS7_SIGN: case EVP_PKEY_CTRL_DIGESTINIT: -#ifndef OPENSSL_NO_CMS - case EVP_PKEY_CTRL_CMS_ENCRYPT: - case EVP_PKEY_CTRL_CMS_DECRYPT: - case EVP_PKEY_CTRL_CMS_SIGN: -#endif return 1; case EVP_PKEY_CTRL_GOST_PARAMSET: diff --git a/src/lib/libssl/src/crypto/pem/pem_lib.c b/src/lib/libssl/src/crypto/pem/pem_lib.c index 011e9e36de..9107e9c225 100644 --- a/src/lib/libssl/src/crypto/pem/pem_lib.c +++ b/src/lib/libssl/src/crypto/pem/pem_lib.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pem_lib.c,v 1.37 2015/02/11 03:19:37 doug Exp $ */ +/* $OpenBSD: pem_lib.c,v 1.38 2015/02/11 03:55:42 beck Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -264,15 +264,6 @@ check_pem(const char *nm, const char *name) !strcmp(name, PEM_STRING_PKCS7)) return 1; -#ifndef OPENSSL_NO_CMS - if (!strcmp(nm, PEM_STRING_X509) && - !strcmp(name, PEM_STRING_CMS)) - return 1; - /* Allow CMS to be read from PKCS#7 headers */ - if (!strcmp(nm, PEM_STRING_PKCS7) && - !strcmp(name, PEM_STRING_CMS)) - return 1; -#endif return 0; } diff --git a/src/lib/libssl/src/crypto/rsa/rsa_ameth.c b/src/lib/libssl/src/crypto/rsa/rsa_ameth.c index f842a7c70c..a68fcbeb11 100644 --- a/src/lib/libssl/src/crypto/rsa/rsa_ameth.c +++ b/src/lib/libssl/src/crypto/rsa/rsa_ameth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rsa_ameth.c,v 1.12 2014/07/11 12:59:10 miod Exp $ */ +/* $OpenBSD: rsa_ameth.c,v 1.13 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2006. */ @@ -66,9 +66,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "asn1_locl.h" @@ -420,17 +417,6 @@ rsa_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2) if (arg1 == 0) PKCS7_RECIP_INFO_get0_alg(arg2, &alg); break; -#ifndef OPENSSL_NO_CMS - case ASN1_PKEY_CTRL_CMS_SIGN: - if (arg1 == 0) - CMS_SignerInfo_get0_algs(arg2, NULL, NULL, NULL, &alg); - break; - - case ASN1_PKEY_CTRL_CMS_ENVELOPE: - if (arg1 == 0) - CMS_RecipientInfo_ktri_get0_algs(arg2, NULL, NULL, &alg); - break; -#endif case ASN1_PKEY_CTRL_DEFAULT_MD_NID: *(int *)arg2 = NID_sha1; diff --git a/src/lib/libssl/src/crypto/rsa/rsa_pmeth.c b/src/lib/libssl/src/crypto/rsa/rsa_pmeth.c index 954190d560..6d38a7c923 100644 --- a/src/lib/libssl/src/crypto/rsa/rsa_pmeth.c +++ b/src/lib/libssl/src/crypto/rsa/rsa_pmeth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rsa_pmeth.c,v 1.14 2014/07/11 08:44:49 jsing Exp $ */ +/* $OpenBSD: rsa_pmeth.c,v 1.15 2015/02/11 03:55:42 beck Exp $ */ /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL * project 2006. */ @@ -69,9 +69,6 @@ #include #include -#ifndef OPENSSL_NO_CMS -#include -#endif #include "evp_locl.h" #include "rsa_locl.h" @@ -462,26 +459,6 @@ bad_pad: case EVP_PKEY_CTRL_PKCS7_DECRYPT: case EVP_PKEY_CTRL_PKCS7_SIGN: return 1; -#ifndef OPENSSL_NO_CMS - case EVP_PKEY_CTRL_CMS_DECRYPT: - { - X509_ALGOR *alg = NULL; - ASN1_OBJECT *encalg = NULL; - - if (p2) - CMS_RecipientInfo_ktri_get0_algs(p2, NULL, - NULL, &alg); - if (alg) - X509_ALGOR_get0(&encalg, NULL, NULL, alg); - if (encalg && OBJ_obj2nid(encalg) == NID_rsaesOaep) - rctx->pad_mode = RSA_PKCS1_OAEP_PADDING; - } - /* FALLTHROUGH */ - - case EVP_PKEY_CTRL_CMS_ENCRYPT: - case EVP_PKEY_CTRL_CMS_SIGN: - return 1; -#endif case EVP_PKEY_CTRL_PEER_KEY: RSAerr(RSA_F_PKEY_RSA_CTRL, RSA_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE); -- cgit v1.2.3-55-g6feb