edtFTPnet/PRO - Secure FTP component for .NET | Free Trial | Pricing

SSLFTPCertificate Class

Contains information regarding an X.509v3 certificate.

Definition

Namespace: EnterpriseDT.Net.Ftp.Ssl
Assembly: edtFTPnetPRO (in edtFTPnetPRO.dll) Version: 12.7.0.0
C#
public class SSLFTPCertificate : IDisposable
Inheritance
Object    SSLFTPCertificate
Implements
IDisposable

Remarks

Certificates are used here in two basic ways: (1) to validate the server to the client, and (2) to validate the client to the server. In the former case, the certificate is obtained from the server. In the latter case, the certificate must be loaded from a file.

Certificates may be loaded from files using one of the following three methods:

  1. CreateFromCER(...) – Loads the certificate from a CER file
  2. CreateFromPEM(...) – Loads the certificate from a PEM file
  3. CreateFromPFX(...) – Loads the certificate from a PFX file

Private keys may be loaded from a PVK file and associated with a certificate using the AssociatePrivateKey(string,string) method.

Instances of this class should be managed via using or Dispose.

Properties

CertFile Name of the certificate file from which this certificate was read.
CertFilePassword Password for the certificate file.
Chain Chain of certificates.
EffectiveDate Date from which the certificate became effective.
ExpirationDate Date on which the certificate expires.
Extensions Certificate extensions.
IssuerName Name of the entity which issued the certificate.
KeyAlgorithm Algorithm that was used to generate the public/private key pair.
KeyAlgorithmParameters Parameters that were used to generate the public/private key pair.
KeyAlgorithmParametersString String representation of the parameters that were used to generate the public/private key pair.
KeyFile Name of the private key file associated with this certificate.
KeyFilePassword Password for the private key file.
Name Name of the entity to which the certificate was issued.
PrivateKey Private key associated with the certificate.
PublicKey Public key associated with the certificate.
SerialNumber Serial number of certificate.
SerialNumberString String representation of the serial number of the certificate.
SubjectName Distinguished Name (DN) of the entity to which the certificate was issued.

Methods

AssociatePrivateKey(String, String) Loads the private key from the given PVK file.
AssociatePrivateKey(String, String, Boolean) Loads the private key from the given PVK file.
CreateFromCER Loads the certificate from a CER file.
CreateFromFile(String) Loads the certificate from a file.
CreateFromFile(String, String) Loads the certificate from a file.
CreateFromPEM Loads the certificate from a PEM file.
CreateFromPFX(Byte, String) Loads the certificate and private key from a PFX buffer.
CreateFromPFX(String, String) Loads the certificate and private key from a PFX file.
CreateFromPFX(String, String, Boolean) Loads the certificate and private key from a PFX file.
CreateFromPKCS12 Loads the certificate and private key from a PKCS12 buffer.
DisposeReleases all resources used by the SSLFTPCertificate
Equals
(Overrides ObjectEquals(Object))
Finalize
(Overrides ObjectFinalize)
GetBase64String Returns a base-64 representation of the certificate.
GetCACertificates Returns an array of all the certificates in the TrustedRootCAs store on the LocalMachine.
GetCertificates Returns an array of all the certificates in a particular store.
GetHashCode
(Overrides ObjectGetHashCode)
GetPFXBuffer Returns the certificate in buffer in the PFX format.
GetPKCS12Buffer Returns the certificate in buffer in the PKCS12 format.
GetTypeGets the Type of the current instance.
(Inherited from Object)
GetX509 Returns an X509Certificate object that corresponds to this certificate.
ImportCACertificate Imports a certificate into the TrustedRootCAs store on the LocalMachine.
ImportIntoStore Imports a certificate into a particular certificate store.
MemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
PromptForCertificate(Boolean) Prompts the user for a certificate file and a matching private key.
PromptForCertificate(Form, Boolean) Prompts the user for a certificate file and a matching private key.
PromptForCertificate(Form, String, Boolean) Prompts the user for a certificate file and a matching private key.
RemoveCACertificate Removes the given CA certificate from the TrustedRootCAs store on the LocalMachine.
RemoveFromStore Removes a certificate from a specific certificate store.
ShowCertificateManager Displays the certificate manager either as a modal dialog or as a window.
ShowCertificateManager(String) Displays the certificate manager either as a modal dialog or as a window.
ShowCertificateManager(String, IWin32Window) Displays the certificate manager either as a modal dialog or as a window.
ShowCertificateManager(String, IWin32Window, Boolean) Displays the certificate manager either as a modal dialog or as a window.
ToLongString Returns a long string representation of the certificate.
ToString Returns a string representation of the certificate.
(Overrides ObjectToString)
WriteToCER Writes the certificate to a file in CER format.
WriteToPEM Writes the certificate to a file in PEM format.
WriteToPFX Writes the certificate and (optionally) the private key to a file in PFX format.

See Also