Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Decode() [1/2]

static RSAPublicKeyAsn System.Security.Cryptography.Asn1.RSAPublicKeyAsn.Decode ( Asn1Tag expectedTag,
ReadOnlyMemory< byte > encoded,
AsnEncodingRules ruleSet )
inlinestaticpackage

Definition at line 17 of file RSAPublicKeyAsn.cs.

18 {
19 try
20 {
21 AsnValueReader reader = new AsnValueReader(encoded.Span, ruleSet);
22 DecodeCore(ref reader, expectedTag, encoded, out var decoded);
23 reader.ThrowIfNotEmpty();
24 return decoded;
25 }
26 catch (AsnContentException inner)
27 {
28 throw new CryptographicException(System.SR.Cryptography_Der_Invalid_Encoding, inner);
29 }
30 }
static string Cryptography_Der_Invalid_Encoding
Definition SR.cs:50
Definition SR.cs:7
unsafe ReadOnlySpan< T > Span
static void DecodeCore(ref AsnValueReader reader, Asn1Tag expectedTag, ReadOnlyMemory< byte > rebind, out RSAPublicKeyAsn decoded)

References System.SR.Cryptography_Der_Invalid_Encoding, System.Security.Cryptography.Asn1.RSAPublicKeyAsn.DecodeCore(), System.ReadOnlyMemory< T >.Span, and System.Formats.Asn1.AsnValueReader.ThrowIfNotEmpty().