aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib
diff options
context:
space:
mode:
authorJack Lloyd <[email protected]>2017-11-14 12:33:03 -0500
committerJack Lloyd <[email protected]>2017-11-14 16:19:45 -0500
commitcd7866e3ec00beff057228cf3fb87b72df02f88f (patch)
treef7607b9d7b74c0d0138bd2e542e697e95a08cfb1 /src/lib
parentdafbe9848eb4386207bf5a7a6fdb86e34d720edf (diff)
Add a test for GH #1252
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/x509/x509_dn.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/lib/x509/x509_dn.cpp b/src/lib/x509/x509_dn.cpp
index ce1300e53..e705fe74d 100644
--- a/src/lib/x509/x509_dn.cpp
+++ b/src/lib/x509/x509_dn.cpp
@@ -79,7 +79,13 @@ std::multimap<std::string, std::string> X509_DN::contents() const
{
std::multimap<std::string, std::string> retval;
for(auto i = m_dn_info.begin(); i != m_dn_info.end(); ++i)
- multimap_insert(retval, OIDS::lookup(i->first), i->second.value());
+ {
+ std::string str_value = OIDS::oid2str(i->first);
+
+ if(str_value.empty())
+ str_value = i->first.as_string();
+ multimap_insert(retval, str_value, i->second.value());
+ }
return retval;
}