Extracts the email (E (by preference) or subject name (CN) value from this certificate.

Namespace: NHINDirect.Certificates
Assembly: nhinCommon (in nhinCommon.dll) Version: 1.0.0.0 (1.0.0.0)

Syntax

C#
public static string ExtractEmailNameOrName(
	this X509Certificate2 cert
)
Visual Basic
<ExtensionAttribute> _
Public Shared Function ExtractEmailNameOrName ( _
	cert As X509Certificate2 _
) As String
Visual C++
[ExtensionAttribute]
public:
static String^ ExtractEmailNameOrName(
	X509Certificate2^ cert
)

Parameters

cert
Type: System.Security.Cryptography.X509Certificates..::..X509Certificate2
The certificate from which to extract the name

Return Value

The E value, or the CN value if E is not found or null if neither are found

See Also