void m_decode(Byte[] rawData) { alternativeNames.Decode(rawData); foreach (X509AlternativeName altName in alternativeNames) { if (String.IsNullOrEmpty(altName.Value)) { throw new ArgumentException($"Empty value for {altName.Type} is not allowed."); } } }
void decodeOptionalFields(Asn1Reader asn) { while (asn.MoveNextCurrentLevel()) { switch (asn.Tag) { case (Byte)Asn1Type.BOOLEAN: Ordering = new Asn1Boolean(asn).Value; break; case (Byte)Asn1Type.INTEGER: NonceReceived = true; nonce = asn.GetPayload(); break; case 48: break; case 0xa0: Byte[] nameBytes = asn.GetTagRawData(); nameBytes[0] = 48; _tsaName.Decode(nameBytes); break; case 0xa1: Byte[] extBytes = asn.GetTagRawData(); extBytes[0] = 48; var extList = new X509ExtensionCollection(); extList.Decode(asn.GetTagRawData()); foreach (X509Extension extension in extList) { _extensions.Add(extension); } break; } } }
void m_decode(Byte[] rawData) { alternativeNames.Decode(rawData); }