[openssl-commits] [openssl] master update

Richard Levitte levitte at openssl.org
Wed Jan 18 14:20:11 UTC 2017


The branch master has been updated
       via  31a51151fc163a7f5f4d07dff9478be50e4b5707 (commit)
       via  2191dc846a85ce82925cb06b4dd8649da7fc403c (commit)
      from  1f164c6fadd0eef0aa0997c51639a11276bf9072 (commit)


- Log -----------------------------------------------------------------
commit 31a51151fc163a7f5f4d07dff9478be50e4b5707
Author: FdaSilvaYY <fdasilvayy at gmail.com>
Date:   Tue Nov 8 19:21:51 2016 +0100

    Clean dead macros and defines
    
    ... mostly related to some old discarded modules .
    
    Reviewed-by: Rich Salz <rsalz at openssl.org>
    Reviewed-by: Richard Levitte <levitte at openssl.org>
    (Merged from https://github.com/openssl/openssl/pull/1906)

commit 2191dc846a85ce82925cb06b4dd8649da7fc403c
Author: FdaSilvaYY <fdasilvayy at gmail.com>
Date:   Thu Nov 10 23:28:10 2016 +0100

    Clean one unused variable, plus an useless one.
    
    Reviewed-by: Rich Salz <rsalz at openssl.org>
    Reviewed-by: Richard Levitte <levitte at openssl.org>
    (Merged from https://github.com/openssl/openssl/pull/1906)

-----------------------------------------------------------------------

Summary of changes:
 crypto/asn1/p5_pbev2.c  |  8 ++-----
 crypto/asn1/p5_scrypt.c | 12 ++++------
 include/openssl/err.h   |  3 +--
 util/indent.pro         | 63 -------------------------------------------------
 4 files changed, 7 insertions(+), 79 deletions(-)

diff --git a/crypto/asn1/p5_pbev2.c b/crypto/asn1/p5_pbev2.c
index 9687057..14e8700 100644
--- a/crypto/asn1/p5_pbev2.c
+++ b/crypto/asn1/p5_pbev2.c
@@ -41,12 +41,11 @@ X509_ALGOR *PKCS5_pbe2_set_iv(const EVP_CIPHER *cipher, int iter,
                               unsigned char *salt, int saltlen,
                               unsigned char *aiv, int prf_nid)
 {
-    X509_ALGOR *scheme = NULL, *kalg = NULL, *ret = NULL;
+    X509_ALGOR *scheme = NULL, *ret = NULL;
     int alg_nid, keylen;
     EVP_CIPHER_CTX *ctx = NULL;
     unsigned char iv[EVP_MAX_IV_LENGTH];
     PBE2PARAM *pbe2 = NULL;
-    ASN1_OBJECT *obj;
 
     alg_nid = EVP_CIPHER_type(cipher);
     if (alg_nid == NID_undef) {
@@ -54,14 +53,13 @@ X509_ALGOR *PKCS5_pbe2_set_iv(const EVP_CIPHER *cipher, int iter,
                 ASN1_R_CIPHER_HAS_NO_OBJECT_IDENTIFIER);
         goto err;
     }
-    obj = OBJ_nid2obj(alg_nid);
 
     if ((pbe2 = PBE2PARAM_new()) == NULL)
         goto merr;
 
     /* Setup the AlgorithmIdentifier for the encryption scheme */
     scheme = pbe2->encryption;
-    scheme->algorithm = obj;
+    scheme->algorithm = OBJ_nid2obj(alg_nid);
     if ((scheme->parameter = ASN1_TYPE_new()) == NULL)
         goto merr;
 
@@ -137,11 +135,9 @@ X509_ALGOR *PKCS5_pbe2_set_iv(const EVP_CIPHER *cipher, int iter,
     EVP_CIPHER_CTX_free(ctx);
     PBE2PARAM_free(pbe2);
     /* Note 'scheme' is freed as part of pbe2 */
-    X509_ALGOR_free(kalg);
     X509_ALGOR_free(ret);
 
     return NULL;
-
 }
 
 X509_ALGOR *PKCS5_pbe2_set(const EVP_CIPHER *cipher, int iter,
diff --git a/crypto/asn1/p5_scrypt.c b/crypto/asn1/p5_scrypt.c
index cc1f76c..4cb7837 100644
--- a/crypto/asn1/p5_scrypt.c
+++ b/crypto/asn1/p5_scrypt.c
@@ -50,13 +50,12 @@ X509_ALGOR *PKCS5_pbe2_set_scrypt(const EVP_CIPHER *cipher,
                                   unsigned char *aiv, uint64_t N, uint64_t r,
                                   uint64_t p)
 {
-    X509_ALGOR *scheme = NULL, *kalg = NULL, *ret = NULL;
+    X509_ALGOR *scheme = NULL, *ret = NULL;
     int alg_nid;
     size_t keylen = 0;
     EVP_CIPHER_CTX *ctx = NULL;
     unsigned char iv[EVP_MAX_IV_LENGTH];
     PBE2PARAM *pbe2 = NULL;
-    ASN1_OBJECT *obj;
 
     if (!cipher) {
         ASN1err(ASN1_F_PKCS5_PBE2_SET_SCRYPT, ERR_R_PASSED_NULL_PARAMETER);
@@ -75,7 +74,7 @@ X509_ALGOR *PKCS5_pbe2_set_scrypt(const EVP_CIPHER *cipher,
                 ASN1_R_CIPHER_HAS_NO_OBJECT_IDENTIFIER);
         goto err;
     }
-    obj = OBJ_nid2obj(alg_nid);
+
     pbe2 = PBE2PARAM_new();
     if (pbe2 == NULL)
         goto merr;
@@ -83,7 +82,7 @@ X509_ALGOR *PKCS5_pbe2_set_scrypt(const EVP_CIPHER *cipher,
     /* Setup the AlgorithmIdentifier for the encryption scheme */
     scheme = pbe2->encryption;
 
-    scheme->algorithm = obj;
+    scheme->algorithm = OBJ_nid2obj(alg_nid);
     scheme->parameter = ASN1_TYPE_new();
     if (scheme->parameter == NULL)
         goto merr;
@@ -149,12 +148,10 @@ X509_ALGOR *PKCS5_pbe2_set_scrypt(const EVP_CIPHER *cipher,
 
  err:
     PBE2PARAM_free(pbe2);
-    X509_ALGOR_free(kalg);
     X509_ALGOR_free(ret);
     EVP_CIPHER_CTX_free(ctx);
 
     return NULL;
-
 }
 
 static X509_ALGOR *pkcs5_scrypt_set(const unsigned char *salt, size_t saltlen,
@@ -162,9 +159,8 @@ static X509_ALGOR *pkcs5_scrypt_set(const unsigned char *salt, size_t saltlen,
                                     uint64_t p)
 {
     X509_ALGOR *keyfunc = NULL;
-    SCRYPT_PARAMS *sparam = NULL;
+    SCRYPT_PARAMS *sparam = SCRYPT_PARAMS_new();
 
-    sparam = SCRYPT_PARAMS_new();
     if (sparam == NULL)
         goto merr;
 
diff --git a/include/openssl/err.h b/include/openssl/err.h
index 904cf3a..9bbe9e1 100644
--- a/include/openssl/err.h
+++ b/include/openssl/err.h
@@ -89,7 +89,7 @@ typedef struct err_state_st {
 # define ERR_LIB_CMS             46
 # define ERR_LIB_TS              47
 # define ERR_LIB_HMAC            48
-# define ERR_LIB_JPAKE           49
+/* # define ERR_LIB_JPAKE       49 */
 # define ERR_LIB_CT              50
 # define ERR_LIB_ASYNC           51
 # define ERR_LIB_KDF             52
@@ -128,7 +128,6 @@ typedef struct err_state_st {
 # define CMSerr(f,r) ERR_PUT_error(ERR_LIB_CMS,(f),(r),OPENSSL_FILE,OPENSSL_LINE)
 # define TSerr(f,r) ERR_PUT_error(ERR_LIB_TS,(f),(r),OPENSSL_FILE,OPENSSL_LINE)
 # define HMACerr(f,r) ERR_PUT_error(ERR_LIB_HMAC,(f),(r),OPENSSL_FILE,OPENSSL_LINE)
-# define JPAKEerr(f,r) ERR_PUT_error(ERR_LIB_JPAKE,(f),(r),OPENSSL_FILE,OPENSSL_LINE)
 # define CTerr(f,r) ERR_PUT_error(ERR_LIB_CT,(f),(r),OPENSSL_FILE,OPENSSL_LINE)
 # define ASYNCerr(f,r) ERR_PUT_error(ERR_LIB_ASYNC,(f),(r),OPENSSL_FILE,OPENSSL_LINE)
 # define KDFerr(f,r) ERR_PUT_error(ERR_LIB_KDF,(f),(r),OPENSSL_FILE,OPENSSL_LINE)
diff --git a/util/indent.pro b/util/indent.pro
index e768a2a..74e5680 100644
--- a/util/indent.pro
+++ b/util/indent.pro
@@ -35,24 +35,6 @@
 -ts0
 -T ACCESS_DESCRIPTION
 -T ADDED_OBJ
--T AEP_BBOOL
--T AEP_CHAR
--T AEP_CHAR_PTR
--T AEP_CONNECTION_ENTRY
--T AEP_CONNECTION_HNDL
--T AEP_CONNECTION_HNDL_PTR
--T AEP_FLAGS
--T AEP_RV
--T AEP_TRANSACTION_ID
--T AEP_TRANSACTION_ID_PTR
--T AEP_U16
--T AEP_U32
--T AEP_U32_PTR
--T AEP_U64_PTR
--T AEP_U8
--T AEP_U8_PTR
--T AEP_VOID_PTR
--T AEP_VOID_PTR_PTR
 -T AES_KEY
 -T APP_INFO
 -T ARGS
@@ -284,10 +266,6 @@
 -T HEAPENTRY32
 -T HEAPLIST32
 -T HMAC_CTX
--T ICA_KEY_RSA_CRT
--T ICA_KEY_RSA_CRT_REC
--T ICA_KEY_RSA_MODEXPO
--T ICA_KEY_RSA_MODEXPO_REC
 -T IDEA_KEY_SCHEDULE
 -T IPAddrBlocks
 -T IPAddressFamily
@@ -361,7 +339,6 @@
 -T OPENSSL_ITEM
 -T OPENSSL_PSTRING
 -T OPENSSL_STRING
--T OPENSSL_STRING
 -T OSSL_ASYNC_FD
 -T OTHERNAME
 -T P256_POINT
@@ -433,8 +410,6 @@
 -T SSL
 -T SSL2_STATE
 -T SSL3_BUFFER
--T SSL3_BUF_FREELIST
--T SSL3_BUF_FREELIST_ENTRY
 -T SSL3_COMP
 -T SSL3_ENC_METHOD
 -T SSL3_RECORD
@@ -449,43 +424,6 @@
 -T SSL_SESSION
 -T SSL_SESSION_ASN1
 -T STACK_OF
--T STORE
--T STORE_ATTR_INFO
--T STORE_ATTR_TYPES
--T STORE_CERTIFICATE_STATUS
--T STORE_CLEANUP_FUNC_PTR
--T STORE_CTRL_FUNC_PTR
--T STORE_END_OBJECT_FUNC_PTR
--T STORE_GENERATE_OBJECT_FUNC_PTR
--T STORE_GENERIC_FUNC_PTR
--T STORE_GET_OBJECT_FUNC_PTR
--T STORE_HANDLE_OBJECT_FUNC_PTR
--T STORE_INITIALISE_FUNC_PTR
--T STORE_METHOD
--T STORE_MODIFY_OBJECT_FUNC_PTR
--T STORE_NEXT_OBJECT_FUNC_PTR
--T STORE_OBJECT
--T STORE_OBJECT_TYPES
--T STORE_PARAM_TYPES
--T STORE_START_OBJECT_FUNC_PTR
--T STORE_STORE_OBJECT_FUNC_PTR
--T SW_ALGTYPE
--T SW_BYTE
--T SW_COMMAND_BITMAP
--T SW_COMMAND_CODE
--T SW_CONTEXT_HANDLE
--T SW_CRT
--T SW_DSA
--T SW_EXP
--T SW_LARGENUMBER
--T SW_NVDATA
--T SW_OSHANDLE
--T SW_PARAM
--T SW_STATE
--T SW_STATUS
--T SW_U16
--T SW_U32
--T SW_U64
 -T SXNET
 -T SXNETID
 -T TCHAR
@@ -661,7 +599,6 @@
 -T STACK_OF_SRTP_PROTECTION_PROFILE_
 -T STACK_OF_SSL_CIPHER_
 -T STACK_OF_SSL_COMP_
--T STACK_OF_STORE_ATTR_INFO_
 -T STACK_OF_STRING_
 -T STACK_OF_SXNETID_
 -T STACK_OF_SingleResponse_


More information about the openssl-commits mailing list