Exemplo n.º 1
0
        public SingleResponse(
            Asn1Sequence seq)
        {
            this.certID     = CertID.GetInstance(seq[0]);
            this.certStatus = CertStatus.GetInstance(seq[1]);
            this.thisUpdate = (DerGeneralizedTime)seq[2];

            if (seq.Count > 4)
            {
                this.nextUpdate = DerGeneralizedTime.GetInstance(
                    (Asn1TaggedObject)seq[3], true);
                this.singleExtensions = X509Extensions.GetInstance(
                    (Asn1TaggedObject)seq[4], true);
            }
            else if (seq.Count > 3)
            {
                Asn1TaggedObject o = (Asn1TaggedObject)seq[3];

                if (o.TagNo == 0)
                {
                    this.nextUpdate = DerGeneralizedTime.GetInstance(o, true);
                }
                else
                {
                    this.singleExtensions = X509Extensions.GetInstance(o, true);
                }
            }
        }
Exemplo n.º 2
0
        private Request(
            Asn1Sequence seq)
        {
            reqCert = CertID.GetInstance(seq[0]);

            if (seq.Count == 2)
            {
                singleRequestExtensions = X509Extensions.GetInstance(
                    (Asn1TaggedObject)seq[1], true);
            }
        }
Exemplo n.º 3
0
        public Request(
            CertID reqCert,
            X509Extensions singleRequestExtensions)
        {
            if (reqCert == null)
            {
                throw new ArgumentNullException("reqCert");
            }

            this.reqCert = reqCert;
            this.singleRequestExtensions = singleRequestExtensions;
        }
Exemplo n.º 4
0
 public SingleResponse(
     CertID certID,
     CertStatus certStatus,
     DerGeneralizedTime thisUpdate,
     DerGeneralizedTime nextUpdate,
     X509Extensions singleExtensions)
 {
     this.certID           = certID;
     this.certStatus       = certStatus;
     this.thisUpdate       = thisUpdate;
     this.nextUpdate       = nextUpdate;
     this.singleExtensions = singleExtensions;
 }