Chilkat
HOME
Android™
ASP
Visual Basic
VB.NET
C#
iOS (IPhone)
Objective-C
C++
C
MFC
Delphi
FoxPro
Java
Perl
PHP Extension
PHP ActiveX
Python
PowerShell
Ruby
SQL Server
VBScript
|
Export All Certificates to .cer FilesDemonstrates how to export all certificates from a registry-based certificate store to .cer files where each filename is the serial number. LOCAL loCcs LOCAL loCs LOCAL loCert LOCAL lnNumCerts LOCAL i LOCAL lcFilename loCcs = CreateObject('Chilkat.CreateCS') loCcs.ReadOnly = 1 * Open the current-user certificate store: loCs = loCcs.OpenCurrentUserStore() IF (NOT (loCs = NULL )) THEN lnNumCerts = loCs.NumCertificates * Print the distinguished name of each certificate FOR i = 0 TO lnNumCerts - 1 loCert = loCs.GetCertificate(i) lcFilename = "certs/" + loCert.SerialNumber + ".cer" loCert.ExportCertDerFile(lcFilename) NEXT ELSE =MESSAGEBOX(loCcs.LastErrorText) ENDIF |
© 2000-2010 Chilkat Software, Inc. All Rights Reserved.
Mail Component · .NET Email Component · ASP Mail Component · XML Parser