scripts
This commit is contained in:
+104
@@ -0,0 +1,104 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x0200136C RID: 4972
|
||||
[Token(Token = "0x200136C")]
|
||||
[StructLayout(3)]
|
||||
public sealed class Base64
|
||||
{
|
||||
// Token: 0x06007DC7 RID: 32199 RVA: 0x001A6728 File Offset: 0x001A4928
|
||||
[Token(Token = "0x6007DC7")]
|
||||
[Address(RVA = "0x3C1670", Offset = "0x3C0070", VA = "0x1803C1670")]
|
||||
private Base64()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x06007DC8 RID: 32200 RVA: 0x001A673C File Offset: 0x001A493C
|
||||
[Token(Token = "0x6007DC8")]
|
||||
[Address(RVA = "0x1C5D840", Offset = "0x1C5C240", VA = "0x181C5D840")]
|
||||
public static string ToBase64String(byte[] data)
|
||||
{
|
||||
int length = data.Length;
|
||||
int num = 0;
|
||||
return Convert.ToBase64String(data, num, length);
|
||||
}
|
||||
|
||||
// Token: 0x06007DC9 RID: 32201 RVA: 0x001A6760 File Offset: 0x001A4960
|
||||
[Token(Token = "0x6007DC9")]
|
||||
[Address(RVA = "0x1C5D7D0", Offset = "0x1C5C1D0", VA = "0x181C5D7D0")]
|
||||
public static string ToBase64String(byte[] data, int off, int length)
|
||||
{
|
||||
return Convert.ToBase64String(data, off, length);
|
||||
}
|
||||
|
||||
// Token: 0x06007DCA RID: 32202 RVA: 0x001A6778 File Offset: 0x001A4978
|
||||
[Token(Token = "0x6007DCA")]
|
||||
[Address(RVA = "0x1C5D5B0", Offset = "0x1C5BFB0", VA = "0x181C5D5B0")]
|
||||
public static byte[] Encode(byte[] data)
|
||||
{
|
||||
int length = data.Length;
|
||||
int num = 0;
|
||||
return Strings.ToAsciiByteArray(Convert.ToBase64String(data, num, length));
|
||||
}
|
||||
|
||||
// Token: 0x06007DCB RID: 32203 RVA: 0x001A67A4 File Offset: 0x001A49A4
|
||||
[Token(Token = "0x6007DCB")]
|
||||
[Address(RVA = "0x1C5D750", Offset = "0x1C5C150", VA = "0x181C5D750")]
|
||||
public static byte[] Encode(byte[] data, int off, int length)
|
||||
{
|
||||
return Strings.ToAsciiByteArray(Convert.ToBase64String(data, off, length));
|
||||
}
|
||||
|
||||
// Token: 0x06007DCC RID: 32204 RVA: 0x001A67C0 File Offset: 0x001A49C0
|
||||
[Token(Token = "0x6007DCC")]
|
||||
[Address(RVA = "0x1C5D690", Offset = "0x1C5C090", VA = "0x181C5D690")]
|
||||
public static int Encode(byte[] data, Stream outStream)
|
||||
{
|
||||
int length = data.Length;
|
||||
int num = 0;
|
||||
byte[] array = Strings.ToAsciiByteArray(Convert.ToBase64String(data, num, length));
|
||||
int num2 = outStream.ReadByte();
|
||||
return array.Length;
|
||||
}
|
||||
|
||||
// Token: 0x06007DCD RID: 32205 RVA: 0x001A67F8 File Offset: 0x001A49F8
|
||||
[Token(Token = "0x6007DCD")]
|
||||
[Address(RVA = "0x1C5D630", Offset = "0x1C5C030", VA = "0x181C5D630")]
|
||||
public static int Encode(byte[] data, int off, int length, Stream outStream)
|
||||
{
|
||||
byte[] array = Base64.Encode(data, off, length);
|
||||
int num = outStream.ReadByte();
|
||||
return array.Length;
|
||||
}
|
||||
|
||||
// Token: 0x06007DCE RID: 32206 RVA: 0x001A6824 File Offset: 0x001A4A24
|
||||
[Token(Token = "0x6007DCE")]
|
||||
[Address(RVA = "0x1C5D450", Offset = "0x1C5BE50", VA = "0x181C5D450")]
|
||||
public static byte[] Decode(byte[] data)
|
||||
{
|
||||
return Convert.FromBase64String(Strings.FromAsciiByteArray(data));
|
||||
}
|
||||
|
||||
// Token: 0x06007DCF RID: 32207 RVA: 0x001A683C File Offset: 0x001A4A3C
|
||||
[Token(Token = "0x6007DCF")]
|
||||
[Address(RVA = "0x1C5D550", Offset = "0x1C5BF50", VA = "0x181C5D550")]
|
||||
public static byte[] Decode(string data)
|
||||
{
|
||||
return Convert.FromBase64String(data);
|
||||
}
|
||||
|
||||
// Token: 0x06007DD0 RID: 32208 RVA: 0x001A6850 File Offset: 0x001A4A50
|
||||
[Token(Token = "0x6007DD0")]
|
||||
[Address(RVA = "0x1C5D4B0", Offset = "0x1C5BEB0", VA = "0x181C5D4B0")]
|
||||
public static int Decode(string data, Stream outStream)
|
||||
{
|
||||
byte[] array = Convert.FromBase64String(data);
|
||||
int num = outStream.ReadByte();
|
||||
return array.Length;
|
||||
}
|
||||
}
|
||||
}
|
||||
+268
@@ -0,0 +1,268 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x0200136D RID: 4973
|
||||
[Token(Token = "0x200136D")]
|
||||
[StructLayout(3)]
|
||||
public class Base64Encoder : IEncoder
|
||||
{
|
||||
// Token: 0x06007DD1 RID: 32209 RVA: 0x001A6878 File Offset: 0x001A4A78
|
||||
[Token(Token = "0x6007DD1")]
|
||||
[Address(RVA = "0x1C5CCE0", Offset = "0x1C5B6E0", VA = "0x181C5CCE0")]
|
||||
protected void InitialiseDecodingTable()
|
||||
{
|
||||
int num = this.decodingTable.Length;
|
||||
if (num > 0)
|
||||
{
|
||||
num--;
|
||||
}
|
||||
byte[] array = this.encodingTable;
|
||||
int num2 = 0;
|
||||
if (num2 < array.Length)
|
||||
{
|
||||
byte[] array2 = this.decodingTable;
|
||||
num2++;
|
||||
byte[] array3 = this.encodingTable;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06007DD2 RID: 32210 RVA: 0x001A68C4 File Offset: 0x001A4AC4
|
||||
[Token(Token = "0x6007DD2")]
|
||||
[Address(RVA = "0x1C5CDF0", Offset = "0x1C5B7F0", VA = "0x181C5CDF0")]
|
||||
public Base64Encoder()
|
||||
{
|
||||
byte[] array = new byte[64];
|
||||
RuntimeHelpers.InitializeArray(array, fieldof(<PrivateImplementationDetails>.0953DF544832295E4A5B19928F95C351F25DA86A).FieldHandle);
|
||||
this.encodingTable = array;
|
||||
this.padding = (byte)((ulong)61L);
|
||||
byte[] array2 = new byte[128];
|
||||
this.decodingTable = array2;
|
||||
base..ctor();
|
||||
int num = this.decodingTable.Length;
|
||||
if (num > 0)
|
||||
{
|
||||
num--;
|
||||
}
|
||||
byte[] array3 = this.encodingTable;
|
||||
int num2 = 0;
|
||||
if (num2 < array3.Length)
|
||||
{
|
||||
byte[] array4 = this.decodingTable;
|
||||
num2++;
|
||||
byte[] array5 = this.encodingTable;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x06007DD3 RID: 32211 RVA: 0x001A6954 File Offset: 0x001A4B54
|
||||
[Token(Token = "0x6007DD3")]
|
||||
[Address(RVA = "0x1C5C850", Offset = "0x1C5B250", VA = "0x181C5C850", Slot = "4")]
|
||||
public int Encode(byte[] data, int off, int length, Stream outStream)
|
||||
{
|
||||
int length2 = data.Length;
|
||||
int num = off + 1;
|
||||
byte b = data[num];
|
||||
byte[] array = this.encodingTable;
|
||||
byte[] array2 = this.encodingTable;
|
||||
byte[] array3 = this.encodingTable;
|
||||
byte[] array4 = this.encodingTable;
|
||||
byte b2;
|
||||
if (length != 0)
|
||||
{
|
||||
if (length == 0)
|
||||
{
|
||||
goto IL_70;
|
||||
}
|
||||
if (length == 1)
|
||||
{
|
||||
int length3 = data.Length;
|
||||
byte[] array5 = this.encodingTable;
|
||||
byte[] array6 = this.encodingTable;
|
||||
byte[] array7 = this.encodingTable;
|
||||
b2 = this.padding;
|
||||
}
|
||||
}
|
||||
b2 += b2;
|
||||
IL_70:
|
||||
byte[] array8 = this.encodingTable;
|
||||
byte[] array9 = this.encodingTable;
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007DD4 RID: 32212 RVA: 0x001A69E8 File Offset: 0x001A4BE8
|
||||
[Token(Token = "0x6007DD4")]
|
||||
[Address(RVA = "0x1C5D360", Offset = "0x1C5BD60", VA = "0x181C5D360")]
|
||||
private bool ignore(char c)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// Token: 0x06007DD5 RID: 32213 RVA: 0x001A69F8 File Offset: 0x001A4BF8
|
||||
[Token(Token = "0x6007DD5")]
|
||||
[Address(RVA = "0x1C5C340", Offset = "0x1C5AD40", VA = "0x181C5C340", Slot = "5")]
|
||||
public int Decode(byte[] data, int off, int length, Stream outStream)
|
||||
{
|
||||
int num = 0;
|
||||
if (off >= length || off == 250)
|
||||
{
|
||||
}
|
||||
if (off < length)
|
||||
{
|
||||
byte[] array = this.decodingTable;
|
||||
int length2 = data.Length;
|
||||
int length3 = array.Length;
|
||||
if (off >= length || off == 250)
|
||||
{
|
||||
}
|
||||
if (off < length)
|
||||
{
|
||||
if (off == 250)
|
||||
{
|
||||
}
|
||||
bool flag;
|
||||
if (flag)
|
||||
{
|
||||
}
|
||||
}
|
||||
if (off < length)
|
||||
{
|
||||
if (off == 250)
|
||||
{
|
||||
}
|
||||
bool flag2;
|
||||
if (flag2)
|
||||
{
|
||||
}
|
||||
}
|
||||
num += 3;
|
||||
if (off < length)
|
||||
{
|
||||
int length4 = data.Length;
|
||||
if (off == 250)
|
||||
{
|
||||
}
|
||||
if (off < length)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
int length5 = data.Length;
|
||||
int num2;
|
||||
num2 += num;
|
||||
return num2;
|
||||
}
|
||||
|
||||
// Token: 0x06007DD6 RID: 32214 RVA: 0x001A6A94 File Offset: 0x001A4C94
|
||||
[Token(Token = "0x6007DD6")]
|
||||
[Address(RVA = "0x1C5D380", Offset = "0x1C5BD80", VA = "0x181C5D380")]
|
||||
private int nextI(byte[] data, int i, int finish)
|
||||
{
|
||||
if (i >= finish || i == 250)
|
||||
{
|
||||
}
|
||||
return i;
|
||||
}
|
||||
|
||||
// Token: 0x06007DD7 RID: 32215 RVA: 0x001A6AB4 File Offset: 0x001A4CB4
|
||||
[Token(Token = "0x6007DD7")]
|
||||
[Address(RVA = "0x1C5BF80", Offset = "0x1C5A980", VA = "0x181C5BF80", Slot = "6")]
|
||||
public int DecodeString(string data, Stream outStream)
|
||||
{
|
||||
int num = 0;
|
||||
int num2 = data.m_stringLength;
|
||||
uint num4;
|
||||
if (num2 > 0)
|
||||
{
|
||||
int num3 = num2 - 1;
|
||||
char c = data[num3];
|
||||
if (num4 == data)
|
||||
{
|
||||
}
|
||||
num2 = num3;
|
||||
}
|
||||
int num5 = 0;
|
||||
int num6 = this.nextI(data, num5, (int)num4);
|
||||
if (num6 < (int)num4)
|
||||
{
|
||||
byte[] array = this.decodingTable;
|
||||
char c2 = data[num6];
|
||||
int num7 = num6 + 1;
|
||||
int num8 = this.nextI(data, num7, (int)num4);
|
||||
byte[] array2 = this.decodingTable;
|
||||
char c3 = data[num8];
|
||||
int num9 = num8 + 1;
|
||||
int num10 = this.nextI(data, num9, (int)num4);
|
||||
byte[] array3 = this.decodingTable;
|
||||
char c4 = data[num10];
|
||||
int num11 = num10 + 1;
|
||||
int num12 = this.nextI(data, num11, (int)num4);
|
||||
byte[] array4 = this.decodingTable;
|
||||
num10 = num12;
|
||||
char c5 = data[num12];
|
||||
int num13 = num10 + 1;
|
||||
if (num13 < (int)num4)
|
||||
{
|
||||
char c6 = data[num13];
|
||||
uint num14;
|
||||
if (num14 == data)
|
||||
{
|
||||
}
|
||||
num13++;
|
||||
}
|
||||
}
|
||||
char c7 = data[(int)num4];
|
||||
char c8 = data[(int)num4];
|
||||
char c9 = data[(int)num4];
|
||||
int num15 = num2 - 1;
|
||||
char c10 = data[num15];
|
||||
int num16;
|
||||
num16 += num;
|
||||
return num16;
|
||||
}
|
||||
|
||||
// Token: 0x06007DD8 RID: 32216 RVA: 0x001A6BE4 File Offset: 0x001A4DE4
|
||||
[Token(Token = "0x6007DD8")]
|
||||
[Address(RVA = "0x1C5CF60", Offset = "0x1C5B960", VA = "0x181C5CF60")]
|
||||
private int decodeLastBlock(Stream outStream, char c1, char c2, char c3, char c4)
|
||||
{
|
||||
byte b = this.padding;
|
||||
byte[] array = this.decodingTable;
|
||||
int length = array.Length;
|
||||
return 3;
|
||||
}
|
||||
|
||||
// Token: 0x06007DD9 RID: 32217 RVA: 0x001A6C28 File Offset: 0x001A4E28
|
||||
[Token(Token = "0x6007DD9")]
|
||||
[Address(RVA = "0x1C5D3E0", Offset = "0x1C5BDE0", VA = "0x181C5D3E0")]
|
||||
private int nextI(string data, int i, int finish)
|
||||
{
|
||||
if (i < finish)
|
||||
{
|
||||
char c = data[i];
|
||||
if ((uint)65530 == data)
|
||||
{
|
||||
}
|
||||
}
|
||||
return i;
|
||||
}
|
||||
|
||||
// Token: 0x04005A3D RID: 23101
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
||||
[Token(Token = "0x4005A3D")]
|
||||
protected readonly byte[] encodingTable;
|
||||
|
||||
// Token: 0x04005A3E RID: 23102
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x18")]
|
||||
[Token(Token = "0x4005A3E")]
|
||||
protected byte padding;
|
||||
|
||||
// Token: 0x04005A3F RID: 23103
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x20")]
|
||||
[Token(Token = "0x4005A3F")]
|
||||
protected readonly byte[] decodingTable;
|
||||
}
|
||||
}
|
||||
+104
@@ -0,0 +1,104 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x0200136E RID: 4974
|
||||
[Token(Token = "0x200136E")]
|
||||
[StructLayout(3)]
|
||||
public class BufferedDecoder
|
||||
{
|
||||
// Token: 0x06007DDA RID: 32218 RVA: 0x001A6C54 File Offset: 0x001A4E54
|
||||
[Token(Token = "0x6007DDA")]
|
||||
[Address(RVA = "0x1C5E130", Offset = "0x1C5CB30", VA = "0x181C5E130")]
|
||||
public BufferedDecoder(ITranslator translator, int bufferSize)
|
||||
{
|
||||
/*
|
||||
An exception occurred when decompiling this method (06007DDA)
|
||||
|
||||
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders.BufferedDecoder::.ctor(BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders.ITranslator,System.Int32)
|
||||
|
||||
---> System.Exception: Basic block has to end with unconditional control flow.
|
||||
{
|
||||
IL_2A:
|
||||
stloc:ArgumentException(var_1_34, newobj:ArgumentException(ArgumentException::.ctor, ldstr:string("buffer size not multiple of input block size")))
|
||||
}
|
||||
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1846
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
|
||||
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
|
||||
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
|
||||
--- End of inner exception stack trace ---
|
||||
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
|
||||
at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1663
|
||||
*/;
|
||||
}
|
||||
|
||||
// Token: 0x06007DDB RID: 32219 RVA: 0x001A6C98 File Offset: 0x001A4E98
|
||||
[Token(Token = "0x6007DDB")]
|
||||
[Address(RVA = "0x1C5DE80", Offset = "0x1C5C880", VA = "0x181C5DE80")]
|
||||
public int ProcessByte(byte input, byte[] output, int outOff)
|
||||
{
|
||||
int num = this.bufOff;
|
||||
int num2 = 0;
|
||||
byte[] array = this.buffer;
|
||||
int num3 = num + 1;
|
||||
this.bufOff = num3;
|
||||
int length = this.buffer.Length;
|
||||
if (this.bufOff == length)
|
||||
{
|
||||
ITranslator translator = this.translator;
|
||||
this.bufOff = (int)((ulong)0L);
|
||||
}
|
||||
return num2;
|
||||
}
|
||||
|
||||
// Token: 0x06007DDC RID: 32220 RVA: 0x001A6CF0 File Offset: 0x001A4EF0
|
||||
[Token(Token = "0x6007DDC")]
|
||||
[Address(RVA = "0x1C5DF60", Offset = "0x1C5C960", VA = "0x181C5DF60")]
|
||||
public int ProcessBytes(byte[] input, int inOff, int len, byte[] outBytes, int outOff)
|
||||
{
|
||||
byte[] array = this.buffer;
|
||||
int num = 0;
|
||||
int num2 = array.Length;
|
||||
int num3 = this.bufOff;
|
||||
num2 -= num3;
|
||||
if (len > num2)
|
||||
{
|
||||
Array.Copy(input, inOff, array, num3, num2);
|
||||
byte[] array2 = this.buffer;
|
||||
ITranslator translator = this.translator;
|
||||
int length = array2.Length;
|
||||
byte[] array3 = this.buffer;
|
||||
this.bufOff = num;
|
||||
ITranslator translator2 = this.translator;
|
||||
}
|
||||
if (len != 0)
|
||||
{
|
||||
int num4 = this.bufOff;
|
||||
byte[] array4 = this.buffer;
|
||||
Array.Copy(input, inOff, array4, num4, len);
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
// Token: 0x04005A40 RID: 23104
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
||||
[Token(Token = "0x4005A40")]
|
||||
internal byte[] buffer;
|
||||
|
||||
// Token: 0x04005A41 RID: 23105
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x18")]
|
||||
[Token(Token = "0x4005A41")]
|
||||
internal int bufOff;
|
||||
|
||||
// Token: 0x04005A42 RID: 23106
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x20")]
|
||||
[Token(Token = "0x4005A42")]
|
||||
internal ITranslator translator;
|
||||
}
|
||||
}
|
||||
+104
@@ -0,0 +1,104 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x0200136F RID: 4975
|
||||
[Token(Token = "0x200136F")]
|
||||
[StructLayout(3)]
|
||||
public class BufferedEncoder
|
||||
{
|
||||
// Token: 0x06007DDD RID: 32221 RVA: 0x001A6D88 File Offset: 0x001A4F88
|
||||
[Token(Token = "0x6007DDD")]
|
||||
[Address(RVA = "0x1C5E4A0", Offset = "0x1C5CEA0", VA = "0x181C5E4A0")]
|
||||
public BufferedEncoder(ITranslator translator, int bufferSize)
|
||||
{
|
||||
/*
|
||||
An exception occurred when decompiling this method (06007DDD)
|
||||
|
||||
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders.BufferedEncoder::.ctor(BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders.ITranslator,System.Int32)
|
||||
|
||||
---> System.Exception: Basic block has to end with unconditional control flow.
|
||||
{
|
||||
IL_2A:
|
||||
stloc:ArgumentException(var_1_34, newobj:ArgumentException(ArgumentException::.ctor, ldstr:string("buffer size not multiple of input block size")))
|
||||
}
|
||||
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1852
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1878
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.FlattenBasicBlocks(ILNode node) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 1846
|
||||
at ICSharpCode.Decompiler.ILAst.ILAstOptimizer.Optimize(DecompilerContext context, ILBlock method, AutoPropertyProvider autoPropertyProvider, StateMachineKind& stateMachineKind, MethodDef& inlinedMethod, AsyncMethodDebugInfo& asyncInfo, ILAstOptimizationStep abortBeforeStep) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\ILAst\ILAstOptimizer.cs:line 355
|
||||
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(IEnumerable`1 parameters, MethodDebugInfoBuilder& builder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 123
|
||||
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 88
|
||||
--- End of inner exception stack trace ---
|
||||
at ICSharpCode.Decompiler.Ast.AstMethodBodyBuilder.CreateMethodBody(MethodDef methodDef, DecompilerContext context, AutoPropertyProvider autoPropertyProvider, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, StringBuilder sb, MethodDebugInfoBuilder& stmtsBuilder) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstMethodBodyBuilder.cs:line 92
|
||||
at ICSharpCode.Decompiler.Ast.AstBuilder.AddMethodBody(EntityDeclaration methodNode, EntityDeclaration& updatedNode, MethodDef method, IEnumerable`1 parameters, Boolean valueParameterIsKeyword, MethodKind methodKind) in D:\a\dnSpy\dnSpy\Extensions\ILSpy.Decompiler\ICSharpCode.Decompiler\ICSharpCode.Decompiler\Ast\AstBuilder.cs:line 1663
|
||||
*/;
|
||||
}
|
||||
|
||||
// Token: 0x06007DDE RID: 32222 RVA: 0x001A6DCC File Offset: 0x001A4FCC
|
||||
[Token(Token = "0x6007DDE")]
|
||||
[Address(RVA = "0x1C5E1F0", Offset = "0x1C5CBF0", VA = "0x181C5E1F0")]
|
||||
public int ProcessByte(byte input, byte[] outBytes, int outOff)
|
||||
{
|
||||
int num = this.bufOff;
|
||||
int num2 = 0;
|
||||
byte[] buffer = this.Buffer;
|
||||
int num3 = num + 1;
|
||||
this.bufOff = num3;
|
||||
int length = this.Buffer.Length;
|
||||
if (this.bufOff == length)
|
||||
{
|
||||
ITranslator translator = this.translator;
|
||||
this.bufOff = (int)((ulong)0L);
|
||||
}
|
||||
return num2;
|
||||
}
|
||||
|
||||
// Token: 0x06007DDF RID: 32223 RVA: 0x001A6E24 File Offset: 0x001A5024
|
||||
[Token(Token = "0x6007DDF")]
|
||||
[Address(RVA = "0x1C5E2D0", Offset = "0x1C5CCD0", VA = "0x181C5E2D0")]
|
||||
public int ProcessBytes(byte[] input, int inOff, int len, byte[] outBytes, int outOff)
|
||||
{
|
||||
byte[] buffer = this.Buffer;
|
||||
int num = 0;
|
||||
int num2 = buffer.Length;
|
||||
int num3 = this.bufOff;
|
||||
num2 -= num3;
|
||||
if (len > num2)
|
||||
{
|
||||
Array.Copy(input, inOff, buffer, num3, num2);
|
||||
byte[] buffer2 = this.Buffer;
|
||||
ITranslator translator = this.translator;
|
||||
int length = buffer2.Length;
|
||||
byte[] buffer3 = this.Buffer;
|
||||
this.bufOff = num;
|
||||
ITranslator translator2 = this.translator;
|
||||
}
|
||||
if (len != 0)
|
||||
{
|
||||
int num4 = this.bufOff;
|
||||
byte[] buffer4 = this.Buffer;
|
||||
Array.Copy(input, inOff, buffer4, num4, len);
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
// Token: 0x04005A43 RID: 23107
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
||||
[Token(Token = "0x4005A43")]
|
||||
internal byte[] Buffer;
|
||||
|
||||
// Token: 0x04005A44 RID: 23108
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x18")]
|
||||
[Token(Token = "0x4005A44")]
|
||||
internal int bufOff;
|
||||
|
||||
// Token: 0x04005A45 RID: 23109
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x20")]
|
||||
[Token(Token = "0x4005A45")]
|
||||
internal ITranslator translator;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,122 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x02001370 RID: 4976
|
||||
[Token(Token = "0x2001370")]
|
||||
[StructLayout(3)]
|
||||
public sealed class Hex
|
||||
{
|
||||
// Token: 0x06007DE0 RID: 32224 RVA: 0x001A6EBC File Offset: 0x001A50BC
|
||||
[Token(Token = "0x6007DE0")]
|
||||
[Address(RVA = "0x3C1670", Offset = "0x3C0070", VA = "0x1803C1670")]
|
||||
private Hex()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x06007DE1 RID: 32225 RVA: 0x001A6ED0 File Offset: 0x001A50D0
|
||||
[Token(Token = "0x6007DE1")]
|
||||
[Address(RVA = "0x1C608B0", Offset = "0x1C5F2B0", VA = "0x181C608B0")]
|
||||
public static string ToHexString(byte[] data)
|
||||
{
|
||||
int length = data.Length;
|
||||
int num = 0;
|
||||
return Strings.FromAsciiByteArray(Hex.Encode(data, num, length));
|
||||
}
|
||||
|
||||
// Token: 0x06007DE2 RID: 32226 RVA: 0x001A6EFC File Offset: 0x001A50FC
|
||||
[Token(Token = "0x6007DE2")]
|
||||
[Address(RVA = "0x1C60970", Offset = "0x1C5F370", VA = "0x181C60970")]
|
||||
public static string ToHexString(byte[] data, int off, int length)
|
||||
{
|
||||
return Strings.FromAsciiByteArray(Hex.Encode(data, off, length));
|
||||
}
|
||||
|
||||
// Token: 0x06007DE3 RID: 32227 RVA: 0x001A6F18 File Offset: 0x001A5118
|
||||
[Token(Token = "0x6007DE3")]
|
||||
[Address(RVA = "0x1C606F0", Offset = "0x1C5F0F0", VA = "0x181C606F0")]
|
||||
public static byte[] Encode(byte[] data)
|
||||
{
|
||||
int length = data.Length;
|
||||
int num = 0;
|
||||
return Hex.Encode(data, num, length);
|
||||
}
|
||||
|
||||
// Token: 0x06007DE4 RID: 32228 RVA: 0x001A6F3C File Offset: 0x001A513C
|
||||
[Token(Token = "0x6007DE4")]
|
||||
[Address(RVA = "0x1C60610", Offset = "0x1C5F010", VA = "0x181C60610")]
|
||||
public static byte[] Encode(byte[] data, int off, int length)
|
||||
{
|
||||
MemoryStream memoryStream = new MemoryStream(off);
|
||||
((IDisposable)memoryStream).Dispose();
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007DE5 RID: 32229 RVA: 0x001A6F60 File Offset: 0x001A5160
|
||||
[Token(Token = "0x6007DE5")]
|
||||
[Address(RVA = "0x1C60810", Offset = "0x1C5F210", VA = "0x181C60810")]
|
||||
public static int Encode(byte[] data, Stream outStream)
|
||||
{
|
||||
return data.Length;
|
||||
}
|
||||
|
||||
// Token: 0x06007DE6 RID: 32230 RVA: 0x001A6F7C File Offset: 0x001A517C
|
||||
[Token(Token = "0x6007DE6")]
|
||||
[Address(RVA = "0x1C60760", Offset = "0x1C5F160", VA = "0x181C60760")]
|
||||
public static int Encode(byte[] data, int off, int length, Stream outStream)
|
||||
{
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007DE7 RID: 32231 RVA: 0x001A6F90 File Offset: 0x001A5190
|
||||
[Token(Token = "0x6007DE7")]
|
||||
[Address(RVA = "0x1C604A0", Offset = "0x1C5EEA0", VA = "0x181C604A0")]
|
||||
public static byte[] Decode(byte[] data)
|
||||
{
|
||||
int num;
|
||||
MemoryStream memoryStream = new MemoryStream(num);
|
||||
num = data.Length;
|
||||
num++;
|
||||
int length = data.Length;
|
||||
((IDisposable)memoryStream).Dispose();
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007DE8 RID: 32232 RVA: 0x001A6FC4 File Offset: 0x001A51C4
|
||||
[Token(Token = "0x6007DE8")]
|
||||
[Address(RVA = "0x1C603C0", Offset = "0x1C5EDC0", VA = "0x181C603C0")]
|
||||
public static byte[] Decode(string data)
|
||||
{
|
||||
int stringLength = data.m_stringLength;
|
||||
int num;
|
||||
MemoryStream memoryStream = new MemoryStream(num);
|
||||
num = stringLength + 1;
|
||||
((IDisposable)memoryStream).Dispose();
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007DE9 RID: 32233 RVA: 0x001A6FF0 File Offset: 0x001A51F0
|
||||
[Token(Token = "0x6007DE9")]
|
||||
[Address(RVA = "0x1C60580", Offset = "0x1C5EF80", VA = "0x181C60580")]
|
||||
public static int Decode(string data, Stream outStream)
|
||||
{
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007DEA RID: 32234 RVA: 0x001A7004 File Offset: 0x001A5204
|
||||
// Note: this type is marked as 'beforefieldinit'.
|
||||
[Token(Token = "0x6007DEA")]
|
||||
[Address(RVA = "0x1C609F0", Offset = "0x1C5F3F0", VA = "0x181C609F0")]
|
||||
static Hex()
|
||||
{
|
||||
HexEncoder hexEncoder = new HexEncoder();
|
||||
}
|
||||
|
||||
// Token: 0x04005A46 RID: 23110
|
||||
[Token(Token = "0x4005A46")]
|
||||
private static readonly IEncoder encoder;
|
||||
}
|
||||
}
|
||||
+163
@@ -0,0 +1,163 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x02001371 RID: 4977
|
||||
[Token(Token = "0x2001371")]
|
||||
[StructLayout(3)]
|
||||
public class HexEncoder : IEncoder
|
||||
{
|
||||
// Token: 0x06007DEB RID: 32235 RVA: 0x001A7018 File Offset: 0x001A5218
|
||||
[Token(Token = "0x6007DEB")]
|
||||
[Address(RVA = "0x202B4E0", Offset = "0x2029EE0", VA = "0x18202B4E0")]
|
||||
protected void InitialiseDecodingTable()
|
||||
{
|
||||
byte[] array = this.decodingTable;
|
||||
byte[] array2 = this.encodingTable;
|
||||
int num = 0;
|
||||
if (num < array2.Length)
|
||||
{
|
||||
byte[] array3 = this.decodingTable;
|
||||
num++;
|
||||
byte[] array4 = this.encodingTable;
|
||||
}
|
||||
byte[] array5 = this.decodingTable;
|
||||
byte b = array5[12];
|
||||
array5[8] = b;
|
||||
byte[] array6 = this.decodingTable;
|
||||
byte b2 = array6[12];
|
||||
array6[8] = b2;
|
||||
byte[] array7 = this.decodingTable;
|
||||
byte b3 = array7[12];
|
||||
array7[8] = b3;
|
||||
byte[] array8 = this.decodingTable;
|
||||
byte b4 = array8[12];
|
||||
array8[8] = b4;
|
||||
byte[] array9 = this.decodingTable;
|
||||
byte b5 = array9[12];
|
||||
array9[8] = b5;
|
||||
byte[] array10 = this.decodingTable;
|
||||
byte b6 = array10[12];
|
||||
array10[8] = b6;
|
||||
}
|
||||
|
||||
// Token: 0x06007DEC RID: 32236 RVA: 0x001A7108 File Offset: 0x001A5308
|
||||
[Token(Token = "0x6007DEC")]
|
||||
[Address(RVA = "0x202B720", Offset = "0x202A120", VA = "0x18202B720")]
|
||||
public HexEncoder()
|
||||
{
|
||||
byte[] array = new byte[16];
|
||||
RuntimeHelpers.InitializeArray(array, fieldof(<PrivateImplementationDetails>.FE5567E8D769550852182CDF69D74BB16DFF8E29).FieldHandle);
|
||||
this.encodingTable = array;
|
||||
byte[] array2 = new byte[128];
|
||||
this.decodingTable = array2;
|
||||
base..ctor();
|
||||
this.InitialiseDecodingTable();
|
||||
}
|
||||
|
||||
// Token: 0x06007DED RID: 32237 RVA: 0x001A7150 File Offset: 0x001A5350
|
||||
[Token(Token = "0x6007DED")]
|
||||
[Address(RVA = "0x202B3A0", Offset = "0x2029DA0", VA = "0x18202B3A0", Slot = "4")]
|
||||
public int Encode(byte[] data, int off, int length, Stream outStream)
|
||||
{
|
||||
byte[] array = this.encodingTable;
|
||||
byte[] array2 = this.encodingTable;
|
||||
return off;
|
||||
}
|
||||
|
||||
// Token: 0x06007DEE RID: 32238 RVA: 0x001A7174 File Offset: 0x001A5374
|
||||
[Token(Token = "0x6007DEE")]
|
||||
[Address(RVA = "0x202B4C0", Offset = "0x2029EC0", VA = "0x18202B4C0")]
|
||||
private static bool Ignore(char c)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// Token: 0x06007DEF RID: 32239 RVA: 0x001A7184 File Offset: 0x001A5384
|
||||
[Token(Token = "0x6007DEF")]
|
||||
[Address(RVA = "0x202B150", Offset = "0x2029B50", VA = "0x18202B150", Slot = "5")]
|
||||
public int Decode(byte[] data, int off, int length, Stream outStream)
|
||||
{
|
||||
int num = 0;
|
||||
if (off < length)
|
||||
{
|
||||
if (length == 250)
|
||||
{
|
||||
}
|
||||
if (off < length)
|
||||
{
|
||||
if (length == 250)
|
||||
{
|
||||
}
|
||||
byte[] array = this.decodingTable;
|
||||
int length2 = data.Length;
|
||||
int length3 = array.Length;
|
||||
if (off >= length || length == 250)
|
||||
{
|
||||
}
|
||||
num++;
|
||||
}
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
// Token: 0x06007DF0 RID: 32240 RVA: 0x001A71E8 File Offset: 0x001A53E8
|
||||
[Token(Token = "0x6007DF0")]
|
||||
[Address(RVA = "0x202AF40", Offset = "0x2029940", VA = "0x18202AF40", Slot = "6")]
|
||||
public int DecodeString(string data, Stream outStream)
|
||||
{
|
||||
int num = 0;
|
||||
int num2 = data.m_stringLength;
|
||||
if (num2 > 0)
|
||||
{
|
||||
int num3 = num2 - 1;
|
||||
char c = data[num3];
|
||||
if ((uint)65530 == (uint)c)
|
||||
{
|
||||
}
|
||||
num2 = num3;
|
||||
}
|
||||
if (num2 > 0)
|
||||
{
|
||||
if (num < num2)
|
||||
{
|
||||
char c2 = data[num];
|
||||
if ((uint)65530 == (uint)c2)
|
||||
{
|
||||
}
|
||||
num++;
|
||||
}
|
||||
byte[] array = this.decodingTable;
|
||||
num++;
|
||||
char c3 = data[num];
|
||||
if (num < num2)
|
||||
{
|
||||
char c4 = data[num];
|
||||
if ((uint)65530 == (uint)c4)
|
||||
{
|
||||
}
|
||||
num++;
|
||||
}
|
||||
byte[] array2 = this.decodingTable;
|
||||
num++;
|
||||
char c5 = data[num];
|
||||
num++;
|
||||
}
|
||||
return num;
|
||||
}
|
||||
|
||||
// Token: 0x04005A47 RID: 23111
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
||||
[Token(Token = "0x4005A47")]
|
||||
protected readonly byte[] encodingTable;
|
||||
|
||||
// Token: 0x04005A48 RID: 23112
|
||||
[global::Cpp2IlInjected.FieldOffset(Offset = "0x18")]
|
||||
[Token(Token = "0x4005A48")]
|
||||
protected readonly byte[] decodingTable;
|
||||
}
|
||||
}
|
||||
+76
@@ -0,0 +1,76 @@
|
||||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x02001372 RID: 4978
|
||||
[Token(Token = "0x2001372")]
|
||||
[StructLayout(3)]
|
||||
public class HexTranslator : ITranslator
|
||||
{
|
||||
// Token: 0x06007DF1 RID: 32241 RVA: 0x001A7294 File Offset: 0x001A5494
|
||||
[Token(Token = "0x6007DF1")]
|
||||
[Address(RVA = "0x8509C0", Offset = "0x84F3C0", VA = "0x1808509C0", Slot = "4")]
|
||||
public int GetEncodedBlockSize()
|
||||
{
|
||||
return 2;
|
||||
}
|
||||
|
||||
// Token: 0x06007DF2 RID: 32242 RVA: 0x001A72A4 File Offset: 0x001A54A4
|
||||
[Token(Token = "0x6007DF2")]
|
||||
[Address(RVA = "0x202B8F0", Offset = "0x202A2F0", VA = "0x18202B8F0", Slot = "5")]
|
||||
public int Encode(byte[] input, int inOff, int length, byte[] outBytes, int outOff)
|
||||
{
|
||||
int num = 0;
|
||||
if (length > 0)
|
||||
{
|
||||
num++;
|
||||
}
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007DF3 RID: 32243 RVA: 0x001A72C0 File Offset: 0x001A54C0
|
||||
[Token(Token = "0x6007DF3")]
|
||||
[Address(RVA = "0x3E2800", Offset = "0x3E1200", VA = "0x1803E2800", Slot = "6")]
|
||||
public int GetDecodedBlockSize()
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
// Token: 0x06007DF4 RID: 32244 RVA: 0x001A72D0 File Offset: 0x001A54D0
|
||||
[Token(Token = "0x6007DF4")]
|
||||
[Address(RVA = "0x202B7B0", Offset = "0x202A1B0", VA = "0x18202B7B0", Slot = "7")]
|
||||
public int Decode(byte[] input, int inOff, int length, byte[] outBytes, int outOff)
|
||||
{
|
||||
int num = 0;
|
||||
if (length > 0)
|
||||
{
|
||||
int length2 = input.Length;
|
||||
num++;
|
||||
}
|
||||
return length;
|
||||
}
|
||||
|
||||
// Token: 0x06007DF5 RID: 32245 RVA: 0x001A72F8 File Offset: 0x001A54F8
|
||||
[Token(Token = "0x6007DF5")]
|
||||
[Address(RVA = "0x3C1670", Offset = "0x3C0070", VA = "0x1803C1670")]
|
||||
public HexTranslator()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x06007DF6 RID: 32246 RVA: 0x001A730C File Offset: 0x001A550C
|
||||
// Note: this type is marked as 'beforefieldinit'.
|
||||
[Token(Token = "0x6007DF6")]
|
||||
[Address(RVA = "0x202BAA0", Offset = "0x202A4A0", VA = "0x18202BAA0")]
|
||||
static HexTranslator()
|
||||
{
|
||||
RuntimeHelpers.InitializeArray(new byte[16], fieldof(<PrivateImplementationDetails>.FE5567E8D769550852182CDF69D74BB16DFF8E29).FieldHandle);
|
||||
}
|
||||
|
||||
// Token: 0x04005A49 RID: 23113
|
||||
[Token(Token = "0x4005A49")]
|
||||
private static readonly byte[] hexTable;
|
||||
}
|
||||
}
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x02001373 RID: 4979
|
||||
[Token(Token = "0x2001373")]
|
||||
[StructLayout(3)]
|
||||
public interface IEncoder
|
||||
{
|
||||
// Token: 0x06007DF7 RID: 32247
|
||||
[Token(Token = "0x6007DF7")]
|
||||
[Address(Slot = "0")]
|
||||
int Encode(byte[] data, int off, int length, Stream outStream);
|
||||
|
||||
// Token: 0x06007DF8 RID: 32248
|
||||
[Token(Token = "0x6007DF8")]
|
||||
[Address(Slot = "1")]
|
||||
int Decode(byte[] data, int off, int length, Stream outStream);
|
||||
|
||||
// Token: 0x06007DF9 RID: 32249
|
||||
[Token(Token = "0x6007DF9")]
|
||||
[Address(Slot = "2")]
|
||||
int DecodeString(string data, Stream outStream);
|
||||
}
|
||||
}
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x02001374 RID: 4980
|
||||
[Token(Token = "0x2001374")]
|
||||
[StructLayout(3)]
|
||||
public interface ITranslator
|
||||
{
|
||||
// Token: 0x06007DFA RID: 32250
|
||||
[Token(Token = "0x6007DFA")]
|
||||
[Address(Slot = "0")]
|
||||
int GetEncodedBlockSize();
|
||||
|
||||
// Token: 0x06007DFB RID: 32251
|
||||
[Token(Token = "0x6007DFB")]
|
||||
[Address(Slot = "1")]
|
||||
int Encode(byte[] input, int inOff, int length, byte[] outBytes, int outOff);
|
||||
|
||||
// Token: 0x06007DFC RID: 32252
|
||||
[Token(Token = "0x6007DFC")]
|
||||
[Address(Slot = "2")]
|
||||
int GetDecodedBlockSize();
|
||||
|
||||
// Token: 0x06007DFD RID: 32253
|
||||
[Token(Token = "0x6007DFD")]
|
||||
[Address(Slot = "3")]
|
||||
int Decode(byte[] input, int inOff, int length, byte[] outBytes, int outOff);
|
||||
}
|
||||
}
|
||||
+91
@@ -0,0 +1,91 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x02001375 RID: 4981
|
||||
[Token(Token = "0x2001375")]
|
||||
[StructLayout(3)]
|
||||
public class UrlBase64
|
||||
{
|
||||
// Token: 0x06007DFE RID: 32254 RVA: 0x001A732C File Offset: 0x001A552C
|
||||
[Token(Token = "0x6007DFE")]
|
||||
[Address(RVA = "0x20353E0", Offset = "0x2033DE0", VA = "0x1820353E0")]
|
||||
public static byte[] Encode(byte[] data)
|
||||
{
|
||||
MemoryStream memoryStream = new MemoryStream();
|
||||
int length = data.Length;
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007DFF RID: 32255 RVA: 0x001A7358 File Offset: 0x001A5558
|
||||
[Token(Token = "0x6007DFF")]
|
||||
[Address(RVA = "0x2035340", Offset = "0x2033D40", VA = "0x182035340")]
|
||||
public static int Encode(byte[] data, Stream outStr)
|
||||
{
|
||||
return data.Length;
|
||||
}
|
||||
|
||||
// Token: 0x06007E00 RID: 32256 RVA: 0x001A7374 File Offset: 0x001A5574
|
||||
[Token(Token = "0x6007E00")]
|
||||
[Address(RVA = "0x20350B0", Offset = "0x2033AB0", VA = "0x1820350B0")]
|
||||
public static byte[] Decode(byte[] data)
|
||||
{
|
||||
MemoryStream memoryStream = new MemoryStream();
|
||||
int length = data.Length;
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007E01 RID: 32257 RVA: 0x001A73A0 File Offset: 0x001A55A0
|
||||
[Token(Token = "0x6007E01")]
|
||||
[Address(RVA = "0x2035210", Offset = "0x2033C10", VA = "0x182035210")]
|
||||
public static int Decode(byte[] data, Stream outStr)
|
||||
{
|
||||
return data.Length;
|
||||
}
|
||||
|
||||
// Token: 0x06007E02 RID: 32258 RVA: 0x001A73BC File Offset: 0x001A55BC
|
||||
[Token(Token = "0x6007E02")]
|
||||
[Address(RVA = "0x2034F60", Offset = "0x2033960", VA = "0x182034F60")]
|
||||
public static byte[] Decode(string data)
|
||||
{
|
||||
MemoryStream memoryStream = new MemoryStream();
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007E03 RID: 32259 RVA: 0x001A73E0 File Offset: 0x001A55E0
|
||||
[Token(Token = "0x6007E03")]
|
||||
[Address(RVA = "0x20352B0", Offset = "0x2033CB0", VA = "0x1820352B0")]
|
||||
public static int Decode(string data, Stream outStr)
|
||||
{
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x06007E04 RID: 32260 RVA: 0x001A73F4 File Offset: 0x001A55F4
|
||||
[Token(Token = "0x6007E04")]
|
||||
[Address(RVA = "0x3C1670", Offset = "0x3C0070", VA = "0x1803C1670")]
|
||||
public UrlBase64()
|
||||
{
|
||||
}
|
||||
|
||||
// Token: 0x06007E05 RID: 32261 RVA: 0x001A7408 File Offset: 0x001A5608
|
||||
// Note: this type is marked as 'beforefieldinit'.
|
||||
[Token(Token = "0x6007E05")]
|
||||
[Address(RVA = "0x2035540", Offset = "0x2033F40", VA = "0x182035540")]
|
||||
static UrlBase64()
|
||||
{
|
||||
UrlBase64Encoder urlBase64Encoder = new UrlBase64Encoder();
|
||||
int length = urlBase64Encoder.encodingTable.Length;
|
||||
urlBase64Encoder.decodingTable = (ulong)45L;
|
||||
int num = urlBase64Encoder.encodingTable.Length - 1;
|
||||
urlBase64Encoder.padding = (byte)((ulong)46L);
|
||||
urlBase64Encoder.InitialiseDecodingTable();
|
||||
}
|
||||
|
||||
// Token: 0x04005A4A RID: 23114
|
||||
[Token(Token = "0x4005A4A")]
|
||||
private static readonly IEncoder encoder;
|
||||
}
|
||||
}
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders
|
||||
{
|
||||
// Token: 0x02001376 RID: 4982
|
||||
[Token(Token = "0x2001376")]
|
||||
[StructLayout(3)]
|
||||
public class UrlBase64Encoder : Base64Encoder
|
||||
{
|
||||
// Token: 0x06007E06 RID: 32262 RVA: 0x001A7458 File Offset: 0x001A5658
|
||||
[Token(Token = "0x6007E06")]
|
||||
[Address(RVA = "0x2034EE0", Offset = "0x20338E0", VA = "0x182034EE0")]
|
||||
public UrlBase64Encoder()
|
||||
{
|
||||
int length = this.encodingTable.Length;
|
||||
this.decodingTable = (ulong)45L;
|
||||
int num = this.encodingTable.Length - 1;
|
||||
this.padding = (byte)((ulong)46L);
|
||||
base.InitialiseDecodingTable();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user