<PackageReference Include="BouncyCastle.Cryptography" Version="2.6.2" />

CertAnnContent

using Org.BouncyCastle.Asn1.X509; using System; namespace Org.BouncyCastle.Asn1.Cmp { public class CertAnnContent : CmpCertificate { public new static CertAnnContent GetInstance(object obj) { return Asn1Utilities.GetInstanceChoice(obj, GetOptional); } public new static CertAnnContent GetInstance(Asn1TaggedObject taggedObject, bool declaredExplicit) { return Asn1Utilities.GetInstanceChoice(taggedObject, declaredExplicit, GetInstance); } public new static CertAnnContent GetOptional(Asn1Encodable element) { if (element == null) throw new ArgumentNullException("element"); CertAnnContent certAnnContent = element as CertAnnContent; if (certAnnContent != null) return certAnnContent; X509CertificateStructure optional = X509CertificateStructure.GetOptional(element); if (optional != null) return new CertAnnContent(optional); Asn1TaggedObject optional2 = Asn1TaggedObject.GetOptional(element); if (optional2 != null && optional2.HasContextTag() && optional2.IsExplicit()) return new CertAnnContent(optional2.TagNo, optional2.GetBaseObject()); return null; } public new static CertAnnContent GetTagged(Asn1TaggedObject taggedObject, bool declaredExplicit) { return Asn1Utilities.GetTaggedChoice(taggedObject, declaredExplicit, GetInstance); } [Obsolete("Use 'GetInstance' from tagged object instead")] public CertAnnContent(int type, Asn1Object otherCert) : base(type, otherCert) { } private CertAnnContent(int type, Asn1Encodable otherCert) : base(type, otherCert) { } internal CertAnnContent(CmpCertificate other) : base(other) { } public CertAnnContent(X509CertificateStructure x509v3PKCert) : base(x509v3PKCert) { } } }