96 lines
2.9 KiB
C#
96 lines
2.9 KiB
C#
using System;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Math;
|
|
using Cpp2IlInjected;
|
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Signers
|
|
{
|
|
// Token: 0x02001C9C RID: 7324
|
|
[Token(Token = "0x2001C9C")]
|
|
public class StandardDsaEncoding : IDsaEncoding
|
|
{
|
|
// Token: 0x0600B56F RID: 46447 RVA: 0x0000220F File Offset: 0x0000040F
|
|
[Token(Token = "0x600B56F")]
|
|
[Address(RVA = "0x23417F0", Offset = "0x23407F0", VA = "0x1823417F0", Slot = "6")]
|
|
public virtual BigInteger[] Decode(BigInteger n, byte[] encoding)
|
|
{
|
|
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
|
}
|
|
|
|
// Token: 0x0600B570 RID: 46448 RVA: 0x00273F0C File Offset: 0x0027210C
|
|
[Token(Token = "0x600B570")]
|
|
[Address(RVA = "0x2341AD0", Offset = "0x2340AD0", VA = "0x182341AD0", Slot = "7")]
|
|
public virtual byte[] Encode(BigInteger n, BigInteger r, BigInteger s)
|
|
{
|
|
Asn1Encodable[] array = new Asn1Encodable[2];
|
|
BigInteger bigInteger;
|
|
if (bigInteger != 0)
|
|
{
|
|
}
|
|
array[0] = bigInteger;
|
|
BigInteger bigInteger2;
|
|
if (bigInteger2 != 0)
|
|
{
|
|
}
|
|
array[1] = bigInteger2;
|
|
return new DerSequence(array).GetEncoded("DER");
|
|
}
|
|
|
|
// Token: 0x0600B571 RID: 46449 RVA: 0x00273F50 File Offset: 0x00272150
|
|
[Token(Token = "0x600B571")]
|
|
[Address(RVA = "0x2341630", Offset = "0x2340630", VA = "0x182341630", Slot = "8")]
|
|
protected virtual BigInteger CheckValue(BigInteger n, BigInteger x)
|
|
{
|
|
if (n != 0)
|
|
{
|
|
int num = x.CompareTo(n);
|
|
}
|
|
return x;
|
|
}
|
|
|
|
// Token: 0x0600B572 RID: 46450 RVA: 0x00273F70 File Offset: 0x00272170
|
|
[Token(Token = "0x600B572")]
|
|
[Address(RVA = "0x23416D0", Offset = "0x23406D0", VA = "0x1823416D0", Slot = "9")]
|
|
protected virtual BigInteger DecodeValue(BigInteger n, Asn1Sequence s, int pos)
|
|
{
|
|
Asn1SequenceParser parser;
|
|
do
|
|
{
|
|
parser = s.Parser;
|
|
}
|
|
while (parser == 0 || parser == 0);
|
|
BigInteger bigInteger;
|
|
return bigInteger;
|
|
}
|
|
|
|
// Token: 0x0600B573 RID: 46451 RVA: 0x00273F98 File Offset: 0x00272198
|
|
[Token(Token = "0x600B573")]
|
|
[Address(RVA = "0x2341A50", Offset = "0x2340A50", VA = "0x182341A50", Slot = "10")]
|
|
protected virtual DerInteger EncodeValue(BigInteger n, BigInteger x)
|
|
{
|
|
DerInteger derInteger;
|
|
return derInteger;
|
|
}
|
|
|
|
// Token: 0x0600B574 RID: 46452 RVA: 0x00273FA8 File Offset: 0x002721A8
|
|
[Token(Token = "0x600B574")]
|
|
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
|
|
public StandardDsaEncoding()
|
|
{
|
|
}
|
|
|
|
// Token: 0x0600B575 RID: 46453 RVA: 0x00273FBC File Offset: 0x002721BC
|
|
// Note: this type is marked as 'beforefieldinit'.
|
|
[Token(Token = "0x600B575")]
|
|
[Address(RVA = "0x2341C60", Offset = "0x2340C60", VA = "0x182341C60")]
|
|
static StandardDsaEncoding()
|
|
{
|
|
StandardDsaEncoding standardDsaEncoding = new StandardDsaEncoding();
|
|
}
|
|
|
|
// Token: 0x040072DB RID: 29403
|
|
[Token(Token = "0x40072DB")]
|
|
public static readonly StandardDsaEncoding Instance;
|
|
}
|
|
}
|