aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/pk_pad/emsa1/emsa1.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/pk_pad/emsa1/emsa1.cpp')
-rw-r--r--src/lib/pk_pad/emsa1/emsa1.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/lib/pk_pad/emsa1/emsa1.cpp b/src/lib/pk_pad/emsa1/emsa1.cpp
index e1bc8db6e..048c3417c 100644
--- a/src/lib/pk_pad/emsa1/emsa1.cpp
+++ b/src/lib/pk_pad/emsa1/emsa1.cpp
@@ -111,9 +111,7 @@ AlgorithmIdentifier EMSA1::config_for_x509(const Private_Key& key,
const std::string sig_name = key.algo_name() + "/" + name();
AlgorithmIdentifier sig_algo;
- sig_algo.oid = OIDS::lookup(sig_name);
- if(sig_algo.oid.empty())
- throw Lookup_Error("No OID defined for " + sig_name);
+ sig_algo.oid = OIDS::str2oid_or_throw(key.algo_name() + "/" + name());
std::string algo_name = key.algo_name();
if(algo_name == "DSA" ||