aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pk_pad/emsa_pkcs1
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2019-08-04 06:42:01 -0400
committerJack Lloyd <[email protected]>2019-08-04 16:26:49 -0400
commit20c7d267be8c60fb7a8ed0718bbfdd50365b1d8d (patch)
treec86417f5344b9ddcd93eb72a0530cc1672ce939c /src/lib/pk_pad/emsa_pkcs1
parentb7434defb0769f1f06a7b55f5435ceb690856713 (diff)
Avoid using deprecated public fields of AlgorithmIdentifier
Diffstat (limited to 'src/lib/pk_pad/emsa_pkcs1')
-rw-r--r--src/lib/pk_pad/emsa_pkcs1/emsa_pkcs1.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/lib/pk_pad/emsa_pkcs1/emsa_pkcs1.cpp b/src/lib/pk_pad/emsa_pkcs1/emsa_pkcs1.cpp
index 669025a08..e17858598 100644
--- a/src/lib/pk_pad/emsa_pkcs1/emsa_pkcs1.cpp
+++ b/src/lib/pk_pad/emsa_pkcs1/emsa_pkcs1.cpp
@@ -97,13 +97,10 @@ AlgorithmIdentifier EMSA_PKCS1v15::config_for_x509(const Private_Key& key,
" not supported for signature algorithm " + key.algo_name());
}
+ // for RSA PKCSv1.5 parameters "SHALL" be NULL
- AlgorithmIdentifier sig_algo;
- sig_algo.oid = OIDS::str2oid_or_throw(key.algo_name() + "/" + name());
- // for RSA PKCSv1.5 parameters "SHALL" be NULL as configured by
- // RSA_PublicKey::algorithm_identifier()
- sig_algo.parameters = key.algorithm_identifier().parameters;
- return sig_algo;
+ const OID oid = OIDS::str2oid_or_throw(key.algo_name() + "/" + name());
+ return AlgorithmIdentifier(oid, AlgorithmIdentifier::USE_NULL_PARAM);
}
EMSA_PKCS1v15::EMSA_PKCS1v15(HashFunction* hash) : m_hash(hash)