C# Класс GSF.Security.GenerateCertificate

Generates X509Certificate2s.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
CreateSelfSignedCertificate ( string subjectDirName, int signatureBits, int keyStrength ) : X509Certificate2

Creates a self signed certificate that can be used in SSL communications

CreateSelfSignedCertificate ( string subjectDirName, System.DateTime startDate, System.DateTime endDate, int signatureBits, int keyStrength, string password, string fileName ) : void

Creates new certificate

OpenCertificate ( string fileName, string password ) : X509Certificate2

Opens a certificate, loading the private key of the PFX file.

Описание методов

CreateSelfSignedCertificate() публичный статический Метод

Creates a self signed certificate that can be used in SSL communications
public static CreateSelfSignedCertificate ( string subjectDirName, int signatureBits, int keyStrength ) : X509Certificate2
subjectDirName string A valid DirName formated string. Example: CN=ServerName
signatureBits int Bitstrength of signature algorithm. Supported Lengths are 160,256, and 384
keyStrength int RSA key strength. Typically a multiple of 1024.
Результат System.Security.Cryptography.X509Certificates.X509Certificate2

CreateSelfSignedCertificate() публичный статический Метод

Creates new certificate
public static CreateSelfSignedCertificate ( string subjectDirName, System.DateTime startDate, System.DateTime endDate, int signatureBits, int keyStrength, string password, string fileName ) : void
subjectDirName string
startDate System.DateTime
endDate System.DateTime
signatureBits int
keyStrength int
password string
fileName string
Результат void

OpenCertificate() публичный статический Метод

Opens a certificate, loading the private key of the PFX file.
public static OpenCertificate ( string fileName, string password ) : X509Certificate2
fileName string
password string
Результат System.Security.Cryptography.X509Certificates.X509Certificate2