11 instantiations of CngKeyBlobFormat
System.Core (11)
System\Security\Cryptography\CngKeyBlobFormat.cs (8)
105
s_eccPrivate = new
CngKeyBlobFormat
("ECCPRIVATEBLOB"); // BCRYPT_ECCPRIVATE_BLOB
117
s_eccPublic = new
CngKeyBlobFormat
("ECCPUBLICBLOB"); // BCRYPT_ECCPUBLIC_BLOB
129
s_eccFullPrivate = new
CngKeyBlobFormat
("ECCFULLPRIVATEBLOB"); // BCRYPT_ECCFULLPRIVATE_BLOB
141
s_eccFullPublic = new
CngKeyBlobFormat
("ECCFULLPUBLICBLOB"); // BCRYPT_ECCFULLPUBLIC_BLOB
153
s_genericPrivate = new
CngKeyBlobFormat
("PRIVATEBLOB"); // BCRYPT_PRIVATE_KEY_BLOB
165
s_genericPublic = new
CngKeyBlobFormat
("PUBLICBLOB"); // BCRYPT_PUBLIC_KEY_BLOB
177
s_opaqueTransport = new
CngKeyBlobFormat
("OpaqueTransport"); // NCRYPT_OPAQUETRANSPORT_BLOB
189
s_pkcs8Private = new
CngKeyBlobFormat
("PKCS8_PRIVATEKEY"); // NCRYPT_PKCS8_PRIVATE_KEY_BLOB
System\Security\Cryptography\RsaCng.cs (3)
17
private static CngKeyBlobFormat s_rsaFullPrivateBlob = new
CngKeyBlobFormat
(BCryptNative.KeyBlobType.RsaFullPrivateBlob);
18
private static CngKeyBlobFormat s_rsaPrivateBlob = new
CngKeyBlobFormat
(BCryptNative.KeyBlobType.RsaPrivateBlob);
19
private static CngKeyBlobFormat s_rsaPublicBlob = new
CngKeyBlobFormat
(BCryptNative.KeyBlobType.RsaPublicBlob);
57 references to CngKeyBlobFormat
System.Core (57)
System\Security\Cryptography\CngKey.cs (9)
551
public static CngKey Import(byte[] keyBlob,
CngKeyBlobFormat
format) {
556
internal static CngKey Import(byte[] keyBlob, string curveName,
CngKeyBlobFormat
format) {
561
public static CngKey Import(byte[] keyBlob,
CngKeyBlobFormat
format, CngProvider provider) {
567
internal static CngKey Import(byte[] keyBlob, string curveName,
CngKeyBlobFormat
format, CngProvider provider)
588
bool safeKeyImport = format ==
CngKeyBlobFormat
.EccPublicBlob ||
589
format ==
CngKeyBlobFormat
.EccFullPublicBlob ||
590
format ==
CngKeyBlobFormat
.GenericPublicBlob;
610
key.IsEphemeral = format !=
CngKeyBlobFormat
.OpaqueTransportBlob;
619
public byte[] Export(
CngKeyBlobFormat
format) {
System\Security\Cryptography\CngKeyBlobFormat.cs (31)
20
public sealed class CngKeyBlobFormat : IEquatable<
CngKeyBlobFormat
> {
21
private static volatile
CngKeyBlobFormat
s_eccPrivate;
22
private static volatile
CngKeyBlobFormat
s_eccPublic;
23
private static volatile
CngKeyBlobFormat
s_eccFullPrivate;
24
private static volatile
CngKeyBlobFormat
s_eccFullPublic;
25
private static volatile
CngKeyBlobFormat
s_genericPrivate;
26
private static volatile
CngKeyBlobFormat
s_genericPublic;
27
private static volatile
CngKeyBlobFormat
s_opaqueTransport;
28
private static volatile
CngKeyBlobFormat
s_pkcs8Private;
55
public static bool operator ==(
CngKeyBlobFormat
left,
CngKeyBlobFormat
right) {
64
public static bool operator !=(
CngKeyBlobFormat
left,
CngKeyBlobFormat
right) {
75
return Equals(obj as
CngKeyBlobFormat
);
78
public bool Equals(
CngKeyBlobFormat
other) {
100
public static
CngKeyBlobFormat
EccPrivateBlob {
102
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
112
public static
CngKeyBlobFormat
EccPublicBlob {
114
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
124
public static
CngKeyBlobFormat
EccFullPrivateBlob {
126
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
136
public static
CngKeyBlobFormat
EccFullPublicBlob {
138
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
148
public static
CngKeyBlobFormat
GenericPrivateBlob {
150
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
160
public static
CngKeyBlobFormat
GenericPublicBlob {
162
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
172
public static
CngKeyBlobFormat
OpaqueTransportBlob {
174
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
184
public static
CngKeyBlobFormat
Pkcs8PrivateBlob {
186
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
System\Security\Cryptography\ECDiffieHellmanCngPublicKey.cs (7)
21
private
CngKeyBlobFormat
m_format;
28
internal ECDiffieHellmanCngPublicKey(byte[] keyBlob, string curveName,
CngKeyBlobFormat
format) : base(keyBlob) {
40
public
CngKeyBlobFormat
BlobFormat {
42
Contract.Ensures(Contract.Result<
CngKeyBlobFormat
>() != null);
60
public static ECDiffieHellmanPublicKey FromByteArray(byte[] publicKeyBlob,
CngKeyBlobFormat
format) {
82
CngKeyBlobFormat
format;
107
CngKeyBlobFormat
format;
System\Security\Cryptography\RsaCng.cs (3)
17
private static
CngKeyBlobFormat
s_rsaFullPrivateBlob = new CngKeyBlobFormat(BCryptNative.KeyBlobType.RsaFullPrivateBlob);
18
private static
CngKeyBlobFormat
s_rsaPrivateBlob = new CngKeyBlobFormat(BCryptNative.KeyBlobType.RsaPrivateBlob);
19
private static
CngKeyBlobFormat
s_rsaPublicBlob = new CngKeyBlobFormat(BCryptNative.KeyBlobType.RsaPublicBlob);
System\Security\Cryptography\X509Certificates\ECDsaCertificateExtensions.cs (6)
84
CngKeyBlobFormat
blobFormat = HasExplicitParameters(bcryptKeyHandle) ?
85
CngKeyBlobFormat
.EccFullPublicBlob :
CngKeyBlobFormat
.EccPublicBlob;
95
CngKeyBlobFormat
blobFormat =
CngKeyBlobFormat
.EccPublicBlob;
351
CngKey Key = CngKey.Import(keyBlob,
CngKeyBlobFormat
.EccPublicBlob);
System\Security\Cryptography\X509Certificates\RSACertificateExtensions.cs (1)
51
CngKey key = CngKey.Import(cngBlob,
CngKeyBlobFormat
.GenericPublicBlob);