0 out of 2 rated this helpful - Rate this topic

CertificateEnrollmentManager.ImportPfxDataAsync | importPfxDataAsync method

Asynchronously imports a certificate from a Personal Information Exchange (PFX) message.

Syntax


Windows.Security.Cryptography.Certificates.CertificateEnrollmentManager.importPfxDataAsync(pfxData, password, exportable, keyProtectionLevel, installOption, friendlyName).done( /* Your success and error handlers */ );

Parameters

pfxData

Type: String [JavaScript] | System.String [.NET] | Platform::String [C++]

Base64-encoded PFX message.

password

Type: String [JavaScript] | System.String [.NET] | Platform::String [C++]

The password used to decrypt and verify the PFX packet. The password must be exactly the same as the password that was used to encrypt the packet.

exportable

Type: ExportOption

A value of the ExportOption enumeration that specifies whether the key can be exported.

keyProtectionLevel

Type: KeyProtectionLevel

A value of the KeyProtectionLevel enumeration that specifies the strength of the key protection. The default is NoConsent.

installOption

Type: InstallOptions

An InstallOptions enumeration value that specifies the certificate installation option.

friendlyName

Type: String [JavaScript] | System.String [.NET] | Platform::String [C++]

The display name of the enrolled certificate. This value overwrites the FriendlyName property inside the PFX message.

Return value

Type: IAsyncAction

This method does not return a value.

Remarks

This method imports the certificate chain into the app container.

  • To import an issued certificate, it is not necessary for the certificate request to have been generated on the importing computer.
  • The certificates included in the response need not be chained to trusted root certificates on the importing computer.
  • The certificate is installed in the app container MY store.
  • Certification authority and Root certificates are installed in the app container intermediate certification authority store.
  • The key container name and key specification for the imported certificate are determined as described in the Remarks section of PFXImportCertStore with the exception that if AttributeId 1.3.6.1.4.1.311.17.1 is not present, MS_KEY_STORAGE_PROVIDER is always used as the provider name.

Requirements

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Namespace

Windows.Security.Cryptography.Certificates
Windows::Security::Cryptography::Certificates [C++]

Metadata

Windows.winmd

See also

CertificateEnrollmentManager

 

 

Build date: 12/4/2012

© 2013 Microsoft. All rights reserved.