RSA padding Zeroization fixes
[oweals/openssl.git] / crypto / rsa / rsa_pss.c
index 4484ff28a301ec8f8cf0fd99e1db7f11d520e8a8..26d5f36f1f66c58a1b0903f82c3abbb0ff0ad88b 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2005-2017 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2005-2018 The OpenSSL Project Authors. All Rights Reserved.
  *
  * Licensed under the OpenSSL license (the "License").  You may not use
  * this file except in compliance with the License.  You can obtain a copy
@@ -244,7 +244,7 @@ int RSA_padding_add_PKCS1_PSS_mgf1(RSA *rsa, unsigned char *EM,
 
  err:
     EVP_MD_CTX_free(ctx);
-    OPENSSL_free(salt);
+    OPENSSL_clear_free(salt, sLen);
 
     return ret;