src\libraries\Common\src\System\Security\Cryptography\Asn1\GeneralNameAsn.xml.cs (37)
38ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 0), "OtherName");
39ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 1), "Rfc822Name");
40ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 2), "DnsName");
41ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 3), "X400Address");
42ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 4), "DirectoryName");
43ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 5), "EdiPartyName");
44ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 6), "Uri");
45ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 7), "IPAddress");
46ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 8), "RegisteredId");
59OtherName.Value.Encode(writer, new Asn1Tag(TagClass.ContextSpecific, 0));
68writer.WriteCharacterString(UniversalTagNumber.IA5String, Rfc822Name, new Asn1Tag(TagClass.ContextSpecific, 1));
77writer.WriteCharacterString(UniversalTagNumber.IA5String, DnsName, new Asn1Tag(TagClass.ContextSpecific, 2));
89!validateTag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 3)))
111writer.PushSequence(new Asn1Tag(TagClass.ContextSpecific, 4));
120writer.PopSequence(new Asn1Tag(TagClass.ContextSpecific, 4));
129EdiPartyName.Value.Encode(writer, new Asn1Tag(TagClass.ContextSpecific, 5));
138writer.WriteCharacterString(UniversalTagNumber.IA5String, Uri, new Asn1Tag(TagClass.ContextSpecific, 6));
147writer.WriteOctetString(IPAddress.Value.Span, new Asn1Tag(TagClass.ContextSpecific, 7));
158writer.WriteObjectIdentifier(RegisteredId, new Asn1Tag(TagClass.ContextSpecific, 8));
210if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 0)))
213System.Security.Cryptography.Asn1.OtherNameAsn.Decode(ref reader, new Asn1Tag(TagClass.ContextSpecific, 0), rebind, out tmpOtherName);
217else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 1)))
219decoded.Rfc822Name = reader.ReadCharacterString(UniversalTagNumber.IA5String, new Asn1Tag(TagClass.ContextSpecific, 1));
221else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 2)))
223decoded.DnsName = reader.ReadCharacterString(UniversalTagNumber.IA5String, new Asn1Tag(TagClass.ContextSpecific, 2));
225else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 3)))
230else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 4)))
232explicitReader = reader.ReadSequence(new Asn1Tag(TagClass.ContextSpecific, 4));
237else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 5)))
240System.Security.Cryptography.Asn1.EdiPartyNameAsn.Decode(ref reader, new Asn1Tag(TagClass.ContextSpecific, 5), rebind, out tmpEdiPartyName);
244else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 6)))
246decoded.Uri = reader.ReadCharacterString(UniversalTagNumber.IA5String, new Asn1Tag(TagClass.ContextSpecific, 6));
248else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 7)))
251if (reader.TryReadPrimitiveOctetString(out tmpSpan, new Asn1Tag(TagClass.ContextSpecific, 7)))
257decoded.IPAddress = reader.ReadOctetString(new Asn1Tag(TagClass.ContextSpecific, 7));
261else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 8)))
263decoded.RegisteredId = reader.ReadObjectIdentifier(new Asn1Tag(TagClass.ContextSpecific, 8));
src\libraries\Common\src\System\Security\Cryptography\Asn1\OaepParamsAsn.xml.cs (12)
62writer.PushSequence(new Asn1Tag(TagClass.ContextSpecific, 0));
64writer.PopSequence(new Asn1Tag(TagClass.ContextSpecific, 0));
76writer.PushSequence(new Asn1Tag(TagClass.ContextSpecific, 1));
78writer.PopSequence(new Asn1Tag(TagClass.ContextSpecific, 1));
90writer.PushSequence(new Asn1Tag(TagClass.ContextSpecific, 2));
92writer.PopSequence(new Asn1Tag(TagClass.ContextSpecific, 2));
145if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 0)))
147explicitReader = sequenceReader.ReadSequence(new Asn1Tag(TagClass.ContextSpecific, 0));
158if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 1)))
160explicitReader = sequenceReader.ReadSequence(new Asn1Tag(TagClass.ContextSpecific, 1));
171if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 2)))
173explicitReader = sequenceReader.ReadSequence(new Asn1Tag(TagClass.ContextSpecific, 2));
src\libraries\Common\src\System\Security\Cryptography\Asn1\PssParamsAsn.xml.cs (16)
79writer.PushSequence(new Asn1Tag(TagClass.ContextSpecific, 0));
81writer.PopSequence(new Asn1Tag(TagClass.ContextSpecific, 0));
93writer.PushSequence(new Asn1Tag(TagClass.ContextSpecific, 1));
95writer.PopSequence(new Asn1Tag(TagClass.ContextSpecific, 1));
108writer.PushSequence(new Asn1Tag(TagClass.ContextSpecific, 2));
110writer.PopSequence(new Asn1Tag(TagClass.ContextSpecific, 2));
123writer.PushSequence(new Asn1Tag(TagClass.ContextSpecific, 3));
125writer.PopSequence(new Asn1Tag(TagClass.ContextSpecific, 3));
178if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 0)))
180explicitReader = sequenceReader.ReadSequence(new Asn1Tag(TagClass.ContextSpecific, 0));
191if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 1)))
193explicitReader = sequenceReader.ReadSequence(new Asn1Tag(TagClass.ContextSpecific, 1));
204if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 2)))
206explicitReader = sequenceReader.ReadSequence(new Asn1Tag(TagClass.ContextSpecific, 2));
227if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 3)))
229explicitReader = sequenceReader.ReadSequence(new Asn1Tag(TagClass.ContextSpecific, 3));
System\Security\Cryptography\Pkcs\Asn1\CertificateChoiceAsn.xml.cs (13)
35ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 0), "ExtendedCertificate");
36ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 1), "AttributeCertificateV1");
37ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 2), "AttributeCertificateV2");
38ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 3), "OtherCertificateFormat");
79!validateTag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 0)))
104!validateTag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 1)))
129!validateTag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 2)))
151OtherCertificateFormat.Value.Encode(writer, new Asn1Tag(TagClass.ContextSpecific, 3));
202else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 0)))
207else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 1)))
212else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 2)))
217else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 3)))
220System.Security.Cryptography.Pkcs.Asn1.OtherCertificateFormat.Decode(ref reader, new Asn1Tag(TagClass.ContextSpecific, 3), rebind, out tmpOtherCertificateFormat);
System\Security\Cryptography\Pkcs\Asn1\EnvelopedDataAsn.xml.cs (7)
34OriginatorInfo.Value.Encode(writer, new Asn1Tag(TagClass.ContextSpecific, 0));
50writer.PushSetOf(new Asn1Tag(TagClass.ContextSpecific, 1));
55writer.PopSetOf(new Asn1Tag(TagClass.ContextSpecific, 1));
113if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 0)))
116System.Security.Cryptography.Pkcs.Asn1.OriginatorInfoAsn.Decode(ref sequenceReader, new Asn1Tag(TagClass.ContextSpecific, 0), rebind, out tmpOriginatorInfo);
139if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 1)))
144collectionReader = sequenceReader.ReadSetOf(new Asn1Tag(TagClass.ContextSpecific, 1));
System\Security\Cryptography\Pkcs\Asn1\OriginatorIdentifierOrKeyAsn.xml.cs (9)
33ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 0), "SubjectKeyIdentifier");
34ensureUniqueTag(new Asn1Tag(TagClass.ContextSpecific, 1), "OriginatorKey");
56writer.WriteOctetString(SubjectKeyIdentifier.Value.Span, new Asn1Tag(TagClass.ContextSpecific, 0));
65OriginatorKey.Value.Encode(writer, new Asn1Tag(TagClass.ContextSpecific, 1));
118else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 0)))
121if (reader.TryReadPrimitiveOctetString(out tmpSpan, new Asn1Tag(TagClass.ContextSpecific, 0)))
127decoded.SubjectKeyIdentifier = reader.ReadOctetString(new Asn1Tag(TagClass.ContextSpecific, 0));
131else if (tag.HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 1)))
134System.Security.Cryptography.Pkcs.Asn1.OriginatorPublicKeyAsn.Decode(ref reader, new Asn1Tag(TagClass.ContextSpecific, 1), rebind, out tmpOriginatorKey);
System\Security\Cryptography\Pkcs\Asn1\Rfc3161Accuracy.xml.cs (6)
36writer.WriteInteger(Millis.Value, new Asn1Tag(TagClass.ContextSpecific, 0));
42writer.WriteInteger(Micros.Value, new Asn1Tag(TagClass.ContextSpecific, 1));
107if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 0)))
110if (sequenceReader.TryReadInt32(out int tmpMillis, new Asn1Tag(TagClass.ContextSpecific, 0)))
122if (sequenceReader.HasData && sequenceReader.PeekTag().HasSameClassAndValue(new Asn1Tag(TagClass.ContextSpecific, 1)))
125if (sequenceReader.TryReadInt32(out int tmpMicros, new Asn1Tag(TagClass.ContextSpecific, 1)))