Mentalis.org Security Library documentation

Certificate Members

Public Static (Shared) Methods

CreateFromBase64String Creates a new Certificate from a string representation.
CreateFromCerFileOverloaded. Creates a new instance of the Certificate class by opening a certificate file and retrieving the first certificate from it.
CreateFromPemFileOverloaded. Creates a new instance of the Certificate class by reading a certificate from a PEM encoded file.
CreateFromPfxFileOverloaded. Creates a new instance of the Certificate class by opening a PFX file and retrieving the first certificate from it.
CreateFromX509Certificate Creates a new instance of the Certificate class by duplicating an existing X509Certificate instance.
DecodeExtensionOverloaded. Decodes the specified extension and returns an object of the specified type that is instantiated with the decoded bytes.
GetValidUsages Returns an array of usages consisting of the intersection of the valid usages for all certificates in an array of certificates.

Protected Static (Shared) Methods

Public Instance Constructors

CertificateOverloaded. Initialize a new instance of the Certificate class.

Public Instance Properties

Handle Gets the handle of the Certificate.
IsCurrent Gets a value indicating whether the certificate is current, that is, has not expired.
PrivateKey Gets the private key for the certificate.
PublicKey Gets the public key derived from the certificate's data. This key cannot be used to sign or decrypt data.
SupportsDataEncryption Gets a value indicating whether the certificate can be used for encrypting and decrypting messages.
SupportsDigitalSignature Gets a value indicating whether the certificate can be used for digital signatures.

Public Instance Methods

AssociateWithPrivateKeyOverloaded. Associates the certificate with a private key from a PVK file.
Clone Creates a copy of this Certificate.
EqualsOverloaded. Compares a Certificate object and an X509Certificate object for equality.
FindExtension Searches for a certificate extension.
GetCertHashOverloaded. Returns the hash value for the X.509v3 certificate as an array of bytes.
GetCertHashStringOverloaded. Returns the hash value for the X.509v3 certificate as a hexadecimal string.
GetCertificateChain Returns a CertificateChain where the leaf certificate corresponds to this Certificate.
GetDistinguishedName Returns a list of attributes of the X.509v3 certificate.
GetEffectiveDate Returns the effective date of this X.509v3 certificate.
GetEnhancedKeyUsage Returns a list of enhanced key usages of the X.509v3 certificate.
GetExpirationDate Returns the expiration date of this X.509v3 certificate.
GetExtensions Returns a list of extensions of the X.509v3 certificate.
GetFormat Returns the name of the format of this X.509v3 certificate.
GetHashCode Returns the hash code for the X.509v3 certificate as an integer.
GetIntendedKeyUsage Returns a list of intended key usages of the X.509v3 certificate.
GetIssuerName Returns the name of the certification authority that issued the X.509v3 certificate.
GetKeyAlgorithm Returns the key algorithm information for this X.509v3 certificate.
GetKeyAlgorithmParameters Returns the key algorithm parameters for the X.509v3 certificate.
GetKeyAlgorithmParametersString Returns the key algorithm parameters for the X.509v3 certificate.
GetKeyIdentifier Gets the unique identifier associated with the key.
GetName Returns the name of the current principal.
GetPublicKey Returns the public key for the X.509v3 certificate.
GetPublicKeyLength Returns the length of the public key of the X.509v3 certificate.
GetPublicKeyString Returns the public key for the X.509v3 certificate.
GetRawCertData Returns the raw data for the entire X.509v3 certificate.
GetRawCertDataString Returns the raw data for the entire X.509v3 certificate.
GetSerialNumber Returns the serial number of the X.509v3 certificate.
GetSerialNumberString Returns the serial number of the X.509v3 certificate.
GetType (inherited from Object)Gets the Type of the current instance.
HasPrivateKey Checks whether the Certificate has a private key associated with it.
ToBase64String Returns a Base64-encoded representation of the certificate.
ToCerBuffer Saves the Certificate as an encoded buffer.
ToCerFile Saves the Certificate as an encoded file.
ToPemBuffer Converts the Certificate to a PEM encoded buffer.
ToPfxBuffer Saves the Certificate as a PFX encoded buffer.
ToPfxFile Saves the Certificate as a PFX encoded file.
ToStringOverloaded. Returns a string representation of the current Certificate object.
ToX509 Returns an X509Certificate object that corresponds to this Certificate.

Protected Instance Methods

Finalize Disposes of the certificate and frees unmanaged resources.
MemberwiseClone (inherited from Object)Creates a shallow copy of the current Object.

See Also

Certificate Class | Org.Mentalis.Security.Certificates Namespace