Inheritance: Asn1Encodable, IAsn1Choice
示例#1
0
 public PkiMessage(
     PkiHeader header,
     PkiBody body,
     DerBitString protection)
     : this(header, body, protection, null)
 {
 }
示例#2
0
 public PkiMessage(
     PkiHeader header,
     PkiBody body,
     DerBitString protection)
     : this(header, body, protection, null)
 {
 }
示例#3
0
 public PkiMessage(PkiHeader header, PkiBody body, DerBitString protection, CmpCertificate[] extraCerts)
 {
     this.header     = header;
     this.body       = body;
     this.protection = protection;
     if (extraCerts != null)
     {
         this.extraCerts = new DerSequence(extraCerts);
     }
 }
示例#4
0
 /**
  * Creates a new PkiMessage.
  *
  * @param header message header
  * @param body message body
  * @param protection message protection (may be null)
  * @param extraCerts extra certificates (may be null)
  */
 public PkiMessage(
     PkiHeader header,
     PkiBody body,
     DerBitString protection,
     CmpCertificate[] extraCerts)
 {
     this.header = header;
     this.body = body;
     this.protection = protection;
     if (extraCerts != null)
     {
         this.extraCerts = new DerSequence(extraCerts);
     }
 }
示例#5
0
 private PkiMessage(Asn1Sequence seq)
 {
     this.header = PkiHeader.GetInstance(seq[0]);
     this.body   = PkiBody.GetInstance(seq[1]);
     for (int i = 2; i < seq.Count; i++)
     {
         Asn1TaggedObject asn1TaggedObject = (Asn1TaggedObject)seq[i].ToAsn1Object();
         if (asn1TaggedObject.TagNo == 0)
         {
             this.protection = DerBitString.GetInstance(asn1TaggedObject, true);
         }
         else
         {
             this.extraCerts = Asn1Sequence.GetInstance(asn1TaggedObject, true);
         }
     }
 }
示例#6
0
        private PkiMessage(Asn1Sequence seq)
        {
            header = PkiHeader.GetInstance(seq[0]);
            body   = PkiBody.GetInstance(seq[1]);

            for (int pos = 2; pos < seq.Count; ++pos)
            {
                Asn1TaggedObject tObj = (Asn1TaggedObject)seq[pos].ToAsn1Object();

                if (tObj.TagNo == 0)
                {
                    protection = DerBitString.GetInstance(tObj, true);
                }
                else
                {
                    extraCerts = Asn1Sequence.GetInstance(tObj, true);
                }
            }
        }
示例#7
0
        private PkiMessage(Asn1Sequence seq)
        {
            header = PkiHeader.GetInstance(seq[0]);
            body = PkiBody.GetInstance(seq[1]);

            for (int pos = 2; pos < seq.Count; ++pos)
            {
                Asn1TaggedObject tObj = (Asn1TaggedObject)seq[pos].ToAsn1Object();

                if (tObj.TagNo == 0)
                {
                    protection = DerBitString.GetInstance(tObj, true);
                }
                else
                {
                    extraCerts = Asn1Sequence.GetInstance(tObj, true);
                }
            }
        }
示例#8
0
 public PkiMessage(
     PkiHeader header,
     PkiBody body)
     : this(header, body, null, null)
 {
 }
示例#9
0
 public ProtectedPart(PkiHeader header, PkiBody body)
 {
     this.header = header;
     this.body   = body;
 }
示例#10
0
 private ProtectedPart(Asn1Sequence seq)
 {
     header = PkiHeader.GetInstance(seq[0]);
     body   = PkiBody.GetInstance(seq[1]);
 }
示例#11
0
		public ProtectedPart(PkiHeader header, PkiBody body)
		{
			this.header = header;
			this.body = body;
		}
示例#12
0
		private ProtectedPart(Asn1Sequence seq)
		{
			header = PkiHeader.GetInstance(seq[0]);
			body = PkiBody.GetInstance(seq[1]);
		}
示例#13
0
 private PkiBody(Asn1TaggedObject tagged)
 {
     this.tagNo = tagged.TagNo;
     this.body  = PkiBody.GetBodyForType(this.tagNo, tagged.GetObject());
 }
示例#14
0
 public PkiBody(int type, Asn1Encodable content)
 {
     this.tagNo = type;
     this.body  = PkiBody.GetBodyForType(type, content);
 }
示例#15
0
 public PkiMessage(
     PkiHeader header,
     PkiBody body)
     : this(header, body, null, null)
 {
 }