C# Класс Org.BouncyCastle.X509.X509Certificate

An Object representing an X509 Certificate. Has static methods for loading Certificates encoded in many forms that return X509Certificate Objects.
Наследование: X509ExtensionBase
Показать файл Открыть проект Примеры использования класса

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

Метод Описание
CheckValidity ( ) : void

Checks if the current date is within certificate's validity period.

CheckValidity ( System.DateTime time ) : void

Checks if the given date is within certificate's validity period.

Equals ( object obj ) : bool
GetBasicConstraints ( ) : int
GetEncoded ( ) : byte[]

Return a Der encoded version of this certificate.

GetExtendedKeyUsage ( ) : IList
GetHashCode ( ) : int
GetIssuerAlternativeNames ( ) : ICollection
GetKeyUsage ( ) : bool[]

Get a key usage guidlines.

GetPublicKey ( ) : AsymmetricKeyParameter

Get the public key of the subject of the certificate.

GetSigAlgParams ( ) : byte[]

Get the signature algorithms parameters. (EG DSA Parameters)

GetSignature ( ) : byte[]

The signature.

GetSubjectAlternativeNames ( ) : ICollection
GetTbsCertificate ( ) : byte[]

Return the Der encoded TbsCertificate data. This is the certificate component less the signature. To Get the whole certificate call the GetEncoded() member.

IsValid ( DateTime time ) : bool

Return true if the nominated time is within the start and end times nominated on the certificate.

ToString ( ) : string
Verify ( AsymmetricKeyParameter key ) : void

Verify the certificate's signature using the nominated public key.

X509Certificate ( X509CertificateStructure c ) : System

Защищенные методы

Метод Описание
CheckSignature ( AsymmetricKeyParameter publicKey, ISigner signature ) : void
GetAlternativeNames ( string oid ) : ICollection
GetX509Extensions ( ) : X509Extensions
X509Certificate ( ) : System

Приватные методы

Метод Описание
IsAlgIDEqual ( AlgorithmIdentifier id1, AlgorithmIdentifier id2 ) : bool

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

CheckSignature() защищенный Метод

protected CheckSignature ( AsymmetricKeyParameter publicKey, ISigner signature ) : void
publicKey Org.BouncyCastle.Crypto.AsymmetricKeyParameter
signature ISigner
Результат void

CheckValidity() публичный Метод

Checks if the current date is within certificate's validity period.
public CheckValidity ( ) : void
Результат void

CheckValidity() публичный Метод

Checks if the given date is within certificate's validity period.
if the certificate is expired by given date if the certificate is not yet valid on given date
public CheckValidity ( System.DateTime time ) : void
time System.DateTime
Результат void

Equals() публичный Метод

public Equals ( object obj ) : bool
obj object
Результат bool

GetAlternativeNames() защищенный Метод

protected GetAlternativeNames ( string oid ) : ICollection
oid string
Результат ICollection

GetBasicConstraints() публичный Метод

public GetBasicConstraints ( ) : int
Результат int

GetEncoded() публичный Метод

Return a Der encoded version of this certificate.
public GetEncoded ( ) : byte[]
Результат byte[]

GetExtendedKeyUsage() публичный Метод

public GetExtendedKeyUsage ( ) : IList
Результат IList

GetHashCode() публичный Метод

public GetHashCode ( ) : int
Результат int

GetIssuerAlternativeNames() публичный Метод

public GetIssuerAlternativeNames ( ) : ICollection
Результат ICollection

GetKeyUsage() публичный Метод

Get a key usage guidlines.
public GetKeyUsage ( ) : bool[]
Результат bool[]

GetPublicKey() публичный Метод

Get the public key of the subject of the certificate.
public GetPublicKey ( ) : AsymmetricKeyParameter
Результат AsymmetricKeyParameter

GetSigAlgParams() публичный Метод

Get the signature algorithms parameters. (EG DSA Parameters)
public GetSigAlgParams ( ) : byte[]
Результат byte[]

GetSignature() публичный Метод

The signature.
public GetSignature ( ) : byte[]
Результат byte[]

GetSubjectAlternativeNames() публичный Метод

public GetSubjectAlternativeNames ( ) : ICollection
Результат ICollection

GetTbsCertificate() публичный Метод

Return the Der encoded TbsCertificate data. This is the certificate component less the signature. To Get the whole certificate call the GetEncoded() member.
public GetTbsCertificate ( ) : byte[]
Результат byte[]

GetX509Extensions() защищенный Метод

protected GetX509Extensions ( ) : X509Extensions
Результат X509Extensions

IsValid() публичный Метод

Return true if the nominated time is within the start and end times nominated on the certificate.
public IsValid ( DateTime time ) : bool
time DateTime The time to test validity against.
Результат bool

ToString() публичный Метод

public ToString ( ) : string
Результат string

Verify() публичный Метод

Verify the certificate's signature using the nominated public key.
If key submitted is not of the above nominated types.
public Verify ( AsymmetricKeyParameter key ) : void
key AsymmetricKeyParameter An appropriate public key parameter object, RsaPublicKeyParameters, DsaPublicKeyParameters or ECDsaPublicKeyParameters
Результат void

X509Certificate() защищенный Метод

protected X509Certificate ( ) : System
Результат System

X509Certificate() публичный Метод

public X509Certificate ( X509CertificateStructure c ) : System
c X509CertificateStructure
Результат System