C# Class Elastacloud.AzureManagement.Fluent.Helpers.CertificateGenerator

Certificate generator class used to create an X509 cert with exportable privatekey and optionally add to the personal store
Afficher le fichier Open project: azurecoder/fluent-management Class Usage Examples

Méthodes publiques

Méthode Description
AddToMyStore ( X509Certificate2 certificate2 ) : void

Adds a certificate to My store for the LocalMachine

CertificateGenerator ( ) : System
CertificateGenerator ( string subscriptionId, X509Certificate2 managementCertificate ) : System
Create ( string name, System.DateTime start, System.DateTime end, string userPassword, bool addtoStore = false ) : X509Certificate2

Static method used to create a certificate and return as a .net object

ExportToFileSystem ( string exportDirectory ) : void

Used to export the certificates to the filesystem

ExportToStorageAccount ( string account, string container, string folder ) : string
GetCerData ( ) : byte[]
GetPemData ( ) : string
GetPfxData ( ) : byte[]
IsInMyStore ( X509Certificate2 certificate2 ) : bool

Checks to see whether the certificate is in the appropriate store

RemoveFromMyStore ( X509Certificate2 certificate2 ) : void

Removes a certificate from My LocalMachine Store

Private Methods

Méthode Description
ReturnStore ( ) : X509Store

Returns the My LocalMachine store

Method Details

AddToMyStore() public méthode

Adds a certificate to My store for the LocalMachine
public AddToMyStore ( X509Certificate2 certificate2 ) : void
certificate2 System.Security.Cryptography.X509Certificates.X509Certificate2
Résultat void

CertificateGenerator() public méthode

public CertificateGenerator ( ) : System
Résultat System

CertificateGenerator() public méthode

public CertificateGenerator ( string subscriptionId, X509Certificate2 managementCertificate ) : System
subscriptionId string
managementCertificate System.Security.Cryptography.X509Certificates.X509Certificate2
Résultat System

Create() public méthode

Static method used to create a certificate and return as a .net object
public Create ( string name, System.DateTime start, System.DateTime end, string userPassword, bool addtoStore = false ) : X509Certificate2
name string
start System.DateTime
end System.DateTime
userPassword string
addtoStore bool
Résultat System.Security.Cryptography.X509Certificates.X509Certificate2

ExportToFileSystem() public méthode

Used to export the certificates to the filesystem
public ExportToFileSystem ( string exportDirectory ) : void
exportDirectory string
Résultat void

ExportToStorageAccount() public méthode

public ExportToStorageAccount ( string account, string container, string folder ) : string
account string
container string
folder string
Résultat string

GetCerData() public méthode

public GetCerData ( ) : byte[]
Résultat byte[]

GetPemData() public méthode

public GetPemData ( ) : string
Résultat string

GetPfxData() public méthode

public GetPfxData ( ) : byte[]
Résultat byte[]

IsInMyStore() public méthode

Checks to see whether the certificate is in the appropriate store
public IsInMyStore ( X509Certificate2 certificate2 ) : bool
certificate2 System.Security.Cryptography.X509Certificates.X509Certificate2
Résultat bool

RemoveFromMyStore() public méthode

Removes a certificate from My LocalMachine Store
public RemoveFromMyStore ( X509Certificate2 certificate2 ) : void
certificate2 System.Security.Cryptography.X509Certificates.X509Certificate2
Résultat void