Terraria
v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
KeyBlobHelpers.cs
Go to the documentation of this file.
1
using
System.Formats.Asn1
;
2
3
namespace
System.Security.Cryptography
;
4
5
internal
static
class
KeyBlobHelpers
6
{
7
internal
static
void
WriteKeyParameterInteger
(
this
AsnWriter
writer
,
ReadOnlySpan<byte>
integer)
8
{
9
if
(integer[0] == 0)
10
{
11
int
i;
12
for
(i = 1; i < integer.
Length
; i++)
13
{
14
if
(integer[i] >= 128)
15
{
16
i--;
17
break
;
18
}
19
if
(integer[i] != 0)
20
{
21
break
;
22
}
23
}
24
if
(i == integer.
Length
)
25
{
26
i--;
27
}
28
integer = integer.
Slice
(i);
29
}
30
writer
.WriteIntegerUnsigned(integer);
31
}
32
}
System.Formats.Asn1.AsnWriter
Definition
AsnWriter.cs:13
System.Security.Cryptography.KeyBlobHelpers.WriteKeyParameterInteger
static void WriteKeyParameterInteger(this AsnWriter writer, ReadOnlySpan< byte > integer)
Definition
KeyBlobHelpers.cs:7
System.Formats.Asn1
Definition
Asn1Tag.cs:3
System.Security.Cryptography
Definition
CryptoPool.cs:3
System.ExceptionArgument.writer
@ writer
System.ReadOnlySpan.Length
int Length
Definition
ReadOnlySpan.cs:70
System.ReadOnlySpan.Slice
ReadOnlySpan< T > Slice(int start)
Definition
ReadOnlySpan.cs:232
System.ReadOnlySpan
Definition
ReadOnlySpan.cs:14
source
System.Security.Cryptography.X509Certificates
System.Security.Cryptography
KeyBlobHelpers.cs
Generated by
1.10.0