using System; using System.IO; using System.Runtime.CompilerServices; using Cpp2IlInjected; namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Encoders { // Token: 0x02001A2E RID: 6702 [Token(Token = "0x2001A2E")] public class HexEncoder : IEncoder { // Token: 0x06009D93 RID: 40339 RVA: 0x002076B4 File Offset: 0x002058B4 [Token(Token = "0x6009D93")] [Address(RVA = "0x4E80A0", Offset = "0x4E70A0", VA = "0x1804E80A0")] 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; } byte[] array4 = this.decodingTable; byte b = array4[12]; array4[8] = b; byte[] array5 = this.decodingTable; byte b2 = array5[12]; array5[8] = b2; byte[] array6 = this.decodingTable; byte b3 = array6[12]; array6[8] = b3; byte[] array7 = this.decodingTable; byte b4 = array7[12]; array7[8] = b4; byte[] array8 = this.decodingTable; byte b5 = array8[12]; array8[8] = b5; byte[] array9 = this.decodingTable; byte b6 = array9[12]; array9[8] = b6; } // Token: 0x06009D94 RID: 40340 RVA: 0x002077B0 File Offset: 0x002059B0 [Token(Token = "0x6009D94")] [Address(RVA = "0x4E8310", Offset = "0x4E7310", VA = "0x1804E8310")] public HexEncoder() { byte[] array = new byte[16]; RuntimeHelpers.InitializeArray(array, fieldof(.FE5567E8D769550852182CDF69D74BB16DFF8E29).FieldHandle); this.encodingTable = array; byte[] array2 = new byte[128]; this.decodingTable = array2; base..ctor(); this.InitialiseDecodingTable(); } // Token: 0x06009D95 RID: 40341 RVA: 0x002077F8 File Offset: 0x002059F8 [Token(Token = "0x6009D95")] [Address(RVA = "0x4E7F60", Offset = "0x4E6F60", VA = "0x1804E7F60", Slot = "4")] public int Encode(byte[] data, int off, int length, Stream outStream) { byte[] array = this.encodingTable; byte[] array2 = this.encodingTable; return off; } // Token: 0x06009D96 RID: 40342 RVA: 0x0020781C File Offset: 0x00205A1C [Token(Token = "0x6009D96")] [Address(RVA = "0x4E8080", Offset = "0x4E7080", VA = "0x1804E8080")] private static bool Ignore(char c) { return true; } // Token: 0x06009D97 RID: 40343 RVA: 0x0020782C File Offset: 0x00205A2C [Token(Token = "0x6009D97")] [Address(RVA = "0x4E7D10", Offset = "0x4E6D10", VA = "0x1804E7D10", 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: 0x06009D98 RID: 40344 RVA: 0x00207890 File Offset: 0x00205A90 [Token(Token = "0x6009D98")] [Address(RVA = "0x4E7B00", Offset = "0x4E6B00", VA = "0x1804E7B00", 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: 0x04006A43 RID: 27203 [FieldOffset(Offset = "0x10")] [Token(Token = "0x4006A43")] protected readonly byte[] encodingTable; // Token: 0x04006A44 RID: 27204 [FieldOffset(Offset = "0x18")] [Token(Token = "0x4006A44")] protected readonly byte[] decodingTable; } }