using System; using System.Collections; using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1; using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto; using Cpp2IlInjected; namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security { // Token: 0x02001A81 RID: 6785 [Token(Token = "0x2001A81")] public sealed class CipherUtilities { // Token: 0x0600A077 RID: 41079 RVA: 0x00213DEC File Offset: 0x00211FEC [Token(Token = "0x600A077")] [Address(RVA = "0x512050", Offset = "0x511050", VA = "0x180512050")] static CipherUtilities() { /* An exception occurred when decompiling this method (0600A077) ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Security.CipherUtilities::.cctor() ---> System.Exception: Basic block has to end with unconditional control flow. { Block_0: stloc:IDictionary(var_2_09, call:IDictionary(Platform::CreateHashtable)) stsfld:IDictionary(CipherUtilities::algorithms, ldloc:IDictionary(var_2_09)) stsfld:IDictionary(CipherUtilities::oids, call:IDictionary(Platform::CreateHashtable)) stloc:Enum(var_4_2B, call:Enum(Enums::GetArbitraryValue, call:Type(Type::GetTypeFromHandle, ldtoken:RuntimeTypeHandle(BestHTTP.SecureProtocol.Org.BouncyCastle.Security.CipherUtilities/CipherAlgorithm)))) stloc:Enum(var_8_48, call:Enum(Enums::GetArbitraryValue, call:Type(Type::GetTypeFromHandle, ldtoken:RuntimeTypeHandle(BestHTTP.SecureProtocol.Org.BouncyCastle.Security.CipherUtilities/CipherMode)))) stloc:Enum(var_12_65, call:Enum(Enums::GetArbitraryValue, call:Type(Type::GetTypeFromHandle, ldtoken:RuntimeTypeHandle(BestHTTP.SecureProtocol.Org.BouncyCastle.Security.CipherUtilities/CipherPadding)))) stloc:IDictionary(var_16_78, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_17_7F, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes128Ecb)) stloc:IDictionary(var_19_86, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_20_8D, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes192Ecb)) stloc:IDictionary(var_22_94, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_23_9B, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes256Ecb)) stloc:IDictionary(var_25_A2, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_27_A9, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_29_B0, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_31_B7, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_33_BE, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_34_C5, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes128Cbc)) stloc:IDictionary(var_36_CC, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_37_D3, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes192Cbc)) stloc:IDictionary(var_39_DA, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_40_E1, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes256Cbc)) stloc:IDictionary(var_42_E8, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_43_EF, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes128Ofb)) stloc:IDictionary(var_45_F6, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_46_FD, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes192Ofb)) stloc:IDictionary(var_48_104, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_49_10B, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes256Ofb)) stloc:IDictionary(var_51_112, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_52_119, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes128Cfb)) stloc:IDictionary(var_54_120, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_55_127, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes192Cfb)) stloc:IDictionary(var_57_12E, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_58_135, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdAes256Cfb)) stloc:IDictionary(var_60_13C, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_62_143, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_64_14A, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_65_151, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::RsaEncryption)) stloc:IDictionary(var_67_158, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_68_15F, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::IdRsaesOaep)) stloc:IDictionary(var_70_166, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_71_16D, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::DesCbc)) stloc:IDictionary(var_73_174, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_74_17B, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::DesCfb)) stloc:IDictionary(var_76_182, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_77_189, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::DesEcb)) stloc:IDictionary(var_79_190, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_80_197, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::DesOfb)) stloc:IDictionary(var_82_19E, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_83_1A5, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::DesEde)) stloc:IDictionary(var_85_1AC, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_87_1B3, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_88_1BA, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::DesEde3Cbc)) stloc:IDictionary(var_90_1C1, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_91_1C8, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::RC2Cbc)) stloc:IDictionary(var_93_1CF, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_95_1D6, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_97_1DD, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_99_1E4, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_101_1EB, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_103_1F2, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_105_1F9, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_106_200, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd128BitRC4)) stloc:IDictionary(var_108_207, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_110_20E, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_111_215, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd40BitRC4)) stloc:IDictionary(var_113_21C, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_115_223, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_116_22A, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithSha1AndDesCbc)) stloc:IDictionary(var_118_231, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_120_238, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_121_23F, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithSha1AndRC2Cbc)) stloc:IDictionary(var_123_246, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_125_24D, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_127_254, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_128_25B, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd3KeyTripleDesCbc)) stloc:IDictionary(var_130_262, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_132_269, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_134_270, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_135_277, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd2KeyTripleDesCbc)) stloc:IDictionary(var_137_27E, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_139_285, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_140_28C, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd128BitRC2Cbc)) stloc:IDictionary(var_142_293, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_144_29A, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:DerObjectIdentifier(var_145_2A1, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbewithShaAnd40BitRC2Cbc)) stloc:IDictionary(var_147_2A8, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_149_2AF, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_151_2B6, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_153_2BD, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_155_2C4, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_157_2CB, ldsfld:IDictionary(CipherUtilities::algorithms)) stloc:IDictionary(var_159_2D2, ldsfld:IDictionary(CipherUtilities::algorithms)) } 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.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: 0x0600A078 RID: 41080 RVA: 0x002140CC File Offset: 0x002122CC [Token(Token = "0x600A078")] [Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")] private CipherUtilities() { } // Token: 0x0600A079 RID: 41081 RVA: 0x002140E0 File Offset: 0x002122E0 [Token(Token = "0x600A079")] [Address(RVA = "0x511EA0", Offset = "0x510EA0", VA = "0x180511EA0")] public static DerObjectIdentifier GetObjectIdentifier(string mechanism) { /* An exception occurred when decompiling this method (0600A079) ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.DerObjectIdentifier BestHTTP.SecureProtocol.Org.BouncyCastle.Security.CipherUtilities::GetObjectIdentifier(System.String) ---> System.Exception: Basic block has to end with unconditional control flow. { IL_2E: stloc:ArgumentNullException(var_7_38, newobj:ArgumentNullException(ArgumentNullException::.ctor, ldstr:string("mechanism"))) } 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.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: 0x170019A1 RID: 6561 // (get) Token: 0x0600A07A RID: 41082 RVA: 0x00214128 File Offset: 0x00212328 [Token(Token = "0x170019A1")] public static ICollection Algorithms { [Token(Token = "0x600A07A")] [Address(RVA = "0x5137A0", Offset = "0x5127A0", VA = "0x1805137A0")] get { IDictionary dictionary = CipherUtilities.oids; throw new NullReferenceException(); } } // Token: 0x0600A07B RID: 41083 RVA: 0x00214140 File Offset: 0x00212340 [Token(Token = "0x600A07B")] [Address(RVA = "0x5103A0", Offset = "0x50F3A0", VA = "0x1805103A0")] public static IBufferedCipher GetCipher(DerObjectIdentifier oid) { return CipherUtilities.GetCipher(oid.identifier); } // Token: 0x0600A07C RID: 41084 RVA: 0x00214160 File Offset: 0x00212360 [Token(Token = "0x600A07C")] [Address(RVA = "0x510400", Offset = "0x50F400", VA = "0x180510400")] public static IBufferedCipher GetCipher(string algorithm) { /* An exception occurred when decompiling this method (0600A07C) ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IBufferedCipher BestHTTP.SecureProtocol.Org.BouncyCastle.Security.CipherUtilities::GetCipher(System.String) ---> System.Exception: Basic block has to end with unconditional control flow. { IL_535: stloc:Kdf2BytesGenerator(var_102_53F, newobj:Kdf2BytesGenerator(Kdf2BytesGenerator::.ctor, newobj:Sha1Digest[exp:IDigest](Sha1Digest::.ctor))) } 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.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: 0x0600A07D RID: 41085 RVA: 0x002146B0 File Offset: 0x002128B0 [Token(Token = "0x600A07D")] [Address(RVA = "0x5102F0", Offset = "0x50F2F0", VA = "0x1805102F0")] public static string GetAlgorithmName(DerObjectIdentifier oid) { IDictionary dictionary = CipherUtilities.algorithms; throw new NullReferenceException(); } // Token: 0x0600A07E RID: 41086 RVA: 0x002146C8 File Offset: 0x002128C8 [Token(Token = "0x600A07E")] [Address(RVA = "0x511DF0", Offset = "0x510DF0", VA = "0x180511DF0")] private static int GetDigitIndex(string s) { int num = 0; if (num < s.m_stringLength) { if (!char.IsDigit(s[num])) { num++; } return num; } return -1; } // Token: 0x0600A07F RID: 41087 RVA: 0x002146FC File Offset: 0x002128FC [Token(Token = "0x600A07F")] [Address(RVA = "0x50FE30", Offset = "0x50EE30", VA = "0x18050FE30")] private static IBlockCipher CreateBlockCipher(CipherUtilities.CipherAlgorithm cipherAlgorithm) { /* An exception occurred when decompiling this method (0600A07F) ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IBlockCipher BestHTTP.SecureProtocol.Org.BouncyCastle.Security.CipherUtilities::CreateBlockCipher(BestHTTP.SecureProtocol.Org.BouncyCastle.Security.CipherUtilities/CipherAlgorithm) ---> System.Exception: Basic block has to end with unconditional control flow. { IL_C3: stloc:string(var_30_D3, call:string(string::Concat, ldstr:string[exp:object]("Cipher "), ldloc:CipherAlgorithm[exp:object](cipherAlgorithm), ldstr:string[exp:object](" not recognised or not a block cipher"))) stloc:SecurityUtilityException(var_31_DC, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldloc:string(var_30_D3))) stloc:SecurityUtilityException(var_31_E3, add:SecurityUtilityException(ldloc:SecurityUtilityException(var_31_DC), ldloc:string[exp:SecurityUtilityException](var_30_D3))) stloc:SecurityUtilityException(var_31_EA, add:SecurityUtilityException(ldloc:SecurityUtilityException(var_31_E3), ldloc:SecurityUtilityException(var_31_E3))) } 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.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: 0x04006B11 RID: 27409 [Token(Token = "0x4006B11")] private static readonly IDictionary algorithms; // Token: 0x04006B12 RID: 27410 [Token(Token = "0x4006B12")] private static readonly IDictionary oids; // Token: 0x02001A82 RID: 6786 [Token(Token = "0x2001A82")] private enum CipherAlgorithm { // Token: 0x04006B14 RID: 27412 [Token(Token = "0x4006B14")] AES, // Token: 0x04006B15 RID: 27413 [Token(Token = "0x4006B15")] ARC4, // Token: 0x04006B16 RID: 27414 [Token(Token = "0x4006B16")] BLOWFISH, // Token: 0x04006B17 RID: 27415 [Token(Token = "0x4006B17")] CAMELLIA, // Token: 0x04006B18 RID: 27416 [Token(Token = "0x4006B18")] CAST5, // Token: 0x04006B19 RID: 27417 [Token(Token = "0x4006B19")] CAST6, // Token: 0x04006B1A RID: 27418 [Token(Token = "0x4006B1A")] DES, // Token: 0x04006B1B RID: 27419 [Token(Token = "0x4006B1B")] DESEDE, // Token: 0x04006B1C RID: 27420 [Token(Token = "0x4006B1C")] ELGAMAL, // Token: 0x04006B1D RID: 27421 [Token(Token = "0x4006B1D")] GOST28147, // Token: 0x04006B1E RID: 27422 [Token(Token = "0x4006B1E")] HC128, // Token: 0x04006B1F RID: 27423 [Token(Token = "0x4006B1F")] HC256, // Token: 0x04006B20 RID: 27424 [Token(Token = "0x4006B20")] IDEA, // Token: 0x04006B21 RID: 27425 [Token(Token = "0x4006B21")] NOEKEON, // Token: 0x04006B22 RID: 27426 [Token(Token = "0x4006B22")] PBEWITHSHAAND128BITRC4, // Token: 0x04006B23 RID: 27427 [Token(Token = "0x4006B23")] PBEWITHSHAAND40BITRC4, // Token: 0x04006B24 RID: 27428 [Token(Token = "0x4006B24")] RC2, // Token: 0x04006B25 RID: 27429 [Token(Token = "0x4006B25")] RC5, // Token: 0x04006B26 RID: 27430 [Token(Token = "0x4006B26")] RC5_64, // Token: 0x04006B27 RID: 27431 [Token(Token = "0x4006B27")] RC6, // Token: 0x04006B28 RID: 27432 [Token(Token = "0x4006B28")] RIJNDAEL, // Token: 0x04006B29 RID: 27433 [Token(Token = "0x4006B29")] RSA, // Token: 0x04006B2A RID: 27434 [Token(Token = "0x4006B2A")] SALSA20, // Token: 0x04006B2B RID: 27435 [Token(Token = "0x4006B2B")] SEED, // Token: 0x04006B2C RID: 27436 [Token(Token = "0x4006B2C")] SERPENT, // Token: 0x04006B2D RID: 27437 [Token(Token = "0x4006B2D")] SKIPJACK, // Token: 0x04006B2E RID: 27438 [Token(Token = "0x4006B2E")] SM4, // Token: 0x04006B2F RID: 27439 [Token(Token = "0x4006B2F")] TEA, // Token: 0x04006B30 RID: 27440 [Token(Token = "0x4006B30")] THREEFISH_256, // Token: 0x04006B31 RID: 27441 [Token(Token = "0x4006B31")] THREEFISH_512, // Token: 0x04006B32 RID: 27442 [Token(Token = "0x4006B32")] THREEFISH_1024, // Token: 0x04006B33 RID: 27443 [Token(Token = "0x4006B33")] TNEPRES, // Token: 0x04006B34 RID: 27444 [Token(Token = "0x4006B34")] TWOFISH, // Token: 0x04006B35 RID: 27445 [Token(Token = "0x4006B35")] VMPC, // Token: 0x04006B36 RID: 27446 [Token(Token = "0x4006B36")] VMPC_KSA3, // Token: 0x04006B37 RID: 27447 [Token(Token = "0x4006B37")] XTEA } // Token: 0x02001A83 RID: 6787 [Token(Token = "0x2001A83")] private enum CipherMode { // Token: 0x04006B39 RID: 27449 [Token(Token = "0x4006B39")] ECB, // Token: 0x04006B3A RID: 27450 [Token(Token = "0x4006B3A")] NONE, // Token: 0x04006B3B RID: 27451 [Token(Token = "0x4006B3B")] CBC, // Token: 0x04006B3C RID: 27452 [Token(Token = "0x4006B3C")] CCM, // Token: 0x04006B3D RID: 27453 [Token(Token = "0x4006B3D")] CFB, // Token: 0x04006B3E RID: 27454 [Token(Token = "0x4006B3E")] CTR, // Token: 0x04006B3F RID: 27455 [Token(Token = "0x4006B3F")] CTS, // Token: 0x04006B40 RID: 27456 [Token(Token = "0x4006B40")] EAX, // Token: 0x04006B41 RID: 27457 [Token(Token = "0x4006B41")] GCM, // Token: 0x04006B42 RID: 27458 [Token(Token = "0x4006B42")] GOFB, // Token: 0x04006B43 RID: 27459 [Token(Token = "0x4006B43")] OCB, // Token: 0x04006B44 RID: 27460 [Token(Token = "0x4006B44")] OFB, // Token: 0x04006B45 RID: 27461 [Token(Token = "0x4006B45")] OPENPGPCFB, // Token: 0x04006B46 RID: 27462 [Token(Token = "0x4006B46")] SIC } // Token: 0x02001A84 RID: 6788 [Token(Token = "0x2001A84")] private enum CipherPadding { // Token: 0x04006B48 RID: 27464 [Token(Token = "0x4006B48")] NOPADDING, // Token: 0x04006B49 RID: 27465 [Token(Token = "0x4006B49")] RAW, // Token: 0x04006B4A RID: 27466 [Token(Token = "0x4006B4A")] ISO10126PADDING, // Token: 0x04006B4B RID: 27467 [Token(Token = "0x4006B4B")] ISO10126D2PADDING, // Token: 0x04006B4C RID: 27468 [Token(Token = "0x4006B4C")] ISO10126_2PADDING, // Token: 0x04006B4D RID: 27469 [Token(Token = "0x4006B4D")] ISO7816_4PADDING, // Token: 0x04006B4E RID: 27470 [Token(Token = "0x4006B4E")] ISO9797_1PADDING, // Token: 0x04006B4F RID: 27471 [Token(Token = "0x4006B4F")] ISO9796_1, // Token: 0x04006B50 RID: 27472 [Token(Token = "0x4006B50")] ISO9796_1PADDING, // Token: 0x04006B51 RID: 27473 [Token(Token = "0x4006B51")] OAEP, // Token: 0x04006B52 RID: 27474 [Token(Token = "0x4006B52")] OAEPPADDING, // Token: 0x04006B53 RID: 27475 [Token(Token = "0x4006B53")] OAEPWITHMD5ANDMGF1PADDING, // Token: 0x04006B54 RID: 27476 [Token(Token = "0x4006B54")] OAEPWITHSHA1ANDMGF1PADDING, // Token: 0x04006B55 RID: 27477 [Token(Token = "0x4006B55")] OAEPWITHSHA_1ANDMGF1PADDING, // Token: 0x04006B56 RID: 27478 [Token(Token = "0x4006B56")] OAEPWITHSHA224ANDMGF1PADDING, // Token: 0x04006B57 RID: 27479 [Token(Token = "0x4006B57")] OAEPWITHSHA_224ANDMGF1PADDING, // Token: 0x04006B58 RID: 27480 [Token(Token = "0x4006B58")] OAEPWITHSHA256ANDMGF1PADDING, // Token: 0x04006B59 RID: 27481 [Token(Token = "0x4006B59")] OAEPWITHSHA_256ANDMGF1PADDING, // Token: 0x04006B5A RID: 27482 [Token(Token = "0x4006B5A")] OAEPWITHSHA384ANDMGF1PADDING, // Token: 0x04006B5B RID: 27483 [Token(Token = "0x4006B5B")] OAEPWITHSHA_384ANDMGF1PADDING, // Token: 0x04006B5C RID: 27484 [Token(Token = "0x4006B5C")] OAEPWITHSHA512ANDMGF1PADDING, // Token: 0x04006B5D RID: 27485 [Token(Token = "0x4006B5D")] OAEPWITHSHA_512ANDMGF1PADDING, // Token: 0x04006B5E RID: 27486 [Token(Token = "0x4006B5E")] PKCS1, // Token: 0x04006B5F RID: 27487 [Token(Token = "0x4006B5F")] PKCS1PADDING, // Token: 0x04006B60 RID: 27488 [Token(Token = "0x4006B60")] PKCS5, // Token: 0x04006B61 RID: 27489 [Token(Token = "0x4006B61")] PKCS5PADDING, // Token: 0x04006B62 RID: 27490 [Token(Token = "0x4006B62")] PKCS7, // Token: 0x04006B63 RID: 27491 [Token(Token = "0x4006B63")] PKCS7PADDING, // Token: 0x04006B64 RID: 27492 [Token(Token = "0x4006B64")] TBCPADDING, // Token: 0x04006B65 RID: 27493 [Token(Token = "0x4006B65")] WITHCTS, // Token: 0x04006B66 RID: 27494 [Token(Token = "0x4006B66")] X923PADDING, // Token: 0x04006B67 RID: 27495 [Token(Token = "0x4006B67")] ZEROBYTEPADDING } } }