Inheritance: Asn1Encodable
Exemplo n.º 1
0
 private CertificateList(Asn1Sequence seq)
 {
     if (seq.Count != 3)
     {
         throw new ArgumentException("sequence wrong size for CertificateList", "seq");
     }
     this.tbsCertList = TbsCertificateList.GetInstance(seq[0]);
     this.sigAlgID    = AlgorithmIdentifier.GetInstance(seq[1]);
     this.sig         = DerBitString.GetInstance(seq[2]);
 }
Exemplo n.º 2
0
		private CertificateList(
            Asn1Sequence seq)
        {
			if (seq.Count != 3)
				throw new ArgumentException("sequence wrong size for CertificateList", "seq");

			tbsCertList = TbsCertificateList.GetInstance(seq[0]);
			sigAlgID = AlgorithmIdentifier.GetInstance(seq[1]);
			sig = DerBitString.GetInstance(seq[2]);
        }
Exemplo n.º 3
0
 private CertificateList(Asn1Sequence seq)
 {
     //IL_0019: Unknown result type (might be due to invalid IL or missing references)
     if (seq.Count != 3)
     {
         throw new ArgumentException("sequence wrong size for CertificateList", "seq");
     }
     tbsCertList = TbsCertificateList.GetInstance(seq[0]);
     sigAlgID    = AlgorithmIdentifier.GetInstance(seq[1]);
     sig         = DerBitString.GetInstance(seq[2]);
 }
        public static TbsCertificateList GetInstance(object obj)
        {
            TbsCertificateList list = obj as TbsCertificateList;

            if ((obj == null) || (list != null))
            {
                return(list);
            }
            if (!(obj is Asn1Sequence))
            {
                throw new ArgumentException("unknown object in factory: " + Platform.GetTypeName(obj), "obj");
            }
            return(new TbsCertificateList((Asn1Sequence)obj));
        }
Exemplo n.º 5
0
        public static TbsCertificateList GetInstance(object obj)
        {
            TbsCertificateList tbsCertificateList = obj as TbsCertificateList;

            if (obj == null || tbsCertificateList != null)
            {
                return(tbsCertificateList);
            }
            if (obj is Asn1Sequence)
            {
                return(new TbsCertificateList((Asn1Sequence)obj));
            }
            throw new ArgumentException("unknown object in factory: " + obj.GetType().Name, "obj");
        }
Exemplo n.º 6
0
        public static TbsCertificateList GetInstance(object obj)
        {
            //IL_0038: Unknown result type (might be due to invalid IL or missing references)
            TbsCertificateList tbsCertificateList = obj as TbsCertificateList;

            if (obj == null || tbsCertificateList != null)
            {
                return(tbsCertificateList);
            }
            if (obj is Asn1Sequence)
            {
                return(new TbsCertificateList((Asn1Sequence)obj));
            }
            throw new ArgumentException("unknown object in factory: " + Platform.GetTypeName(obj), "obj");
        }
        public static TbsCertificateList GetInstance(
            object obj)
        {
            TbsCertificateList list = obj as TbsCertificateList;

            if (obj == null || list != null)
            {
                return(list);
            }

            if (obj is Asn1Sequence)
            {
                return(new TbsCertificateList((Asn1Sequence)obj));
            }

            throw new ArgumentException("unknown object in factory");
        }
Exemplo n.º 8
0
        public static TbsCertificateList GetInstance(
            object obj)
        {
            TbsCertificateList list = obj as TbsCertificateList;

            if (obj == null || list != null)
            {
                return(list);
            }

            if (obj is Asn1Sequence)
            {
                return(new TbsCertificateList((Asn1Sequence)obj));
            }

            throw new ArgumentException("unknown object in factory: " + Org.BouncyCastle.Utilities.Platform.GetTypeName(obj), "obj");
        }
        private X509Crl GenerateJcaObject(
			TbsCertificateList	tbsCrl,
			byte[]				signature)
        {
            return new X509Crl(
                CertificateList.GetInstance(
                    new DerSequence(tbsCrl, sigAlgId, new DerBitString(signature))));
        }
Exemplo n.º 10
0
 public static TbsCertificateList GetInstance(Asn1TaggedObject obj, bool explicitly)
 {
     return(TbsCertificateList.GetInstance(Asn1Sequence.GetInstance(obj, explicitly)));
 }