コード例 #1
0
        public KekIdentifier(
            Asn1Sequence seq)
        {
            keyIdentifier = (Asn1OctetString)seq[0];

            switch (seq.Count)
            {
            case 1:
                break;

            case 2:
                if (seq[1] is DerGeneralizedTime)
                {
                    date = (DerGeneralizedTime)seq[1];
                }
                else
                {
                    other = OtherKeyAttribute.GetInstance(seq[2]);
                }
                break;

            case 3:
                date  = (DerGeneralizedTime)seq[1];
                other = OtherKeyAttribute.GetInstance(seq[2]);
                break;

            default:
                throw new ArgumentException("Invalid KekIdentifier");
            }
        }
コード例 #2
0
 public RecipientKeyIdentifier(
     byte[]                          subjectKeyIdentifier,
     DerGeneralizedTime date,
     OtherKeyAttribute other)
 {
     this.subjectKeyIdentifier = new DerOctetString(subjectKeyIdentifier);
     this.date  = date;
     this.other = other;
 }
コード例 #3
0
 public KekIdentifier(
     byte[]              keyIdentifier,
     DerGeneralizedTime date,
     OtherKeyAttribute other)
 {
     this.keyIdentifier = new DerOctetString(keyIdentifier);
     this.date          = date;
     this.other         = other;
 }
コード例 #4
0
 public RecipientKeyIdentifier(
     Asn1OctetString subjectKeyIdentifier,
     DerGeneralizedTime date,
     OtherKeyAttribute other)
 {
     this.subjectKeyIdentifier = subjectKeyIdentifier;
     this.date  = date;
     this.other = other;
 }