public static string MapNameToOID(string name)
{
if (name == null)
throw new ArgumentNullException(nameof(name));
string oidName;
if (!DefaultOidHT.TryGetValue(name, out oidName))
{
try
{
Oid oid = Oid.FromFriendlyName(name, OidGroup.All);
oidName = oid.Value;
}
catch (CryptographicException) { }
}
return oidName;
}
}