This commit is contained in:
niko
2026-04-12 16:51:38 +02:00
parent 1b6f6d81d0
commit c12fbe3fc6
17828 changed files with 2994770 additions and 0 deletions
@@ -0,0 +1,242 @@
using System;
using System.Collections;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.EdEC;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X9;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A80 RID: 6784
[Token(Token = "0x2001A80")]
public sealed class AgreementUtilities
{
// Token: 0x0600A06D RID: 41069 RVA: 0x00213AA8 File Offset: 0x00211CA8
[Token(Token = "0x600A06D")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private AgreementUtilities()
{
}
// Token: 0x0600A06E RID: 41070 RVA: 0x00213ABC File Offset: 0x00211CBC
[Token(Token = "0x600A06E")]
[Address(RVA = "0x50FA80", Offset = "0x50EA80", VA = "0x18050FA80")]
static AgreementUtilities()
{
IDictionary dictionary = Platform.CreateHashtable();
DerObjectIdentifier dhsinglePassCofactorDHSha1KdfScheme = X9ObjectIdentifiers.DHSinglePassCofactorDHSha1KdfScheme;
DerObjectIdentifier dhsinglePassStdDHSha1KdfScheme = X9ObjectIdentifiers.DHSinglePassStdDHSha1KdfScheme;
DerObjectIdentifier mqvSinglePassSha1KdfScheme = X9ObjectIdentifiers.MqvSinglePassSha1KdfScheme;
DerObjectIdentifier id_X = EdECObjectIdentifiers.id_X25519;
DerObjectIdentifier id_X2 = EdECObjectIdentifiers.id_X448;
}
// Token: 0x0600A06F RID: 41071 RVA: 0x00213AFC File Offset: 0x00211CFC
[Token(Token = "0x600A06F")]
[Address(RVA = "0x50F330", Offset = "0x50E330", VA = "0x18050F330")]
public static IBasicAgreement GetBasicAgreement(DerObjectIdentifier oid)
{
/*
An exception occurred when decompiling this method (0600A06F)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IBasicAgreement BestHTTP.SecureProtocol.Org.BouncyCastle.Security.AgreementUtilities::GetBasicAgreement(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.DerObjectIdentifier)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_7F:
stloc:SecurityUtilityException(var_6_86, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldloc:string(var_5)))
}
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.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.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.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: 0x0600A070 RID: 41072 RVA: 0x00213B90 File Offset: 0x00211D90
[Token(Token = "0x600A070")]
[Address(RVA = "0x50F550", Offset = "0x50E550", VA = "0x18050F550")]
public static IBasicAgreement GetBasicAgreement(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A070)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IBasicAgreement BestHTTP.SecureProtocol.Org.BouncyCastle.Security.AgreementUtilities::GetBasicAgreement(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_74:
stloc:SecurityUtilityException(var_5_89, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, call:string(string::Concat, ldstr:string("Basic Agreement "), ldloc:string(algorithm), ldstr:string(" not recognised."))))
}
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: 0x0600A071 RID: 41073 RVA: 0x00213C28 File Offset: 0x00211E28
[Token(Token = "0x600A071")]
[Address(RVA = "0x50EF40", Offset = "0x50DF40", VA = "0x18050EF40")]
public static IBasicAgreement GetBasicAgreementWithKdf(DerObjectIdentifier oid, string wrapAlgorithm)
{
/*
An exception occurred when decompiling this method (0600A071)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IBasicAgreement BestHTTP.SecureProtocol.Org.BouncyCastle.Security.AgreementUtilities::GetBasicAgreementWithKdf(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.DerObjectIdentifier,System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_63:
stloc:SecurityUtilityException(var_6_6A, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldloc:string(var_5)))
}
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.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: 0x0600A072 RID: 41074 RVA: 0x00213CA0 File Offset: 0x00211EA0
[Token(Token = "0x600A072")]
[Address(RVA = "0x50F160", Offset = "0x50E160", VA = "0x18050F160")]
public static IBasicAgreement GetBasicAgreementWithKdf(string agreeAlgorithm, string wrapAlgorithm)
{
/*
An exception occurred when decompiling this method (0600A072)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IBasicAgreement BestHTTP.SecureProtocol.Org.BouncyCastle.Security.AgreementUtilities::GetBasicAgreementWithKdf(System.String,System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_58:
stloc:SecurityUtilityException(var_6_5F, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldloc:string(var_5)))
}
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: 0x0600A073 RID: 41075 RVA: 0x00213D10 File Offset: 0x00211F10
[Token(Token = "0x600A073")]
[Address(RVA = "0x50F7F0", Offset = "0x50E7F0", VA = "0x18050F7F0")]
public static IRawAgreement GetRawAgreement(DerObjectIdentifier oid)
{
/*
An exception occurred when decompiling this method (0600A073)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IRawAgreement BestHTTP.SecureProtocol.Org.BouncyCastle.Security.AgreementUtilities::GetRawAgreement(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.DerObjectIdentifier)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_3A:
stloc:SecurityUtilityException(var_4_40, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldloc:string(var_3)))
}
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.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: 0x0600A074 RID: 41076 RVA: 0x00213D60 File Offset: 0x00211F60
[Token(Token = "0x600A074")]
[Address(RVA = "0x50F960", Offset = "0x50E960", VA = "0x18050F960")]
public static IRawAgreement GetRawAgreement(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A074)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IRawAgreement BestHTTP.SecureProtocol.Org.BouncyCastle.Security.AgreementUtilities::GetRawAgreement(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_2F:
stloc:SecurityUtilityException(var_3_44, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, call:string(string::Concat, ldstr:string("Raw Agreement "), ldloc:string(algorithm), ldstr:string(" not recognised."))))
}
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: 0x0600A075 RID: 41077 RVA: 0x00213DB4 File Offset: 0x00211FB4
[Token(Token = "0x600A075")]
[Address(RVA = "0x50EE90", Offset = "0x50DE90", VA = "0x18050EE90")]
public static string GetAlgorithmName(DerObjectIdentifier oid)
{
throw new NullReferenceException();
}
// Token: 0x0600A076 RID: 41078 RVA: 0x00213DC8 File Offset: 0x00211FC8
[Token(Token = "0x600A076")]
[Address(RVA = "0x50F720", Offset = "0x50E720", VA = "0x18050F720")]
private static string GetMechanism(string algorithm)
{
string text;
do
{
text = Platform.ToUpperInvariant(algorithm);
}
while (text != 0 && text == 0);
return text;
}
// Token: 0x04006B10 RID: 27408
[Token(Token = "0x4006B10")]
private static readonly IDictionary algorithms;
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security.Certificates
{
// Token: 0x02001A9A RID: 6810
[Token(Token = "0x2001A9A")]
[Serializable]
public class CertificateEncodingException : CertificateException
{
// Token: 0x0600A135 RID: 41269 RVA: 0x002193EC File Offset: 0x002175EC
[Token(Token = "0x600A135")]
[Address(RVA = "0x50FCE0", Offset = "0x50ECE0", VA = "0x18050FCE0")]
public CertificateEncodingException()
{
}
// Token: 0x0600A136 RID: 41270 RVA: 0x00219400 File Offset: 0x00217600
[Token(Token = "0x600A136")]
[Address(RVA = "0x50FDC0", Offset = "0x50EDC0", VA = "0x18050FDC0")]
public CertificateEncodingException(string msg)
: base(msg)
{
}
// Token: 0x0600A137 RID: 41271 RVA: 0x00219414 File Offset: 0x00217614
[Token(Token = "0x600A137")]
[Address(RVA = "0x50FD40", Offset = "0x50ED40", VA = "0x18050FD40")]
public CertificateEncodingException(string msg, Exception e)
: base(msg, e)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security.Certificates
{
// Token: 0x02001A9B RID: 6811
[Token(Token = "0x2001A9B")]
[Serializable]
public class CertificateException : GeneralSecurityException
{
// Token: 0x0600A138 RID: 41272 RVA: 0x0021942C File Offset: 0x0021762C
[Token(Token = "0x600A138")]
[Address(RVA = "0x50FCE0", Offset = "0x50ECE0", VA = "0x18050FCE0")]
public CertificateException()
{
}
// Token: 0x0600A139 RID: 41273 RVA: 0x00219440 File Offset: 0x00217640
[Token(Token = "0x600A139")]
[Address(RVA = "0x50FDC0", Offset = "0x50EDC0", VA = "0x18050FDC0")]
public CertificateException(string message)
: base(message)
{
}
// Token: 0x0600A13A RID: 41274 RVA: 0x00219454 File Offset: 0x00217654
[Token(Token = "0x600A13A")]
[Address(RVA = "0x50FD40", Offset = "0x50ED40", VA = "0x18050FD40")]
public CertificateException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security.Certificates
{
// Token: 0x02001A9C RID: 6812
[Token(Token = "0x2001A9C")]
[Serializable]
public class CertificateExpiredException : CertificateException
{
// Token: 0x0600A13B RID: 41275 RVA: 0x0021946C File Offset: 0x0021766C
[Token(Token = "0x600A13B")]
[Address(RVA = "0x50FCE0", Offset = "0x50ECE0", VA = "0x18050FCE0")]
public CertificateExpiredException()
{
}
// Token: 0x0600A13C RID: 41276 RVA: 0x00219480 File Offset: 0x00217680
[Token(Token = "0x600A13C")]
[Address(RVA = "0x50FDC0", Offset = "0x50EDC0", VA = "0x18050FDC0")]
public CertificateExpiredException(string message)
: base(message)
{
}
// Token: 0x0600A13D RID: 41277 RVA: 0x00219494 File Offset: 0x00217694
[Token(Token = "0x600A13D")]
[Address(RVA = "0x50FD40", Offset = "0x50ED40", VA = "0x18050FD40")]
public CertificateExpiredException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security.Certificates
{
// Token: 0x02001A9D RID: 6813
[Token(Token = "0x2001A9D")]
[Serializable]
public class CertificateNotYetValidException : CertificateException
{
// Token: 0x0600A13E RID: 41278 RVA: 0x002194AC File Offset: 0x002176AC
[Token(Token = "0x600A13E")]
[Address(RVA = "0x50FCE0", Offset = "0x50ECE0", VA = "0x18050FCE0")]
public CertificateNotYetValidException()
{
}
// Token: 0x0600A13F RID: 41279 RVA: 0x002194C0 File Offset: 0x002176C0
[Token(Token = "0x600A13F")]
[Address(RVA = "0x50FDC0", Offset = "0x50EDC0", VA = "0x18050FDC0")]
public CertificateNotYetValidException(string message)
: base(message)
{
}
// Token: 0x0600A140 RID: 41280 RVA: 0x002194D4 File Offset: 0x002176D4
[Token(Token = "0x600A140")]
[Address(RVA = "0x50FD40", Offset = "0x50ED40", VA = "0x18050FD40")]
public CertificateNotYetValidException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security.Certificates
{
// Token: 0x02001A9E RID: 6814
[Token(Token = "0x2001A9E")]
[Serializable]
public class CertificateParsingException : CertificateException
{
// Token: 0x0600A141 RID: 41281 RVA: 0x002194EC File Offset: 0x002176EC
[Token(Token = "0x600A141")]
[Address(RVA = "0x50FCE0", Offset = "0x50ECE0", VA = "0x18050FCE0")]
public CertificateParsingException()
{
}
// Token: 0x0600A142 RID: 41282 RVA: 0x00219500 File Offset: 0x00217700
[Token(Token = "0x600A142")]
[Address(RVA = "0x50FDC0", Offset = "0x50EDC0", VA = "0x18050FDC0")]
public CertificateParsingException(string message)
: base(message)
{
}
// Token: 0x0600A143 RID: 41283 RVA: 0x00219514 File Offset: 0x00217714
[Token(Token = "0x600A143")]
[Address(RVA = "0x50FD40", Offset = "0x50ED40", VA = "0x18050FD40")]
public CertificateParsingException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security.Certificates
{
// Token: 0x02001A9F RID: 6815
[Token(Token = "0x2001A9F")]
[Serializable]
public class CrlException : GeneralSecurityException
{
// Token: 0x0600A144 RID: 41284 RVA: 0x0021952C File Offset: 0x0021772C
[Token(Token = "0x600A144")]
[Address(RVA = "0x50FCE0", Offset = "0x50ECE0", VA = "0x18050FCE0")]
public CrlException()
{
}
// Token: 0x0600A145 RID: 41285 RVA: 0x00219540 File Offset: 0x00217740
[Token(Token = "0x600A145")]
[Address(RVA = "0x50FDC0", Offset = "0x50EDC0", VA = "0x18050FDC0")]
public CrlException(string msg)
: base(msg)
{
}
// Token: 0x0600A146 RID: 41286 RVA: 0x00219554 File Offset: 0x00217754
[Token(Token = "0x600A146")]
[Address(RVA = "0x50FD40", Offset = "0x50ED40", VA = "0x18050FD40")]
public CrlException(string msg, Exception e)
: base(msg, e)
{
}
}
}
@@ -0,0 +1,539 @@
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
}
}
}
@@ -0,0 +1,404 @@
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: 0x02001A85 RID: 6789
[Token(Token = "0x2001A85")]
public sealed class DigestUtilities
{
// Token: 0x0600A080 RID: 41088 RVA: 0x002147F4 File Offset: 0x002129F4
[Token(Token = "0x600A080")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private DigestUtilities()
{
}
// Token: 0x0600A081 RID: 41089 RVA: 0x00214808 File Offset: 0x00212A08
[Token(Token = "0x600A081")]
[Address(RVA = "0x514560", Offset = "0x513560", VA = "0x180514560")]
static DigestUtilities()
{
/*
An exception occurred when decompiling this method (0600A081)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Security.DigestUtilities::.cctor()
---> System.Exception: Basic block has to end with unconditional control flow.
{
Block_0:
stloc:IDictionary(var_2_07, call:IDictionary(Platform::CreateHashtable))
stsfld:IDictionary(DigestUtilities::algorithms, ldloc:IDictionary(var_2_07))
stsfld:IDictionary(DigestUtilities::oids, call:IDictionary(Platform::CreateHashtable))
stloc:Enum(var_4_29, call:Enum(Enums::GetArbitraryValue, call:Type(Type::GetTypeFromHandle, ldtoken:RuntimeTypeHandle(BestHTTP.SecureProtocol.Org.BouncyCastle.Security.DigestUtilities/DigestAlgorithm))))
stloc:IDictionary(var_8_3C, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_9_43, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD2))
stloc:IDictionary(var_11_4A, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_12_51, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD4))
stloc:IDictionary(var_14_58, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_15_5F, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD5))
stloc:IDictionary(var_17_66, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_19_6D, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_20_74, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::IdSha1))
stloc:IDictionary(var_22_7B, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_24_82, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_25_89, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha224))
stloc:IDictionary(var_27_90, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_29_97, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_30_9E, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha256))
stloc:IDictionary(var_32_A5, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_34_AC, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_35_B3, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha384))
stloc:IDictionary(var_37_BA, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_39_C1, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_40_C8, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha512))
stloc:IDictionary(var_42_CF, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_44_D6, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_45_DD, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha512_224))
stloc:IDictionary(var_47_E4, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_49_EB, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_50_F2, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha512_256))
stloc:IDictionary(var_52_F9, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_54_100, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_55_107, ldsfld:DerObjectIdentifier(TeleTrusTObjectIdentifiers::RipeMD128))
stloc:IDictionary(var_57_10E, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_59_115, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_60_11C, ldsfld:DerObjectIdentifier(TeleTrusTObjectIdentifiers::RipeMD160))
stloc:IDictionary(var_62_123, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_64_12A, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_65_131, ldsfld:DerObjectIdentifier(TeleTrusTObjectIdentifiers::RipeMD256))
stloc:IDictionary(var_67_138, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_69_13F, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_70_146, ldsfld:DerObjectIdentifier(CryptoProObjectIdentifiers::GostR3411))
stloc:IDictionary(var_72_14D, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_74_154, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_76_15B, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_78_162, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_80_169, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:IDictionary(var_82_170, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_83_177, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha3_224))
stloc:IDictionary(var_85_17E, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_86_185, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha3_256))
stloc:IDictionary(var_88_18C, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_89_193, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha3_384))
stloc:IDictionary(var_91_19A, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_92_1A1, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha3_512))
stloc:IDictionary(var_94_1A8, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_95_1AF, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdShake128))
stloc:IDictionary(var_97_1B6, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_98_1BD, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdShake256))
stloc:IDictionary(var_100_1C4, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_101_1CB, ldsfld:DerObjectIdentifier(GMObjectIdentifiers::sm3))
stloc:IDictionary(var_103_1D2, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_104_1D9, ldsfld:DerObjectIdentifier(MiscObjectIdentifiers::id_blake2b160))
stloc:IDictionary(var_106_1E0, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_107_1E7, ldsfld:DerObjectIdentifier(MiscObjectIdentifiers::id_blake2b256))
stloc:IDictionary(var_109_1EE, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_110_1F5, ldsfld:DerObjectIdentifier(MiscObjectIdentifiers::id_blake2b384))
stloc:IDictionary(var_112_1FC, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_113_203, ldsfld:DerObjectIdentifier(MiscObjectIdentifiers::id_blake2b512))
stloc:IDictionary(var_115_20A, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_116_211, ldsfld:DerObjectIdentifier(MiscObjectIdentifiers::id_blake2s128))
stloc:IDictionary(var_118_218, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_119_21F, ldsfld:DerObjectIdentifier(MiscObjectIdentifiers::id_blake2s160))
stloc:IDictionary(var_121_226, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_122_22D, ldsfld:DerObjectIdentifier(MiscObjectIdentifiers::id_blake2s224))
stloc:IDictionary(var_124_234, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_125_23B, ldsfld:DerObjectIdentifier(MiscObjectIdentifiers::id_blake2s256))
stloc:IDictionary(var_127_242, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_128_249, ldsfld:DerObjectIdentifier(RosstandartObjectIdentifiers::id_tc26_gost_3411_12_256))
stloc:IDictionary(var_130_250, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_131_257, ldsfld:DerObjectIdentifier(RosstandartObjectIdentifiers::id_tc26_gost_3411_12_512))
stloc:IDictionary(var_133_25E, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_134_265, ldsfld:DerObjectIdentifier(UAObjectIdentifiers::dstu7564digest_256))
stloc:IDictionary(var_136_26C, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_137_273, ldsfld:DerObjectIdentifier(UAObjectIdentifiers::dstu7564digest_384))
stloc:IDictionary(var_139_27A, ldsfld:IDictionary(DigestUtilities::algorithms))
stloc:DerObjectIdentifier(var_140_281, ldsfld:DerObjectIdentifier(UAObjectIdentifiers::dstu7564digest_512))
stloc:IDictionary(var_142_288, ldsfld:IDictionary(DigestUtilities::oids))
stloc:DerObjectIdentifier(var_143_28F, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD2))
stloc:IDictionary(var_144_296, ldsfld:IDictionary(DigestUtilities::oids))
stloc:DerObjectIdentifier(var_145_29D, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD4))
stloc:IDictionary(var_146_2A4, ldsfld:IDictionary(DigestUtilities::oids))
stloc:DerObjectIdentifier(var_147_2AB, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD5))
stloc:IDictionary(var_148_2B2, ldsfld:IDictionary(DigestUtilities::oids))
stloc:DerObjectIdentifier(var_149_2B9, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::IdSha1))
stloc:IDictionary(var_150_2C0, ldsfld:IDictionary(DigestUtilities::oids))
stloc:DerObjectIdentifier(var_151_2C7, ldsfld:DerObjectIdentifier(NistObjectIdentifiers::IdSha224))
stloc:IDictionary(var_152_2CE, ldsfld:IDictionary(DigestUtilities::oids))
}
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: 0x0600A082 RID: 41090 RVA: 0x00214AE4 File Offset: 0x00212CE4
[Token(Token = "0x600A082")]
[Address(RVA = "0x5143B0", Offset = "0x5133B0", VA = "0x1805143B0")]
public static DerObjectIdentifier GetObjectIdentifier(string mechanism)
{
/*
An exception occurred when decompiling this method (0600A082)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.DerObjectIdentifier BestHTTP.SecureProtocol.Org.BouncyCastle.Security.DigestUtilities::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: 0x170019A2 RID: 6562
// (get) Token: 0x0600A083 RID: 41091 RVA: 0x00214B2C File Offset: 0x00212D2C
[Token(Token = "0x170019A2")]
public static ICollection Algorithms
{
[Token(Token = "0x600A083")]
[Address(RVA = "0x516140", Offset = "0x515140", VA = "0x180516140")]
get
{
IDictionary dictionary = DigestUtilities.oids;
throw new NullReferenceException();
}
}
// Token: 0x0600A084 RID: 41092 RVA: 0x00214B44 File Offset: 0x00212D44
[Token(Token = "0x600A084")]
[Address(RVA = "0x513B00", Offset = "0x512B00", VA = "0x180513B00")]
public static IDigest GetDigest(DerObjectIdentifier id)
{
return DigestUtilities.GetDigest(id.identifier);
}
// Token: 0x0600A085 RID: 41093 RVA: 0x00214B64 File Offset: 0x00212D64
[Token(Token = "0x600A085")]
[Address(RVA = "0x513B60", Offset = "0x512B60", VA = "0x180513B60")]
public static IDigest GetDigest(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A085)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IDigest BestHTTP.SecureProtocol.Org.BouncyCastle.Security.DigestUtilities::GetDigest(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_18D:
stloc:SecurityUtilityException(var_69_1A2, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, call:string(string::Concat, ldstr:string("Digest "), ldloc:string(var_0_06), ldstr:string(" not recognised."))))
}
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: 0x0600A086 RID: 41094 RVA: 0x00214D14 File Offset: 0x00212F14
[Token(Token = "0x600A086")]
[Address(RVA = "0x513A50", Offset = "0x512A50", VA = "0x180513A50")]
public static string GetAlgorithmName(DerObjectIdentifier oid)
{
IDictionary dictionary = DigestUtilities.algorithms;
throw new NullReferenceException();
}
// Token: 0x0600A087 RID: 41095 RVA: 0x00214D2C File Offset: 0x00212F2C
[Token(Token = "0x600A087")]
[Address(RVA = "0x513820", Offset = "0x512820", VA = "0x180513820")]
public static byte[] CalculateDigest(string algorithm, byte[] input)
{
IDigest digest = DigestUtilities.GetDigest(algorithm);
int length = input.Length;
return DigestUtilities.DoFinal(digest);
}
// Token: 0x0600A088 RID: 41096 RVA: 0x00214D54 File Offset: 0x00212F54
[Token(Token = "0x600A088")]
[Address(RVA = "0x513960", Offset = "0x512960", VA = "0x180513960")]
public static byte[] DoFinal(IDigest digest)
{
byte[] array = new byte[0];
int num = 0;
num += num;
num++;
return array;
}
// Token: 0x0600A089 RID: 41097 RVA: 0x00214D80 File Offset: 0x00212F80
[Token(Token = "0x600A089")]
[Address(RVA = "0x5138C0", Offset = "0x5128C0", VA = "0x1805138C0")]
public static byte[] DoFinal(IDigest digest, byte[] input)
{
int length = input.Length;
return DigestUtilities.DoFinal(digest);
}
// Token: 0x04006B68 RID: 27496
[Token(Token = "0x4006B68")]
private static readonly IDictionary algorithms;
// Token: 0x04006B69 RID: 27497
[Token(Token = "0x4006B69")]
private static readonly IDictionary oids;
// Token: 0x02001A86 RID: 6790
[Token(Token = "0x2001A86")]
private enum DigestAlgorithm
{
// Token: 0x04006B6B RID: 27499
[Token(Token = "0x4006B6B")]
BLAKE2B_160,
// Token: 0x04006B6C RID: 27500
[Token(Token = "0x4006B6C")]
BLAKE2B_256,
// Token: 0x04006B6D RID: 27501
[Token(Token = "0x4006B6D")]
BLAKE2B_384,
// Token: 0x04006B6E RID: 27502
[Token(Token = "0x4006B6E")]
BLAKE2B_512,
// Token: 0x04006B6F RID: 27503
[Token(Token = "0x4006B6F")]
BLAKE2S_128,
// Token: 0x04006B70 RID: 27504
[Token(Token = "0x4006B70")]
BLAKE2S_160,
// Token: 0x04006B71 RID: 27505
[Token(Token = "0x4006B71")]
BLAKE2S_224,
// Token: 0x04006B72 RID: 27506
[Token(Token = "0x4006B72")]
BLAKE2S_256,
// Token: 0x04006B73 RID: 27507
[Token(Token = "0x4006B73")]
DSTU7564_256,
// Token: 0x04006B74 RID: 27508
[Token(Token = "0x4006B74")]
DSTU7564_384,
// Token: 0x04006B75 RID: 27509
[Token(Token = "0x4006B75")]
DSTU7564_512,
// Token: 0x04006B76 RID: 27510
[Token(Token = "0x4006B76")]
GOST3411,
// Token: 0x04006B77 RID: 27511
[Token(Token = "0x4006B77")]
GOST3411_2012_256,
// Token: 0x04006B78 RID: 27512
[Token(Token = "0x4006B78")]
GOST3411_2012_512,
// Token: 0x04006B79 RID: 27513
[Token(Token = "0x4006B79")]
KECCAK_224,
// Token: 0x04006B7A RID: 27514
[Token(Token = "0x4006B7A")]
KECCAK_256,
// Token: 0x04006B7B RID: 27515
[Token(Token = "0x4006B7B")]
KECCAK_288,
// Token: 0x04006B7C RID: 27516
[Token(Token = "0x4006B7C")]
KECCAK_384,
// Token: 0x04006B7D RID: 27517
[Token(Token = "0x4006B7D")]
KECCAK_512,
// Token: 0x04006B7E RID: 27518
[Token(Token = "0x4006B7E")]
MD2,
// Token: 0x04006B7F RID: 27519
[Token(Token = "0x4006B7F")]
MD4,
// Token: 0x04006B80 RID: 27520
[Token(Token = "0x4006B80")]
MD5,
// Token: 0x04006B81 RID: 27521
[Token(Token = "0x4006B81")]
NONE,
// Token: 0x04006B82 RID: 27522
[Token(Token = "0x4006B82")]
RIPEMD128,
// Token: 0x04006B83 RID: 27523
[Token(Token = "0x4006B83")]
RIPEMD160,
// Token: 0x04006B84 RID: 27524
[Token(Token = "0x4006B84")]
RIPEMD256,
// Token: 0x04006B85 RID: 27525
[Token(Token = "0x4006B85")]
RIPEMD320,
// Token: 0x04006B86 RID: 27526
[Token(Token = "0x4006B86")]
SHA_1,
// Token: 0x04006B87 RID: 27527
[Token(Token = "0x4006B87")]
SHA_224,
// Token: 0x04006B88 RID: 27528
[Token(Token = "0x4006B88")]
SHA_256,
// Token: 0x04006B89 RID: 27529
[Token(Token = "0x4006B89")]
SHA_384,
// Token: 0x04006B8A RID: 27530
[Token(Token = "0x4006B8A")]
SHA_512,
// Token: 0x04006B8B RID: 27531
[Token(Token = "0x4006B8B")]
SHA_512_224,
// Token: 0x04006B8C RID: 27532
[Token(Token = "0x4006B8C")]
SHA_512_256,
// Token: 0x04006B8D RID: 27533
[Token(Token = "0x4006B8D")]
SHA3_224,
// Token: 0x04006B8E RID: 27534
[Token(Token = "0x4006B8E")]
SHA3_256,
// Token: 0x04006B8F RID: 27535
[Token(Token = "0x4006B8F")]
SHA3_384,
// Token: 0x04006B90 RID: 27536
[Token(Token = "0x4006B90")]
SHA3_512,
// Token: 0x04006B91 RID: 27537
[Token(Token = "0x4006B91")]
SHAKE128,
// Token: 0x04006B92 RID: 27538
[Token(Token = "0x4006B92")]
SHAKE256,
// Token: 0x04006B93 RID: 27539
[Token(Token = "0x4006B93")]
SM3,
// Token: 0x04006B94 RID: 27540
[Token(Token = "0x4006B94")]
TIGER,
// Token: 0x04006B95 RID: 27541
[Token(Token = "0x4006B95")]
WHIRLPOOL
}
}
}
@@ -0,0 +1,354 @@
using System;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Parameters;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Math;
using BestHTTP.SecureProtocol.Org.BouncyCastle.X509;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A87 RID: 6791
[Token(Token = "0x2001A87")]
public sealed class DotNetUtilities
{
// Token: 0x0600A08A RID: 41098 RVA: 0x00214DA0 File Offset: 0x00212FA0
[Token(Token = "0x600A08A")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private DotNetUtilities()
{
}
// Token: 0x0600A08B RID: 41099 RVA: 0x00214DB4 File Offset: 0x00212FB4
[Token(Token = "0x600A08B")]
[Address(RVA = "0x517900", Offset = "0x516900", VA = "0x180517900")]
public static global::System.Security.Cryptography.X509Certificates.X509Certificate ToX509Certificate(X509CertificateStructure x509Struct)
{
return new global::System.Security.Cryptography.X509Certificates.X509Certificate(x509Struct.GetDerEncoded());
}
// Token: 0x0600A08C RID: 41100 RVA: 0x00214DD4 File Offset: 0x00212FD4
[Token(Token = "0x600A08C")]
[Address(RVA = "0x517970", Offset = "0x516970", VA = "0x180517970")]
public static global::System.Security.Cryptography.X509Certificates.X509Certificate ToX509Certificate(BestHTTP.SecureProtocol.Org.BouncyCastle.X509.X509Certificate x509Cert)
{
AsymmetricKeyParameter publicKey = x509Cert.GetPublicKey();
global::System.Security.Cryptography.X509Certificates.X509Certificate x509Certificate;
return x509Certificate;
}
// Token: 0x0600A08D RID: 41101 RVA: 0x00214DF0 File Offset: 0x00212FF0
[Token(Token = "0x600A08D")]
[Address(RVA = "0x516480", Offset = "0x515480", VA = "0x180516480")]
public static BestHTTP.SecureProtocol.Org.BouncyCastle.X509.X509Certificate FromX509Certificate(global::System.Security.Cryptography.X509Certificates.X509Certificate x509Cert)
{
X509CertificateParser x509CertificateParser = new X509CertificateParser();
byte[] publicKey = x509Cert.GetPublicKey();
return x509CertificateParser.ReadCertificate(publicKey);
}
// Token: 0x0600A08E RID: 41102 RVA: 0x00214E18 File Offset: 0x00213018
[Token(Token = "0x600A08E")]
[Address(RVA = "0x516500", Offset = "0x515500", VA = "0x180516500")]
public static AsymmetricCipherKeyPair GetDsaKeyPair(DSA dsa)
{
AsymmetricCipherKeyPair asymmetricCipherKeyPair;
return asymmetricCipherKeyPair;
}
// Token: 0x0600A08F RID: 41103 RVA: 0x00214E2C File Offset: 0x0021302C
[Token(Token = "0x600A08F")]
[Address(RVA = "0x516570", Offset = "0x515570", VA = "0x180516570")]
public static AsymmetricCipherKeyPair GetDsaKeyPair(DSAParameters dp)
{
if (dp.Seed != (ulong)0L)
{
byte[] seed = dp.Seed;
}
int num = 0;
byte[] g;
BigInteger bigInteger = new BigInteger(1, g);
g = dp.G;
BigInteger bigInteger2;
BigInteger bigInteger3;
DsaParameters dsaParameters = new DsaParameters(bigInteger2, bigInteger3, bigInteger, num);
BigInteger bigInteger4;
DsaPublicKeyParameters dsaPublicKeyParameters = new DsaPublicKeyParameters(bigInteger4, dsaParameters);
BigInteger bigInteger5;
DsaPrivateKeyParameters dsaPrivateKeyParameters = new DsaPrivateKeyParameters(bigInteger5, dsaParameters);
return new AsymmetricCipherKeyPair(dsaPublicKeyParameters, dsaPrivateKeyParameters);
}
// Token: 0x0600A090 RID: 41104 RVA: 0x00214E8C File Offset: 0x0021308C
[Token(Token = "0x600A090")]
[Address(RVA = "0x516760", Offset = "0x515760", VA = "0x180516760")]
public static DsaPublicKeyParameters GetDsaPublicKey(DSA dsa)
{
int num = 0;
BigInteger bigInteger;
BigInteger bigInteger2;
BigInteger bigInteger3;
DsaParameters dsaParameters = new DsaParameters(bigInteger, bigInteger2, bigInteger3, num);
BigInteger bigInteger4;
return new DsaPublicKeyParameters(bigInteger4, dsaParameters);
}
// Token: 0x0600A091 RID: 41105 RVA: 0x00214EB8 File Offset: 0x002130B8
[Token(Token = "0x600A091")]
[Address(RVA = "0x516920", Offset = "0x515920", VA = "0x180516920")]
public static DsaPublicKeyParameters GetDsaPublicKey(DSAParameters dp)
{
if (dp.Seed != (ulong)0L)
{
byte[] seed = dp.Seed;
}
int num = 0;
byte[] g;
BigInteger bigInteger = new BigInteger(1, g);
g = dp.G;
BigInteger bigInteger2;
BigInteger bigInteger3;
DsaParameters dsaParameters = new DsaParameters(bigInteger2, bigInteger3, bigInteger, num);
BigInteger bigInteger4;
return new DsaPublicKeyParameters(bigInteger4, dsaParameters);
}
// Token: 0x0600A092 RID: 41106 RVA: 0x00214F04 File Offset: 0x00213104
[Token(Token = "0x600A092")]
[Address(RVA = "0x516EE0", Offset = "0x515EE0", VA = "0x180516EE0")]
public static AsymmetricCipherKeyPair GetRsaKeyPair(RSA rsa)
{
byte[] array;
byte b = array[0];
byte b2 = array[2];
AsymmetricCipherKeyPair asymmetricCipherKeyPair;
return asymmetricCipherKeyPair;
}
// Token: 0x0600A093 RID: 41107 RVA: 0x00214F28 File Offset: 0x00213128
[Token(Token = "0x600A093")]
[Address(RVA = "0x516CB0", Offset = "0x515CB0", VA = "0x180516CB0")]
public static AsymmetricCipherKeyPair GetRsaKeyPair(RSAParameters rp)
{
int num;
BigInteger bigInteger;
BigInteger bigInteger2;
RsaKeyParameters rsaKeyParameters = new RsaKeyParameters(num != 0, bigInteger, bigInteger2);
num = 0;
byte[] p;
BigInteger bigInteger3 = new BigInteger(1, p);
p = rp.P;
BigInteger bigInteger4 = new BigInteger(1, p);
byte[] dp;
BigInteger bigInteger5 = new BigInteger(1, dp);
dp = rp.DP;
BigInteger bigInteger6 = new BigInteger(1, dp);
BigInteger bigInteger7 = new BigInteger(1, dp);
AsymmetricCipherKeyPair asymmetricCipherKeyPair;
return asymmetricCipherKeyPair;
}
// Token: 0x0600A094 RID: 41108 RVA: 0x00214F88 File Offset: 0x00213188
[Token(Token = "0x600A094")]
[Address(RVA = "0x516F50", Offset = "0x515F50", VA = "0x180516F50")]
public static RsaKeyParameters GetRsaPublicKey(RSA rsa)
{
int num;
BigInteger bigInteger;
BigInteger bigInteger2;
RsaKeyParameters rsaKeyParameters = new RsaKeyParameters(num != 0, bigInteger, bigInteger2);
num = 0;
return rsaKeyParameters;
}
// Token: 0x0600A095 RID: 41109 RVA: 0x00214FAC File Offset: 0x002131AC
[Token(Token = "0x600A095")]
[Address(RVA = "0x517050", Offset = "0x516050", VA = "0x180517050")]
public static RsaKeyParameters GetRsaPublicKey(RSAParameters rp)
{
int num;
BigInteger bigInteger;
BigInteger bigInteger2;
RsaKeyParameters rsaKeyParameters = new RsaKeyParameters(num != 0, bigInteger, bigInteger2);
num = 0;
return rsaKeyParameters;
}
// Token: 0x0600A096 RID: 41110 RVA: 0x0000220F File Offset: 0x0000040F
[Token(Token = "0x600A096")]
[Address(RVA = "0x516AA0", Offset = "0x515AA0", VA = "0x180516AA0")]
public static AsymmetricCipherKeyPair GetKeyPair(AsymmetricAlgorithm privateKey)
{
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
}
// Token: 0x0600A097 RID: 41111 RVA: 0x00214FC8 File Offset: 0x002131C8
[Token(Token = "0x600A097")]
[Address(RVA = "0x5176F0", Offset = "0x5166F0", VA = "0x1805176F0")]
public static RSA ToRSA(RsaKeyParameters rsaKey)
{
int num = 0;
byte[] array = rsaKey.modulus.ToByteArrayUnsigned();
BigInteger exponent = rsaKey.exponent;
byte[] array2 = exponent.ToByteArrayUnsigned();
int length = array.Length;
byte[] array3 = DotNetUtilities.ConvertRSAParametersField(exponent, length);
return DotNetUtilities.CreateRSAProvider(num);
}
// Token: 0x0600A098 RID: 41112 RVA: 0x00215010 File Offset: 0x00213210
[Token(Token = "0x600A098")]
[Address(RVA = "0x5175B0", Offset = "0x5165B0", VA = "0x1805175B0")]
public static RSA ToRSA(RsaKeyParameters rsaKey, CspParameters csp)
{
int num = 0;
byte[] array = rsaKey.modulus.ToByteArrayUnsigned();
BigInteger exponent = rsaKey.exponent;
byte[] array2 = exponent.ToByteArrayUnsigned();
int length = array.Length;
byte[] array3 = DotNetUtilities.ConvertRSAParametersField(exponent, length);
RSAParameters rsaparameters = new RSACryptoServiceProvider(csp).ExportParameters(num != 0);
throw new NullReferenceException();
}
// Token: 0x0600A099 RID: 41113 RVA: 0x00215060 File Offset: 0x00213260
[Token(Token = "0x600A099")]
[Address(RVA = "0x5178B0", Offset = "0x5168B0", VA = "0x1805178B0")]
public static RSA ToRSA(RsaPrivateCrtKeyParameters privKey)
{
RSAParameters rsaparameters;
byte[] p = rsaparameters.P;
byte[] dp = rsaparameters.DP;
byte[] inverseQ = rsaparameters.InverseQ;
RSA rsa;
return rsa;
}
// Token: 0x0600A09A RID: 41114 RVA: 0x00215084 File Offset: 0x00213284
[Token(Token = "0x600A09A")]
[Address(RVA = "0x517470", Offset = "0x516470", VA = "0x180517470")]
public static RSA ToRSA(RsaPrivateCrtKeyParameters privKey, CspParameters csp)
{
RSAParameters rsaparameters;
byte[] p = rsaparameters.P;
byte[] dp = rsaparameters.DP;
byte[] inverseQ = rsaparameters.InverseQ;
RSACryptoServiceProvider rsacryptoServiceProvider = new RSACryptoServiceProvider(csp);
throw new NullReferenceException();
}
// Token: 0x0600A09B RID: 41115 RVA: 0x002150B4 File Offset: 0x002132B4
[Token(Token = "0x600A09B")]
[Address(RVA = "0x517560", Offset = "0x516560", VA = "0x180517560")]
public static RSA ToRSA(RsaPrivateKeyStructure privKey)
{
RSAParameters rsaparameters;
byte[] p = rsaparameters.P;
byte[] dp = rsaparameters.DP;
byte[] inverseQ = rsaparameters.InverseQ;
RSA rsa;
return rsa;
}
// Token: 0x0600A09C RID: 41116 RVA: 0x002150D8 File Offset: 0x002132D8
[Token(Token = "0x600A09C")]
[Address(RVA = "0x5177C0", Offset = "0x5167C0", VA = "0x1805177C0")]
public static RSA ToRSA(RsaPrivateKeyStructure privKey, CspParameters csp)
{
RSAParameters rsaparameters;
byte[] p = rsaparameters.P;
byte[] dp = rsaparameters.DP;
byte[] inverseQ = rsaparameters.InverseQ;
RSACryptoServiceProvider rsacryptoServiceProvider = new RSACryptoServiceProvider(csp);
throw new NullReferenceException();
}
// Token: 0x0600A09D RID: 41117 RVA: 0x00215108 File Offset: 0x00213308
[Token(Token = "0x600A09D")]
[Address(RVA = "0x517110", Offset = "0x516110", VA = "0x180517110")]
public static RSAParameters ToRSAParameters(RsaKeyParameters rsaKey)
{
if ("{il2cpp array field il2cppMethodInfo->}" == (ulong)0L)
{
}
rsaKey.privateKey = false;
rsaKey.exponent = 0;
throw new NullReferenceException();
}
// Token: 0x0600A09E RID: 41118 RVA: 0x00215134 File Offset: 0x00213334
[Token(Token = "0x600A09E")]
[Address(RVA = "0x517320", Offset = "0x516320", VA = "0x180517320")]
public static RSAParameters ToRSAParameters(RsaPrivateCrtKeyParameters privKey)
{
byte[] array;
privKey.privateKey = array != null;
byte[] array2;
privKey.exponent = array2;
byte[] array3;
privKey.p = array3;
throw new NullReferenceException();
}
// Token: 0x0600A09F RID: 41119 RVA: 0x00215160 File Offset: 0x00213360
[Token(Token = "0x600A09F")]
[Address(RVA = "0x5171D0", Offset = "0x5161D0", VA = "0x1805171D0")]
public static RSAParameters ToRSAParameters(RsaPrivateKeyStructure privKey)
{
byte[] array;
privKey.modulus = array;
byte[] array2;
privKey.privateExponent = array2;
byte[] array3;
privKey.prime2 = array3;
throw new NullReferenceException();
}
// Token: 0x0600A0A0 RID: 41120 RVA: 0x0021518C File Offset: 0x0021338C
[Token(Token = "0x600A0A0")]
[Address(RVA = "0x5161C0", Offset = "0x5151C0", VA = "0x1805161C0")]
private static byte[] ConvertRSAParametersField(BigInteger n, int size)
{
byte[] array = n.ToByteArrayUnsigned();
if (array.Length != size)
{
byte[] array2 = new byte[size];
int length = array.Length;
int num = 0;
Array.Copy(array, num, array2, size, length);
}
return array;
}
// Token: 0x0600A0A1 RID: 41121 RVA: 0x002151CC File Offset: 0x002133CC
[Token(Token = "0x600A0A1")]
[Address(RVA = "0x516350", Offset = "0x515350", VA = "0x180516350")]
private static RSA CreateRSAProvider(RSAParameters rp)
{
CspParameters cspParameters = new CspParameters();
Guid guid = Guid.NewGuid();
string text = string.Format("BouncyCastle-{0}", guid);
cspParameters.KeyContainerName = text;
RSACryptoServiceProvider rsacryptoServiceProvider = new RSACryptoServiceProvider(cspParameters);
byte[] p = rp.P;
byte[] dp = rp.DP;
byte[] inverseQ = rp.InverseQ;
throw new NullReferenceException();
}
// Token: 0x0600A0A2 RID: 41122 RVA: 0x0021521C File Offset: 0x0021341C
[Token(Token = "0x600A0A2")]
[Address(RVA = "0x5162A0", Offset = "0x5152A0", VA = "0x1805162A0")]
private static RSA CreateRSAProvider(RSAParameters rp, CspParameters csp)
{
RSACryptoServiceProvider rsacryptoServiceProvider = new RSACryptoServiceProvider(csp);
byte[] p = rp.P;
byte[] dp = rp.DP;
byte[] inverseQ = rp.InverseQ;
throw new NullReferenceException();
}
}
}
@@ -0,0 +1,28 @@
using System;
using System.IO;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A7E RID: 6782
[Token(Token = "0x2001A7E")]
[Serializable]
public class EncryptionException : IOException
{
// Token: 0x0600A069 RID: 41065 RVA: 0x00213A50 File Offset: 0x00211C50
[Token(Token = "0x600A069")]
[Address(RVA = "0x4F0D40", Offset = "0x4EFD40", VA = "0x1804F0D40")]
public EncryptionException(string message)
: base(message)
{
}
// Token: 0x0600A06A RID: 41066 RVA: 0x00213A64 File Offset: 0x00211C64
[Token(Token = "0x600A06A")]
[Address(RVA = "0x4A7900", Offset = "0x4A6900", VA = "0x1804A7900")]
public EncryptionException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A88 RID: 6792
[Token(Token = "0x2001A88")]
[Serializable]
public class GeneralSecurityException : Exception
{
// Token: 0x0600A0A3 RID: 41123 RVA: 0x0021524C File Offset: 0x0021344C
[Token(Token = "0x600A0A3")]
[Address(RVA = "0x50FCE0", Offset = "0x50ECE0", VA = "0x18050FCE0")]
public GeneralSecurityException()
{
}
// Token: 0x0600A0A4 RID: 41124 RVA: 0x00215260 File Offset: 0x00213460
[Token(Token = "0x600A0A4")]
[Address(RVA = "0x50FDC0", Offset = "0x50EDC0", VA = "0x18050FDC0")]
public GeneralSecurityException(string message)
: base(message)
{
}
// Token: 0x0600A0A5 RID: 41125 RVA: 0x00215274 File Offset: 0x00213474
[Token(Token = "0x600A0A5")]
[Address(RVA = "0x50FD40", Offset = "0x50ED40", VA = "0x18050FD40")]
public GeneralSecurityException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,331 @@
using System;
using System.Collections;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Generators;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A89 RID: 6793
[Token(Token = "0x2001A89")]
public sealed class GeneratorUtilities
{
// Token: 0x0600A0A6 RID: 41126 RVA: 0x0021528C File Offset: 0x0021348C
[Token(Token = "0x600A0A6")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private GeneratorUtilities()
{
}
// Token: 0x0600A0A7 RID: 41127 RVA: 0x002152A0 File Offset: 0x002134A0
[Token(Token = "0x600A0A7")]
[Address(RVA = "0x518E90", Offset = "0x517E90", VA = "0x180518E90")]
static GeneratorUtilities()
{
/*
An exception occurred when decompiling this method (0600A0A7)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Security.GeneratorUtilities::.cctor()
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_F31:
stelem:string([mscorlib]System.String, ldloc:string[](var_140_F12), ldc.i4:int32(1), ldstr:string("HMACSHA1"))
}
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: 0x0600A0A8 RID: 41128 RVA: 0x002161EC File Offset: 0x002143EC
[Token(Token = "0x600A0A8")]
[Address(RVA = "0x5179F0", Offset = "0x5169F0", VA = "0x1805179F0")]
private static void AddDefaultKeySizeEntries(int size, params string[] algorithms)
{
int num = 0;
int length = algorithms.Length;
if (num < length)
{
IDictionary dictionary = GeneratorUtilities.defaultKeySizes;
num++;
}
}
// Token: 0x0600A0A9 RID: 41129 RVA: 0x00216218 File Offset: 0x00214418
[Token(Token = "0x600A0A9")]
[Address(RVA = "0x517D20", Offset = "0x516D20", VA = "0x180517D20")]
private static void AddKgAlgorithm(string canonicalName, params object[] aliases)
{
IDictionary dictionary = GeneratorUtilities.kgAlgorithms;
string text = Platform.ToUpperInvariant(canonicalName);
int num = 0;
int length = aliases.Length;
if (num < length)
{
object obj = aliases[num];
IDictionary dictionary2 = GeneratorUtilities.kgAlgorithms;
int hashCode = obj.GetHashCode();
num++;
}
}
// Token: 0x0600A0AA RID: 41130 RVA: 0x00216264 File Offset: 0x00214464
[Token(Token = "0x600A0AA")]
[Address(RVA = "0x517EE0", Offset = "0x516EE0", VA = "0x180517EE0")]
private static void AddKpgAlgorithm(string canonicalName, params object[] aliases)
{
IDictionary dictionary = GeneratorUtilities.kpgAlgorithms;
string text = Platform.ToUpperInvariant(canonicalName);
int num = 0;
int length = aliases.Length;
if (num < length)
{
object obj = aliases[num];
IDictionary dictionary2 = GeneratorUtilities.kpgAlgorithms;
int hashCode = obj.GetHashCode();
num++;
}
}
// Token: 0x0600A0AB RID: 41131 RVA: 0x002162B0 File Offset: 0x002144B0
[Token(Token = "0x600A0AB")]
[Address(RVA = "0x517AF0", Offset = "0x516AF0", VA = "0x180517AF0")]
private static void AddHMacKeyGenerator(string algorithm, params object[] aliases)
{
string text = "HMAC" + algorithm;
IDictionary dictionary = GeneratorUtilities.kgAlgorithms;
IDictionary dictionary2 = GeneratorUtilities.kgAlgorithms;
string text2 = "HMAC-" + algorithm;
IDictionary dictionary3 = GeneratorUtilities.kgAlgorithms;
string text3 = "HMAC/" + algorithm;
int num = 0;
int length = aliases.Length;
if (num < length)
{
object obj = aliases[num];
IDictionary dictionary4 = GeneratorUtilities.kgAlgorithms;
int hashCode = obj.GetHashCode();
num++;
}
}
// Token: 0x0600A0AC RID: 41132 RVA: 0x0021632C File Offset: 0x0021452C
[Token(Token = "0x600A0AC")]
[Address(RVA = "0x5181B0", Offset = "0x5171B0", VA = "0x1805181B0")]
internal static string GetCanonicalKeyGeneratorAlgorithm(string algorithm)
{
string text;
for (;;)
{
IDictionary dictionary = GeneratorUtilities.kgAlgorithms;
text = Platform.ToUpperInvariant(algorithm);
if (text == 0)
{
break;
}
if (text != 0)
{
goto Block_1;
}
}
return text;
Block_1:
throw new NullReferenceException();
}
// Token: 0x0600A0AD RID: 41133 RVA: 0x00216358 File Offset: 0x00214558
[Token(Token = "0x600A0AD")]
[Address(RVA = "0x518290", Offset = "0x517290", VA = "0x180518290")]
internal static string GetCanonicalKeyPairGeneratorAlgorithm(string algorithm)
{
string text;
for (;;)
{
IDictionary dictionary = GeneratorUtilities.kpgAlgorithms;
text = Platform.ToUpperInvariant(algorithm);
if (text == 0)
{
break;
}
if (text != 0)
{
goto Block_1;
}
}
return text;
Block_1:
throw new NullReferenceException();
}
// Token: 0x0600A0AE RID: 41134 RVA: 0x00216384 File Offset: 0x00214584
[Token(Token = "0x600A0AE")]
[Address(RVA = "0x5185D0", Offset = "0x5175D0", VA = "0x1805185D0")]
public static CipherKeyGenerator GetKeyGenerator(DerObjectIdentifier oid)
{
return GeneratorUtilities.GetKeyGenerator(oid.identifier);
}
// Token: 0x0600A0AF RID: 41135 RVA: 0x002163A4 File Offset: 0x002145A4
[Token(Token = "0x600A0AF")]
[Address(RVA = "0x518630", Offset = "0x517630", VA = "0x180518630")]
public static CipherKeyGenerator GetKeyGenerator(string algorithm)
{
string canonicalKeyGeneratorAlgorithm = GeneratorUtilities.GetCanonicalKeyGeneratorAlgorithm(algorithm);
if (canonicalKeyGeneratorAlgorithm != 0)
{
int num = GeneratorUtilities.FindDefaultKeySize(canonicalKeyGeneratorAlgorithm);
if (num == -1)
{
goto IL_6C;
}
if (!string.Equals(canonicalKeyGeneratorAlgorithm, "DES"))
{
if (!string.Equals(canonicalKeyGeneratorAlgorithm, "DESEDE") && !string.Equals(canonicalKeyGeneratorAlgorithm, "DESEDE3"))
{
return new CipherKeyGenerator(num);
}
DesEdeKeyGenerator desEdeKeyGenerator = new DesEdeKeyGenerator(num);
}
DesKeyGenerator desKeyGenerator = new DesKeyGenerator(num);
}
SecurityUtilityException ex = new SecurityUtilityException("KeyGenerator " + algorithm + " not recognised.");
IL_6C:
string[] array = new string[5];
throw new NullReferenceException();
}
// Token: 0x0600A0B0 RID: 41136 RVA: 0x0021648C File Offset: 0x0021468C
[Token(Token = "0x600A0B0")]
[Address(RVA = "0x5188E0", Offset = "0x5178E0", VA = "0x1805188E0")]
public static IAsymmetricCipherKeyPairGenerator GetKeyPairGenerator(DerObjectIdentifier oid)
{
return GeneratorUtilities.GetKeyPairGenerator(oid.identifier);
}
// Token: 0x0600A0B1 RID: 41137 RVA: 0x002164AC File Offset: 0x002146AC
[Token(Token = "0x600A0B1")]
[Address(RVA = "0x518940", Offset = "0x517940", VA = "0x180518940")]
public static IAsymmetricCipherKeyPairGenerator GetKeyPairGenerator(string algorithm)
{
string text;
do
{
IDictionary dictionary = GeneratorUtilities.kpgAlgorithms;
text = Platform.ToUpperInvariant(algorithm);
}
while (text == 0 || text == 0);
if (text == 0)
{
if (text == 0)
{
bool flag = Platform.StartsWith(text, "EC");
if (!flag)
{
if (!flag)
{
if (!flag)
{
if (!flag)
{
if (!flag)
{
if (!flag)
{
if (!flag)
{
if (!flag)
{
string[] array = new string[5];
throw new NullReferenceException();
}
X448KeyPairGenerator x448KeyPairGenerator = new X448KeyPairGenerator();
}
X25519KeyPairGenerator x25519KeyPairGenerator = new X25519KeyPairGenerator();
}
RsaKeyPairGenerator rsaKeyPairGenerator = new RsaKeyPairGenerator();
}
Gost3410KeyPairGenerator gost3410KeyPairGenerator = new Gost3410KeyPairGenerator();
}
ElGamalKeyPairGenerator elGamalKeyPairGenerator = new ElGamalKeyPairGenerator();
}
Ed448KeyPairGenerator ed448KeyPairGenerator = new Ed448KeyPairGenerator();
}
Ed25519KeyPairGenerator ed25519KeyPairGenerator = new Ed25519KeyPairGenerator();
}
ECKeyPairGenerator eckeyPairGenerator = new ECKeyPairGenerator(text);
}
DsaKeyPairGenerator dsaKeyPairGenerator = new DsaKeyPairGenerator();
}
DHKeyPairGenerator dhkeyPairGenerator = new DHKeyPairGenerator();
throw new NullReferenceException();
}
// Token: 0x0600A0B2 RID: 41138 RVA: 0x002165C0 File Offset: 0x002147C0
[Token(Token = "0x600A0B2")]
[Address(RVA = "0x518570", Offset = "0x517570", VA = "0x180518570")]
internal static int GetDefaultKeySize(DerObjectIdentifier oid)
{
return GeneratorUtilities.GetDefaultKeySize(oid.identifier);
}
// Token: 0x0600A0B3 RID: 41139 RVA: 0x002165E0 File Offset: 0x002147E0
[Token(Token = "0x600A0B3")]
[Address(RVA = "0x518370", Offset = "0x517370", VA = "0x180518370")]
internal static int GetDefaultKeySize(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A0B3)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Int32 BestHTTP.SecureProtocol.Org.BouncyCastle.Security.GeneratorUtilities::GetDefaultKeySize(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_85:
stloc:SecurityUtilityException(var_4_9A, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, call:string(string::Concat, ldstr:string("KeyGenerator "), ldloc:string(algorithm), ldstr:string(" not recognised."))))
}
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: 0x0600A0B4 RID: 41140 RVA: 0x00216688 File Offset: 0x00214888
[Token(Token = "0x600A0B4")]
[Address(RVA = "0x5180A0", Offset = "0x5170A0", VA = "0x1805180A0")]
private static int FindDefaultKeySize(string canonicalName)
{
IDictionary dictionary = GeneratorUtilities.defaultKeySizes;
IDictionary dictionary2 = GeneratorUtilities.defaultKeySizes;
IDictionary dictionary3 = GeneratorUtilities.kgAlgorithms;
return -1;
}
// Token: 0x04006B96 RID: 27542
[Token(Token = "0x4006B96")]
private static readonly IDictionary kgAlgorithms;
// Token: 0x04006B97 RID: 27543
[Token(Token = "0x4006B97")]
private static readonly IDictionary kpgAlgorithms;
// Token: 0x04006B98 RID: 27544
[Token(Token = "0x4006B98")]
private static readonly IDictionary defaultKeySizes;
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A8A RID: 6794
[Token(Token = "0x2001A8A")]
[Serializable]
public class InvalidKeyException : KeyException
{
// Token: 0x0600A0B5 RID: 41141 RVA: 0x002166B0 File Offset: 0x002148B0
[Token(Token = "0x600A0B5")]
[Address(RVA = "0x5DB0F0", Offset = "0x5DA0F0", VA = "0x1805DB0F0")]
public InvalidKeyException()
{
}
// Token: 0x0600A0B6 RID: 41142 RVA: 0x002166C4 File Offset: 0x002148C4
[Token(Token = "0x600A0B6")]
[Address(RVA = "0x5DB0E0", Offset = "0x5DA0E0", VA = "0x1805DB0E0")]
public InvalidKeyException(string message)
: base(message)
{
}
// Token: 0x0600A0B7 RID: 41143 RVA: 0x002166D8 File Offset: 0x002148D8
[Token(Token = "0x600A0B7")]
[Address(RVA = "0x5DB0D0", Offset = "0x5DA0D0", VA = "0x1805DB0D0")]
public InvalidKeyException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A8B RID: 6795
[Token(Token = "0x2001A8B")]
[Serializable]
public class InvalidParameterException : KeyException
{
// Token: 0x0600A0B8 RID: 41144 RVA: 0x002166F0 File Offset: 0x002148F0
[Token(Token = "0x600A0B8")]
[Address(RVA = "0x5DB0F0", Offset = "0x5DA0F0", VA = "0x1805DB0F0")]
public InvalidParameterException()
{
}
// Token: 0x0600A0B9 RID: 41145 RVA: 0x00216704 File Offset: 0x00214904
[Token(Token = "0x600A0B9")]
[Address(RVA = "0x5DB0E0", Offset = "0x5DA0E0", VA = "0x1805DB0E0")]
public InvalidParameterException(string message)
: base(message)
{
}
// Token: 0x0600A0BA RID: 41146 RVA: 0x00216718 File Offset: 0x00214918
[Token(Token = "0x600A0BA")]
[Address(RVA = "0x5DB0D0", Offset = "0x5DA0D0", VA = "0x1805DB0D0")]
public InvalidParameterException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A8C RID: 6796
[Token(Token = "0x2001A8C")]
[Serializable]
public class KeyException : GeneralSecurityException
{
// Token: 0x0600A0BB RID: 41147 RVA: 0x00216730 File Offset: 0x00214930
[Token(Token = "0x600A0BB")]
[Address(RVA = "0x5DB0F0", Offset = "0x5DA0F0", VA = "0x1805DB0F0")]
public KeyException()
{
}
// Token: 0x0600A0BC RID: 41148 RVA: 0x00216744 File Offset: 0x00214944
[Token(Token = "0x600A0BC")]
[Address(RVA = "0x5DB0E0", Offset = "0x5DA0E0", VA = "0x1805DB0E0")]
public KeyException(string message)
: base(message)
{
}
// Token: 0x0600A0BD RID: 41149 RVA: 0x00216758 File Offset: 0x00214958
[Token(Token = "0x600A0BD")]
[Address(RVA = "0x5DB0D0", Offset = "0x5DA0D0", VA = "0x1805DB0D0")]
public KeyException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,201 @@
using System;
using System.Collections;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Iana;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Nist;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Rosstandart;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A8D RID: 6797
[Token(Token = "0x2001A8D")]
public sealed class MacUtilities
{
// Token: 0x0600A0BE RID: 41150 RVA: 0x00216770 File Offset: 0x00214970
[Token(Token = "0x600A0BE")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private MacUtilities()
{
}
// Token: 0x0600A0BF RID: 41151 RVA: 0x00216784 File Offset: 0x00214984
[Token(Token = "0x600A0BF")]
[Address(RVA = "0x5DBEA0", Offset = "0x5DAEA0", VA = "0x1805DBEA0")]
static MacUtilities()
{
IDictionary dictionary = Platform.CreateHashtable();
DerObjectIdentifier hmacMD = IanaObjectIdentifiers.HmacMD5;
DerObjectIdentifier hmacRipeMD = IanaObjectIdentifiers.HmacRipeMD160;
DerObjectIdentifier hmacSha = IanaObjectIdentifiers.HmacSha1;
DerObjectIdentifier hmacTiger = IanaObjectIdentifiers.HmacTiger;
DerObjectIdentifier idHmacWithSha = PkcsObjectIdentifiers.IdHmacWithSha1;
DerObjectIdentifier idHmacWithSha2 = PkcsObjectIdentifiers.IdHmacWithSha224;
DerObjectIdentifier idHmacWithSha3 = PkcsObjectIdentifiers.IdHmacWithSha256;
DerObjectIdentifier idHmacWithSha4 = PkcsObjectIdentifiers.IdHmacWithSha384;
DerObjectIdentifier idHmacWithSha5 = PkcsObjectIdentifiers.IdHmacWithSha512;
DerObjectIdentifier idHMacWithSha3_ = NistObjectIdentifiers.IdHMacWithSha3_224;
DerObjectIdentifier idHMacWithSha3_2 = NistObjectIdentifiers.IdHMacWithSha3_256;
DerObjectIdentifier idHMacWithSha3_3 = NistObjectIdentifiers.IdHMacWithSha3_384;
DerObjectIdentifier idHMacWithSha3_4 = NistObjectIdentifiers.IdHMacWithSha3_512;
DerObjectIdentifier id_tc26_hmac_gost_3411_12_ = RosstandartObjectIdentifiers.id_tc26_hmac_gost_3411_12_256;
DerObjectIdentifier id_tc26_hmac_gost_3411_12_2 = RosstandartObjectIdentifiers.id_tc26_hmac_gost_3411_12_512;
DerObjectIdentifier desEde3Cbc = PkcsObjectIdentifiers.DesEde3Cbc;
}
// Token: 0x0600A0C0 RID: 41152 RVA: 0x00216810 File Offset: 0x00214A10
[Token(Token = "0x600A0C0")]
[Address(RVA = "0x5DB470", Offset = "0x5DA470", VA = "0x1805DB470")]
public static IMac GetMac(DerObjectIdentifier id)
{
return MacUtilities.GetMac(id.identifier);
}
// Token: 0x0600A0C1 RID: 41153 RVA: 0x00216830 File Offset: 0x00214A30
[Token(Token = "0x600A0C1")]
[Address(RVA = "0x5DB4D0", Offset = "0x5DA4D0", VA = "0x1805DB4D0")]
public static IMac GetMac(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A0C1)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IMac BestHTTP.SecureProtocol.Org.BouncyCastle.Security.MacUtilities::GetMac(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_1BE:
stloc:SecurityUtilityException(var_34_1C5, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldloc:string(var_33)))
}
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.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.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.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.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.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.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.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.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.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.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.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.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.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.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.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.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.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.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.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.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.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.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: 0x0600A0C2 RID: 41154 RVA: 0x00216A04 File Offset: 0x00214C04
[Token(Token = "0x600A0C2")]
[Address(RVA = "0x5DB3C0", Offset = "0x5DA3C0", VA = "0x1805DB3C0")]
public static string GetAlgorithmName(DerObjectIdentifier oid)
{
throw new NullReferenceException();
}
// Token: 0x0600A0C3 RID: 41155 RVA: 0x00216A18 File Offset: 0x00214C18
[Token(Token = "0x600A0C3")]
[Address(RVA = "0x5DB100", Offset = "0x5DA100", VA = "0x1805DB100")]
public static byte[] CalculateMac(string algorithm, ICipherParameters cp, byte[] input)
{
IMac mac = MacUtilities.GetMac(algorithm);
int num = 0;
if (num < input)
{
num += num;
num++;
}
int length = input.Length;
return MacUtilities.DoFinal(mac);
}
// Token: 0x0600A0C4 RID: 41156 RVA: 0x00216A54 File Offset: 0x00214C54
[Token(Token = "0x600A0C4")]
[Address(RVA = "0x5DB230", Offset = "0x5DA230", VA = "0x1805DB230")]
public static byte[] DoFinal(IMac mac)
{
byte[] array = new byte[0];
int num = 0;
num += num;
num++;
return array;
}
// Token: 0x0600A0C5 RID: 41157 RVA: 0x00216A80 File Offset: 0x00214C80
[Token(Token = "0x600A0C5")]
[Address(RVA = "0x5DB320", Offset = "0x5DA320", VA = "0x1805DB320")]
public static byte[] DoFinal(IMac mac, byte[] input)
{
int length = input.Length;
return MacUtilities.DoFinal(mac);
}
// Token: 0x04006B99 RID: 27545
[Token(Token = "0x4006B99")]
private static readonly IDictionary algorithms;
}
}
@@ -0,0 +1,35 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A8E RID: 6798
[Token(Token = "0x2001A8E")]
[Obsolete]
[Serializable]
public class NoSuchAlgorithmException : GeneralSecurityException
{
// Token: 0x0600A0C6 RID: 41158 RVA: 0x00216AA0 File Offset: 0x00214CA0
[Token(Token = "0x600A0C6")]
[Address(RVA = "0x5DB0F0", Offset = "0x5DA0F0", VA = "0x1805DB0F0")]
public NoSuchAlgorithmException()
{
}
// Token: 0x0600A0C7 RID: 41159 RVA: 0x00216AB4 File Offset: 0x00214CB4
[Token(Token = "0x600A0C7")]
[Address(RVA = "0x5DB0E0", Offset = "0x5DA0E0", VA = "0x1805DB0E0")]
public NoSuchAlgorithmException(string message)
: base(message)
{
}
// Token: 0x0600A0C8 RID: 41160 RVA: 0x00216AC8 File Offset: 0x00214CC8
[Token(Token = "0x600A0C8")]
[Address(RVA = "0x5DB0D0", Offset = "0x5DA0D0", VA = "0x1805DB0D0")]
public NoSuchAlgorithmException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,303 @@
using System;
using System.Collections;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Parameters;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A8F RID: 6799
[Token(Token = "0x2001A8F")]
public sealed class ParameterUtilities
{
// Token: 0x0600A0C9 RID: 41161 RVA: 0x00216AE0 File Offset: 0x00214CE0
[Token(Token = "0x600A0C9")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private ParameterUtilities()
{
}
// Token: 0x0600A0CA RID: 41162 RVA: 0x00216AF4 File Offset: 0x00214CF4
[Token(Token = "0x600A0CA")]
[Address(RVA = "0x5DDD20", Offset = "0x5DCD20", VA = "0x1805DDD20")]
static ParameterUtilities()
{
/*
An exception occurred when decompiling this method (0600A0CA)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Security.ParameterUtilities::.cctor()
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_76F:
stelem:string([mscorlib]System.String, ldloc:string[](var_75_726), ldc.i4:int32(3), ldstr:string("DESEDE3"))
call:void(ParameterUtilities::AddBasicIVSizeEntries, ldc.i4:int32(8), ldloc:string[](var_75_726))
}
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: 0x0600A0CB RID: 41163 RVA: 0x00217284 File Offset: 0x00215484
[Token(Token = "0x600A0CB")]
[Address(RVA = "0x5DCB50", Offset = "0x5DBB50", VA = "0x1805DCB50")]
private static void AddAlgorithm(string canonicalName, params object[] aliases)
{
IDictionary dictionary = ParameterUtilities.algorithms;
int num = 0;
int length = aliases.Length;
if (num < length)
{
object obj = aliases[num];
IDictionary dictionary2 = ParameterUtilities.algorithms;
int hashCode = obj.GetHashCode();
num++;
}
}
// Token: 0x0600A0CC RID: 41164 RVA: 0x002172C8 File Offset: 0x002154C8
[Token(Token = "0x600A0CC")]
[Address(RVA = "0x5DCCB0", Offset = "0x5DBCB0", VA = "0x1805DCCB0")]
private static void AddBasicIVSizeEntries(int size, params string[] algorithms)
{
int num = 0;
int length = algorithms.Length;
if (num < length)
{
IDictionary dictionary = ParameterUtilities.basicIVSizes;
num++;
}
}
// Token: 0x0600A0CD RID: 41165 RVA: 0x002172F4 File Offset: 0x002154F4
[Token(Token = "0x600A0CD")]
[Address(RVA = "0x5DD7F0", Offset = "0x5DC7F0", VA = "0x1805DD7F0")]
public static string GetCanonicalAlgorithmName(string algorithm)
{
string text;
for (;;)
{
IDictionary dictionary = ParameterUtilities.algorithms;
text = Platform.ToUpperInvariant(algorithm);
if (text == 0)
{
break;
}
if (text != 0)
{
goto Block_1;
}
}
return text;
Block_1:
throw new NullReferenceException();
}
// Token: 0x0600A0CE RID: 41166 RVA: 0x00217320 File Offset: 0x00215520
[Token(Token = "0x600A0CE")]
[Address(RVA = "0x5DD240", Offset = "0x5DC240", VA = "0x1805DD240")]
public static KeyParameter CreateKeyParameter(DerObjectIdentifier algOid, byte[] keyBytes)
{
string identifier = algOid.identifier;
int length = keyBytes.Length;
int num = 0;
return ParameterUtilities.CreateKeyParameter(identifier, keyBytes, num, length);
}
// Token: 0x0600A0CF RID: 41167 RVA: 0x0021734C File Offset: 0x0021554C
[Token(Token = "0x600A0CF")]
[Address(RVA = "0x5DCF90", Offset = "0x5DBF90", VA = "0x1805DCF90")]
public static KeyParameter CreateKeyParameter(string algorithm, byte[] keyBytes)
{
int length = keyBytes.Length;
int num = 0;
return ParameterUtilities.CreateKeyParameter(algorithm, keyBytes, num, length);
}
// Token: 0x0600A0D0 RID: 41168 RVA: 0x00217374 File Offset: 0x00215574
[Token(Token = "0x600A0D0")]
[Address(RVA = "0x5DCEF0", Offset = "0x5DBEF0", VA = "0x1805DCEF0")]
public static KeyParameter CreateKeyParameter(DerObjectIdentifier algOid, byte[] keyBytes, int offset, int length)
{
return ParameterUtilities.CreateKeyParameter(algOid.identifier, keyBytes, offset, length);
}
// Token: 0x0600A0D1 RID: 41169 RVA: 0x00217398 File Offset: 0x00215598
[Token(Token = "0x600A0D1")]
[Address(RVA = "0x5DD010", Offset = "0x5DC010", VA = "0x1805DD010")]
public static KeyParameter CreateKeyParameter(string algorithm, byte[] keyBytes, int offset, int length)
{
/*
An exception occurred when decompiling this method (0600A0D1)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Parameters.KeyParameter BestHTTP.SecureProtocol.Org.BouncyCastle.Security.ParameterUtilities::CreateKeyParameter(System.String,System.Byte[],System.Int32,System.Int32)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_51:
stloc:SecurityUtilityException(var_9_66, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, call:string(string::Concat, ldstr:string("Algorithm "), ldloc:string(algorithm), ldstr:string(" not recognised."))))
}
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: 0x0600A0D2 RID: 41170 RVA: 0x0021740C File Offset: 0x0021560C
[Token(Token = "0x600A0D2")]
[Address(RVA = "0x5DDC20", Offset = "0x5DCC20", VA = "0x1805DDC20")]
public static ICipherParameters GetCipherParameters(DerObjectIdentifier algOid, ICipherParameters key, Asn1Object asn1Params)
{
return ParameterUtilities.GetCipherParameters(algOid.identifier, key, asn1Params);
}
// Token: 0x0600A0D3 RID: 41171 RVA: 0x0021742C File Offset: 0x0021562C
[Token(Token = "0x600A0D3")]
[Address(RVA = "0x5DD8D0", Offset = "0x5DC8D0", VA = "0x1805DD8D0")]
public static ICipherParameters GetCipherParameters(string algorithm, ICipherParameters key, Asn1Object asn1Params)
{
/*
An exception occurred when decompiling this method (0600A0D3)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.ICipherParameters BestHTTP.SecureProtocol.Org.BouncyCastle.Security.ParameterUtilities::GetCipherParameters(System.String,BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.ICipherParameters,BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Asn1Object)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_A9:
stloc:SecurityUtilityException(var_12_BE, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, call:string(string::Concat, ldstr:string("Algorithm "), ldloc:string(algorithm), ldstr:string(" not recognised."))))
}
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.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: 0x0600A0D4 RID: 41172 RVA: 0x002174F8 File Offset: 0x002156F8
[Token(Token = "0x600A0D4")]
[Address(RVA = "0x5DD780", Offset = "0x5DC780", VA = "0x1805DD780")]
public static Asn1Encodable GenerateParameters(DerObjectIdentifier algID, SecureRandom random)
{
return ParameterUtilities.GenerateParameters(algID.identifier, random);
}
// Token: 0x0600A0D5 RID: 41173 RVA: 0x00217518 File Offset: 0x00215718
[Token(Token = "0x600A0D5")]
[Address(RVA = "0x5DD3E0", Offset = "0x5DC3E0", VA = "0x1805DD3E0")]
public static Asn1Encodable GenerateParameters(string algorithm, SecureRandom random)
{
/*
An exception occurred when decompiling this method (0600A0D5)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Asn1Encodable BestHTTP.SecureProtocol.Org.BouncyCastle.Security.ParameterUtilities::GenerateParameters(System.String,BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SecureRandom)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_99:
stloc:SecurityUtilityException(var_9_AE, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, call:string(string::Concat, ldstr:string("Algorithm "), ldloc:string(algorithm), ldstr:string(" not recognised."))))
}
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.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.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.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.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.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: 0x0600A0D6 RID: 41174 RVA: 0x002175D4 File Offset: 0x002157D4
[Token(Token = "0x600A0D6")]
[Address(RVA = "0x5DDCA0", Offset = "0x5DCCA0", VA = "0x1805DDCA0")]
public static ICipherParameters WithRandom(ICipherParameters cp, SecureRandom random)
{
if (random != 0)
{
ParametersWithRandom parametersWithRandom = new ParametersWithRandom(cp, random);
}
return cp;
}
// Token: 0x0600A0D7 RID: 41175 RVA: 0x002175F0 File Offset: 0x002157F0
[Token(Token = "0x600A0D7")]
[Address(RVA = "0x5DCDB0", Offset = "0x5DBDB0", VA = "0x1805DCDB0")]
private static Asn1OctetString CreateIVOctetString(SecureRandom random, int ivLength)
{
byte[] array = new byte[ivLength];
double num = random.NextDouble();
DerOctetString derOctetString = new DerOctetString(array);
throw new NullReferenceException();
}
// Token: 0x0600A0D8 RID: 41176 RVA: 0x00217618 File Offset: 0x00215818
[Token(Token = "0x600A0D8")]
[Address(RVA = "0x5DCE80", Offset = "0x5DBE80", VA = "0x1805DCE80")]
private static byte[] CreateIV(SecureRandom random, int ivLength)
{
byte[] array = new byte[ivLength];
double num = random.NextDouble();
return array;
}
// Token: 0x0600A0D9 RID: 41177 RVA: 0x0021763C File Offset: 0x0021583C
[Token(Token = "0x600A0D9")]
[Address(RVA = "0x5DD2D0", Offset = "0x5DC2D0", VA = "0x1805DD2D0")]
private static int FindBasicIVSize(string canonicalName)
{
IDictionary dictionary = ParameterUtilities.basicIVSizes;
IDictionary dictionary2 = ParameterUtilities.basicIVSizes;
IDictionary dictionary3 = ParameterUtilities.algorithms;
return -1;
}
// Token: 0x04006B9A RID: 27546
[Token(Token = "0x4006B9A")]
private static readonly IDictionary algorithms;
// Token: 0x04006B9B RID: 27547
[Token(Token = "0x4006B9B")]
private static readonly IDictionary basicIVSizes;
}
}
@@ -0,0 +1,28 @@
using System;
using System.IO;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A7F RID: 6783
[Token(Token = "0x2001A7F")]
[Serializable]
public class PasswordException : IOException
{
// Token: 0x0600A06B RID: 41067 RVA: 0x00213A7C File Offset: 0x00211C7C
[Token(Token = "0x600A06B")]
[Address(RVA = "0x4F0D40", Offset = "0x4EFD40", VA = "0x1804F0D40")]
public PasswordException(string message)
: base(message)
{
}
// Token: 0x0600A06C RID: 41068 RVA: 0x00213A90 File Offset: 0x00211C90
[Token(Token = "0x600A06C")]
[Address(RVA = "0x4A7900", Offset = "0x4A6900", VA = "0x1804A7900")]
public PasswordException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,742 @@
using System;
using System.Collections;
using System.IO;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Digests;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Parameters;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A90 RID: 6800
[Token(Token = "0x2001A90")]
public sealed class PbeUtilities
{
// Token: 0x0600A0DA RID: 41178 RVA: 0x00217664 File Offset: 0x00215864
[Token(Token = "0x600A0DA")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private PbeUtilities()
{
}
// Token: 0x0600A0DB RID: 41179 RVA: 0x00217678 File Offset: 0x00215878
[Token(Token = "0x600A0DB")]
[Address(RVA = "0x5E22B0", Offset = "0x5E12B0", VA = "0x1805E22B0")]
static PbeUtilities()
{
/*
An exception occurred when decompiling this method (0600A0DB)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Security.PbeUtilities::.cctor()
---> System.Exception: Basic block has to end with unconditional control flow.
{
Block_0:
stloc:IDictionary(var_1_07, call:IDictionary(Platform::CreateHashtable))
stsfld:IDictionary(PbeUtilities::algorithms, ldloc:IDictionary(var_1_07))
stloc:IDictionary(var_3_15, call:IDictionary(Platform::CreateHashtable))
stsfld:IDictionary(PbeUtilities::algorithmType, ldloc:IDictionary(var_3_15))
stsfld:IDictionary(PbeUtilities::oids, call:IDictionary(Platform::CreateHashtable))
stloc:IDictionary(var_5_2E, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_7_35, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_9_3C, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_10_43, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::IdPbeS2))
stloc:IDictionary(var_12_4A, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_14_51, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_15_58, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithMD2AndDesCbc))
stloc:IDictionary(var_17_5F, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_19_66, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_20_6D, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithMD2AndRC2Cbc))
stloc:IDictionary(var_22_74, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_24_7B, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_25_82, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithMD5AndDesCbc))
stloc:IDictionary(var_27_89, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_29_90, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_30_97, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithMD5AndRC2Cbc))
stloc:IDictionary(var_32_9E, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_34_A5, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_36_AC, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_38_B3, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_40_BA, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_41_C1, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithSha1AndDesCbc))
stloc:IDictionary(var_43_C8, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_45_CF, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_47_D6, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_49_DD, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_51_E4, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_52_EB, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithSha1AndRC2Cbc))
stloc:IDictionary(var_54_F2, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_56_F9, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_57_100, ldsfld:DerObjectIdentifier(BCObjectIdentifiers::bc_pbe_sha1_pkcs12_aes128_cbc))
stloc:IDictionary(var_59_107, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_60_10E, ldsfld:DerObjectIdentifier(BCObjectIdentifiers::bc_pbe_sha1_pkcs12_aes192_cbc))
stloc:IDictionary(var_62_115, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_63_11C, ldsfld:DerObjectIdentifier(BCObjectIdentifiers::bc_pbe_sha1_pkcs12_aes256_cbc))
stloc:IDictionary(var_65_123, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_66_12A, ldsfld:DerObjectIdentifier(BCObjectIdentifiers::bc_pbe_sha256_pkcs12_aes128_cbc))
stloc:IDictionary(var_68_131, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_69_138, ldsfld:DerObjectIdentifier(BCObjectIdentifiers::bc_pbe_sha256_pkcs12_aes192_cbc))
stloc:IDictionary(var_71_13F, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_72_146, ldsfld:DerObjectIdentifier(BCObjectIdentifiers::bc_pbe_sha256_pkcs12_aes256_cbc))
stloc:IDictionary(var_74_14D, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_76_154, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_78_15B, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_80_162, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_81_169, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd128BitRC4))
stloc:IDictionary(var_83_170, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_85_177, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_87_17E, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_89_185, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_90_18C, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd40BitRC4))
stloc:IDictionary(var_92_193, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_94_19A, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_96_1A1, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_98_1A8, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_100_1AF, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_102_1B6, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_104_1BD, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_105_1C4, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd3KeyTripleDesCbc))
stloc:IDictionary(var_107_1CB, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_109_1D2, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_111_1D9, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_113_1E0, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_115_1E7, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_117_1EE, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_119_1F5, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_120_1FC, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd2KeyTripleDesCbc))
stloc:IDictionary(var_122_203, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_124_20A, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_126_211, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_128_218, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_129_21F, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbeWithShaAnd128BitRC2Cbc))
stloc:IDictionary(var_131_226, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_133_22D, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_135_234, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_137_23B, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:DerObjectIdentifier(var_138_242, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::PbewithShaAnd40BitRC2Cbc))
stloc:IDictionary(var_140_249, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_142_250, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_144_257, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_146_25E, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_148_265, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_150_26C, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_152_273, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_154_27A, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_156_281, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_158_288, ldsfld:IDictionary(PbeUtilities::algorithms))
stloc:IDictionary(var_160_28F, ldsfld:IDictionary(PbeUtilities::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: 0x0600A0DC RID: 41180 RVA: 0x00217918 File Offset: 0x00215B18
[Token(Token = "0x600A0DC")]
[Address(RVA = "0x5E2100", Offset = "0x5E1100", VA = "0x1805E2100")]
private static PbeParametersGenerator MakePbeGenerator(string type, IDigest digest, byte[] key, byte[] salt, int iterationCount)
{
/*
An exception occurred when decompiling this method (0600A0DC)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.PbeParametersGenerator BestHTTP.SecureProtocol.Org.BouncyCastle.Security.PbeUtilities::MakePbeGenerator(System.String,BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IDigest,System.Byte[],System.Byte[],System.Int32)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_5D:
stloc:ArgumentException(var_5_69, newobj:ArgumentException(ArgumentException::.ctor, ldloc:string(var_4), ldstr:string("type")))
}
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.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.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.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: 0x0600A0DD RID: 41181 RVA: 0x00217990 File Offset: 0x00215B90
[Token(Token = "0x600A0DD")]
[Address(RVA = "0x5E1900", Offset = "0x5E0900", VA = "0x1805E1900")]
public static DerObjectIdentifier GetObjectIdentifier(string mechanism)
{
string text;
do
{
IDictionary dictionary = PbeUtilities.algorithms;
text = Platform.ToUpperInvariant(mechanism);
if (text == 0)
{
goto IL_2A;
}
}
while (text == 0);
IDictionary dictionary2 = PbeUtilities.oids;
IDictionary dictionary3 = PbeUtilities.algorithms;
IL_2A:
throw new NullReferenceException();
}
// Token: 0x170019A3 RID: 6563
// (get) Token: 0x0600A0DE RID: 41182 RVA: 0x002179D0 File Offset: 0x00215BD0
[Token(Token = "0x170019A3")]
public static ICollection Algorithms
{
[Token(Token = "0x600A0DE")]
[Address(RVA = "0x5E4B80", Offset = "0x5E3B80", VA = "0x1805E4B80")]
get
{
IDictionary dictionary = PbeUtilities.oids;
throw new NullReferenceException();
}
}
// Token: 0x0600A0DF RID: 41183 RVA: 0x002179E8 File Offset: 0x00215BE8
[Token(Token = "0x600A0DF")]
[Address(RVA = "0x5E1D10", Offset = "0x5E0D10", VA = "0x1805E1D10")]
public static bool IsPkcs12(string algorithm)
{
string text;
do
{
IDictionary dictionary = PbeUtilities.algorithms;
text = Platform.ToUpperInvariant(algorithm);
if (text == 0)
{
goto IL_1B;
}
}
while (text == 0);
IDictionary dictionary2 = PbeUtilities.algorithmType;
IL_1B:
throw new NullReferenceException();
}
// Token: 0x0600A0E0 RID: 41184 RVA: 0x00217A18 File Offset: 0x00215C18
[Token(Token = "0x600A0E0")]
[Address(RVA = "0x5E1E60", Offset = "0x5E0E60", VA = "0x1805E1E60")]
public static bool IsPkcs5Scheme1(string algorithm)
{
string text;
do
{
IDictionary dictionary = PbeUtilities.algorithms;
text = Platform.ToUpperInvariant(algorithm);
if (text == 0)
{
goto IL_1B;
}
}
while (text == 0);
IDictionary dictionary2 = PbeUtilities.algorithmType;
IL_1B:
throw new NullReferenceException();
}
// Token: 0x0600A0E1 RID: 41185 RVA: 0x00217A48 File Offset: 0x00215C48
[Token(Token = "0x600A0E1")]
[Address(RVA = "0x5E1FB0", Offset = "0x5E0FB0", VA = "0x1805E1FB0")]
public static bool IsPkcs5Scheme2(string algorithm)
{
string text;
do
{
IDictionary dictionary = PbeUtilities.algorithms;
text = Platform.ToUpperInvariant(algorithm);
if (text == 0)
{
goto IL_1B;
}
}
while (text == 0);
IDictionary dictionary2 = PbeUtilities.algorithmType;
IL_1B:
throw new NullReferenceException();
}
// Token: 0x0600A0E2 RID: 41186 RVA: 0x00217A78 File Offset: 0x00215C78
[Token(Token = "0x600A0E2")]
[Address(RVA = "0x5E1A90", Offset = "0x5E0A90", VA = "0x1805E1A90")]
public static bool IsOpenSsl(string algorithm)
{
string text;
do
{
IDictionary dictionary = PbeUtilities.algorithms;
text = Platform.ToUpperInvariant(algorithm);
if (text == 0)
{
goto IL_1B;
}
}
while (text == 0);
IDictionary dictionary2 = PbeUtilities.algorithmType;
IL_1B:
throw new NullReferenceException();
}
// Token: 0x0600A0E3 RID: 41187 RVA: 0x00217AA8 File Offset: 0x00215CA8
[Token(Token = "0x600A0E3")]
[Address(RVA = "0x5E1BE0", Offset = "0x5E0BE0", VA = "0x1805E1BE0")]
public static bool IsPbeAlgorithm(string algorithm)
{
string text;
do
{
IDictionary dictionary = PbeUtilities.algorithms;
text = Platform.ToUpperInvariant(algorithm);
if (text == 0)
{
goto IL_1D;
}
}
while (text == 0);
IDictionary dictionary2 = PbeUtilities.algorithmType;
bool flag;
return flag;
IL_1D:
throw new NullReferenceException();
}
// Token: 0x0600A0E4 RID: 41188 RVA: 0x00217ADC File Offset: 0x00215CDC
[Token(Token = "0x600A0E4")]
[Address(RVA = "0x5E0400", Offset = "0x5DF400", VA = "0x1805E0400")]
public static Asn1Encodable GenerateAlgorithmParameters(DerObjectIdentifier algorithmOid, byte[] salt, int iterationCount)
{
string identifier = algorithmOid.identifier;
if (!PbeUtilities.IsPkcs12(identifier))
{
if (!PbeUtilities.IsPkcs5Scheme2(identifier))
{
PbeParameter pbeParameter = new PbeParameter(salt, iterationCount);
}
Pbkdf2Params pbkdf2Params = new Pbkdf2Params(salt, iterationCount);
}
Pkcs12PbeParams pkcs12PbeParams = new Pkcs12PbeParams(salt, iterationCount);
throw new NullReferenceException();
}
// Token: 0x0600A0E5 RID: 41189 RVA: 0x00217B20 File Offset: 0x00215D20
[Token(Token = "0x600A0E5")]
[Address(RVA = "0x5E0580", Offset = "0x5DF580", VA = "0x1805E0580")]
public static Asn1Encodable GenerateAlgorithmParameters(string algorithm, byte[] salt, int iterationCount)
{
/*
An exception occurred when decompiling this method (0600A0E5)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Asn1Encodable BestHTTP.SecureProtocol.Org.BouncyCastle.Security.PbeUtilities::GenerateAlgorithmParameters(System.String,System.Byte[],System.Int32)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_22:
stloc:Pkcs12PbeParams(var_2_29, newobj:Pkcs12PbeParams(Pkcs12PbeParams::.ctor, ldloc:uint8[](salt), ldloc:int32(iterationCount)))
}
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: 0x0600A0E6 RID: 41190 RVA: 0x00217B58 File Offset: 0x00215D58
[Token(Token = "0x600A0E6")]
[Address(RVA = "0x5E0960", Offset = "0x5DF960", VA = "0x1805E0960")]
public static ICipherParameters GenerateCipherParameters(DerObjectIdentifier algorithmOid, char[] password, Asn1Encodable pbeParameters)
{
string identifier = algorithmOid.identifier;
int num = 0;
return PbeUtilities.GenerateCipherParameters(identifier, password, num != 0, pbeParameters);
}
// Token: 0x0600A0E7 RID: 41191 RVA: 0x00217B80 File Offset: 0x00215D80
[Token(Token = "0x600A0E7")]
[Address(RVA = "0x5E06B0", Offset = "0x5DF6B0", VA = "0x1805E06B0")]
public static ICipherParameters GenerateCipherParameters(DerObjectIdentifier algorithmOid, char[] password, bool wrongPkcs12Zero, Asn1Encodable pbeParameters)
{
return PbeUtilities.GenerateCipherParameters(algorithmOid.identifier, password, wrongPkcs12Zero, pbeParameters);
}
// Token: 0x0600A0E8 RID: 41192 RVA: 0x00217BA4 File Offset: 0x00215DA4
[Token(Token = "0x600A0E8")]
[Address(RVA = "0x5E0750", Offset = "0x5DF750", VA = "0x1805E0750")]
public static ICipherParameters GenerateCipherParameters(AlgorithmIdentifier algID, char[] password)
{
Asn1Object asn1Object = algID.ToAsn1Object();
DerObjectIdentifier objectID = algID.ObjectID;
ICipherParameters cipherParameters;
return cipherParameters;
}
// Token: 0x0600A0E9 RID: 41193 RVA: 0x00217BC8 File Offset: 0x00215DC8
[Token(Token = "0x600A0E9")]
[Address(RVA = "0x5E0890", Offset = "0x5DF890", VA = "0x1805E0890")]
public static ICipherParameters GenerateCipherParameters(AlgorithmIdentifier algID, char[] password, bool wrongPkcs12Zero)
{
Asn1Object asn1Object = algID.ToAsn1Object();
DerObjectIdentifier objectID = algID.ObjectID;
ICipherParameters cipherParameters;
return cipherParameters;
}
// Token: 0x0600A0EA RID: 41194 RVA: 0x00217BEC File Offset: 0x00215DEC
[Token(Token = "0x600A0EA")]
[Address(RVA = "0x5E0810", Offset = "0x5DF810", VA = "0x1805E0810")]
public static ICipherParameters GenerateCipherParameters(string algorithm, char[] password, Asn1Encodable pbeParameters)
{
int num = 0;
return PbeUtilities.GenerateCipherParameters(algorithm, password, num != 0, pbeParameters);
}
// Token: 0x0600A0EB RID: 41195 RVA: 0x00217C04 File Offset: 0x00215E04
[Token(Token = "0x600A0EB")]
[Address(RVA = "0x5E09F0", Offset = "0x5DF9F0", VA = "0x1805E09F0")]
public static ICipherParameters GenerateCipherParameters(string algorithm, char[] password, bool wrongPkcs12Zero, Asn1Encodable pbeParameters)
{
int num;
for (;;)
{
IDictionary dictionary = PbeUtilities.algorithms;
string text = Platform.ToUpperInvariant(algorithm);
num = 0;
if (text == 0 || text != 0)
{
if (PbeUtilities.IsPkcs12(num))
{
goto IL_4D;
}
int num2;
if (!PbeUtilities.IsPkcs5Scheme2(num))
{
PbeParameter instance = PbeParameter.GetInstance(pbeParameters);
byte[] salt = instance.GetSalt();
num2 = instance.IterationCount.IntValue;
byte[] array = PbeParametersGenerator.Pkcs5PasswordToBytes(password);
goto IL_4D;
}
IL_6C:
if (PbeUtilities.IsPkcs5Scheme2(num))
{
goto IL_1D3;
}
if (Platform.StartsWith(num, "PBEwithSHA-1"))
{
goto IL_14E;
}
if (Platform.StartsWith(num, "PBEwithSHA-256"))
{
goto IL_128;
}
if (Platform.StartsWith(num, "PBEwithMD5"))
{
goto IL_FA;
}
if (Platform.StartsWith(num, "PBEwithMD2"))
{
break;
}
if (!Platform.StartsWith(num, "PBEwithHmac"))
{
goto IL_29A;
}
string text2;
IDigest digest = DigestUtilities.GetDigest(text2);
IDictionary dictionary2 = PbeUtilities.algorithmType;
if (digest == 0 || digest != 0)
{
break;
}
continue;
IL_4D:
Pkcs12PbeParams instance2 = Pkcs12PbeParams.GetInstance(pbeParameters);
byte[] iv = instance2.GetIV();
num2 = instance2.Iterations.IntValue;
goto IL_6C;
}
}
IDictionary dictionary3 = PbeUtilities.algorithmType;
MD2Digest md2Digest = new MD2Digest();
bool flag;
if (flag)
{
goto IL_19A;
}
IL_FA:
IDictionary dictionary4 = PbeUtilities.algorithmType;
MD5Digest md5Digest = new MD5Digest();
bool flag2;
bool flag3;
if (flag2 || flag3)
{
goto IL_19A;
}
bool flag4;
if (flag4)
{
goto IL_1C0;
}
bool flag5;
if (flag5)
{
goto IL_1AD;
}
IL_128:
IDictionary dictionary5 = PbeUtilities.algorithmType;
Sha256Digest sha256Digest = new Sha256Digest();
bool flag6;
if (flag6)
{
goto IL_1C0;
}
bool flag7;
if (flag7)
{
goto IL_1AD;
}
bool flag8;
if (!flag8)
{
goto IL_29A;
}
IL_14E:
IDictionary dictionary6 = PbeUtilities.algorithmType;
Sha1Digest sha1Digest = new Sha1Digest();
bool flag9;
if (flag9)
{
goto IL_1C0;
}
bool flag10;
if (flag10)
{
goto IL_1AD;
}
bool flag11;
while (flag11)
{
}
bool flag12;
bool flag13;
if (flag12 || flag13)
{
goto IL_1AD;
}
bool flag14;
bool flag15;
bool flag16;
bool flag17;
bool flag18;
bool flag19;
if (!flag14 && !flag15 && !flag16 && !flag17 && !flag18 && !flag19)
{
goto IL_29A;
}
IL_19A:
PbeParametersGenerator pbeParametersGenerator;
ICipherParameters cipherParameters = pbeParametersGenerator.GenerateDerivedParameters("DESEDE", 192);
IL_1AD:
ICipherParameters cipherParameters2 = pbeParametersGenerator.GenerateDerivedParameters("AES", 128);
IL_1C0:
ICipherParameters cipherParameters3 = pbeParametersGenerator.GenerateDerivedParameters("AES", 128);
IL_1D3:
PbeS2Parameters pbeS2Parameters;
EncryptionScheme scheme = pbeS2Parameters.scheme;
Asn1Object asn1Object = scheme.ToAsn1Object();
Asn1Object asn1Object2 = scheme.ObjectID.ToAsn1Object();
Pbkdf2Params instance3 = Pbkdf2Params.GetInstance(pbeS2Parameters.func.ObjectID.ToAsn1Object());
Asn1OctetString instance4 = Asn1OctetString.GetInstance(asn1Object2);
Stream octetStream = instance4.GetOctetStream();
byte[] iv2 = RC2CbcParameter.GetInstance(instance4).GetIV();
byte[] salt2 = instance3.GetSalt();
int intValue = instance3.IterationCount.IntValue;
byte[] array2 = PbeParametersGenerator.Pkcs5PasswordToBytes(password);
if (instance3.KeyLength != 0)
{
int intValue2 = instance3.KeyLength.IntValue;
}
IDictionary dictionary7 = PbeUtilities.algorithmType;
ParametersWithIV parametersWithIV;
if (iv2 != 0)
{
byte[] array3 = new byte[iv2.Length];
if (!Arrays.AreEqual(iv2, array3))
{
ICipherParameters cipherParameters4;
parametersWithIV = new ParametersWithIV(cipherParameters4, iv2);
}
}
IL_29A:
int length = array2.Length;
int num3 = 0;
Array.Clear(array2, num3, length);
return PbeUtilities.FixDesParity(num, parametersWithIV);
}
// Token: 0x0600A0EC RID: 41196 RVA: 0x00217ED0 File Offset: 0x002160D0
[Token(Token = "0x600A0EC")]
[Address(RVA = "0x5DFFD0", Offset = "0x5DEFD0", VA = "0x1805DFFD0")]
public static object CreateEngine(DerObjectIdentifier algorithmOid)
{
return PbeUtilities.CreateEngine(algorithmOid.identifier);
}
// Token: 0x0600A0ED RID: 41197 RVA: 0x00217EF0 File Offset: 0x002160F0
[Token(Token = "0x600A0ED")]
[Address(RVA = "0x5E0030", Offset = "0x5DF030", VA = "0x1805E0030")]
public static object CreateEngine(AlgorithmIdentifier algID)
{
Asn1Object asn1Object = algID.ToAsn1Object();
bool flag;
if (!flag)
{
object obj;
return obj;
}
Asn1Object asn1Object2 = PbeS2Parameters.GetInstance(algID.ObjectID.ToAsn1Object()).scheme.ToAsn1Object();
throw new NullReferenceException();
}
// Token: 0x0600A0EE RID: 41198 RVA: 0x00217F2C File Offset: 0x0021612C
[Token(Token = "0x600A0EE")]
[Address(RVA = "0x5DFB40", Offset = "0x5DEB40", VA = "0x1805DFB40")]
public static object CreateEngine(string algorithm)
{
string text;
int num;
do
{
IDictionary dictionary = PbeUtilities.algorithms;
text = Platform.ToUpperInvariant(algorithm);
num = 0;
}
while (text != 0 && text == 0);
if (!Platform.StartsWith(num, "PBEwithHmac"))
{
if (Platform.StartsWith(num, "PBEwithMD2") || Platform.StartsWith(num, "PBEwithMD5") || Platform.StartsWith(num, "PBEwithSHA-1") || Platform.StartsWith(num, "PBEwithSHA-256"))
{
if (Platform.EndsWith(num, "AES-CBC-BC") || Platform.EndsWith(num, "AES-CBC-OPENSSL"))
{
goto IL_E9;
}
if (Platform.EndsWith(num, "DES-CBC"))
{
goto IL_DD;
}
if (Platform.EndsWith(num, "DESEDE-CBC"))
{
goto IL_D1;
}
if (Platform.EndsWith(num, "RC2-CBC"))
{
goto IL_C5;
}
if (!Platform.EndsWith(num, "RC4"))
{
}
}
IBufferedCipher cipher = CipherUtilities.GetCipher("RC4");
IL_C5:
IBufferedCipher cipher2 = CipherUtilities.GetCipher("RC2/CBC");
IL_D1:
IBufferedCipher cipher3 = CipherUtilities.GetCipher("DESEDE/CBC");
IL_DD:
IBufferedCipher cipher4 = CipherUtilities.GetCipher("DES/CBC");
IL_E9:
IBufferedCipher cipher5 = CipherUtilities.GetCipher("AES/CBC");
}
string text2;
IMac mac = MacUtilities.GetMac("HMAC/" + text2);
throw new NullReferenceException();
}
// Token: 0x0600A0EF RID: 41199 RVA: 0x0021804C File Offset: 0x0021624C
[Token(Token = "0x600A0EF")]
[Address(RVA = "0x5E1850", Offset = "0x5E0850", VA = "0x1805E1850")]
public static string GetEncodingName(DerObjectIdentifier oid)
{
IDictionary dictionary = PbeUtilities.algorithms;
throw new NullReferenceException();
}
// Token: 0x0600A0F0 RID: 41200 RVA: 0x00218064 File Offset: 0x00216264
[Token(Token = "0x600A0F0")]
[Address(RVA = "0x5E0170", Offset = "0x5DF170", VA = "0x1805E0170")]
private static ICipherParameters FixDesParity(string mechanism, ICipherParameters parameters)
{
while (Platform.EndsWith(mechanism, "DES-CBC") || Platform.EndsWith(mechanism, "DESEDE-CBC"))
{
byte[] array;
if (parameters == 0)
{
if (parameters == 0 || parameters == 0)
{
continue;
}
DesParameters.SetOddParity(array);
KeyParameter keyParameter = new KeyParameter(array);
}
byte b = array[33];
ICipherParameters cipherParameters;
byte[] array2;
ParametersWithIV parametersWithIV = new ParametersWithIV(cipherParameters, array2);
throw new NullReferenceException();
}
return parameters;
}
// Token: 0x04006B9C RID: 27548
[Token(Token = "0x4006B9C")]
private const string Pkcs5S1 = "Pkcs5S1";
// Token: 0x04006B9D RID: 27549
[Token(Token = "0x4006B9D")]
private const string Pkcs5S2 = "Pkcs5S2";
// Token: 0x04006B9E RID: 27550
[Token(Token = "0x4006B9E")]
private const string Pkcs12 = "Pkcs12";
// Token: 0x04006B9F RID: 27551
[Token(Token = "0x4006B9F")]
private const string OpenSsl = "OpenSsl";
// Token: 0x04006BA0 RID: 27552
[Token(Token = "0x4006BA0")]
private static readonly IDictionary algorithms;
// Token: 0x04006BA1 RID: 27553
[Token(Token = "0x4006BA1")]
private static readonly IDictionary algorithmType;
// Token: 0x04006BA2 RID: 27554
[Token(Token = "0x4006BA2")]
private static readonly IDictionary oids;
}
}
@@ -0,0 +1,146 @@
using System;
using System.IO;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Pkcs;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A91 RID: 6801
[Token(Token = "0x2001A91")]
public sealed class PrivateKeyFactory
{
// Token: 0x0600A0F1 RID: 41201 RVA: 0x002180D0 File Offset: 0x002162D0
[Token(Token = "0x600A0F1")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private PrivateKeyFactory()
{
}
// Token: 0x0600A0F2 RID: 41202 RVA: 0x002180E4 File Offset: 0x002162E4
[Token(Token = "0x600A0F2")]
[Address(RVA = "0x5E5B80", Offset = "0x5E4B80", VA = "0x1805E5B80")]
public static AsymmetricKeyParameter CreateKey(byte[] privateKeyInfoData)
{
return PrivateKeyFactory.CreateKey(PrivateKeyInfo.GetInstance(Asn1Object.FromByteArray(privateKeyInfoData)));
}
// Token: 0x0600A0F3 RID: 41203 RVA: 0x00218104 File Offset: 0x00216304
[Token(Token = "0x600A0F3")]
[Address(RVA = "0x5E5BB0", Offset = "0x5E4BB0", VA = "0x1805E5BB0")]
public static AsymmetricKeyParameter CreateKey(Stream inStr)
{
return PrivateKeyFactory.CreateKey(PrivateKeyInfo.GetInstance(Asn1Object.FromStream(inStr)));
}
// Token: 0x0600A0F4 RID: 41204 RVA: 0x00218124 File Offset: 0x00216324
[Token(Token = "0x600A0F4")]
[Address(RVA = "0x5E4C00", Offset = "0x5E3C00", VA = "0x1805E4C00")]
public static AsymmetricKeyParameter CreateKey(PrivateKeyInfo keyInfo)
{
/*
An exception occurred when decompiling this method (0600A0F4)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.AsymmetricKeyParameter BestHTTP.SecureProtocol.Org.BouncyCastle.Security.PrivateKeyFactory::CreateKey(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs.PrivateKeyInfo)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_2D9:
stloc:ArgumentException(var_91_2E3, newobj:ArgumentException(ArgumentException::.ctor, ldstr:string("Unrecognized curve OID for GostR3410x2001 private key")))
}
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: 0x0600A0F5 RID: 41205 RVA: 0x00218418 File Offset: 0x00216618
[Token(Token = "0x600A0F5")]
[Address(RVA = "0x5E5D40", Offset = "0x5E4D40", VA = "0x1805E5D40")]
private static byte[] GetRawKey(PrivateKeyInfo keyInfo, int expectedSize)
{
/*
An exception occurred when decompiling this method (0600A0F5)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Byte[] BestHTTP.SecureProtocol.Org.BouncyCastle.Security.PrivateKeyFactory::GetRawKey(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs.PrivateKeyInfo,System.Int32)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_1A:
stloc:SecurityUtilityException(var_1_24, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldstr:string("private key encoding has incorrect length")))
}
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: 0x0600A0F6 RID: 41206 RVA: 0x0021844C File Offset: 0x0021664C
[Token(Token = "0x600A0F6")]
[Address(RVA = "0x5E5C60", Offset = "0x5E4C60", VA = "0x1805E5C60")]
public static AsymmetricKeyParameter DecryptKey(char[] passPhrase, EncryptedPrivateKeyInfo encInfo)
{
return PrivateKeyFactory.CreateKey(PrivateKeyInfoFactory.CreatePrivateKeyInfo(passPhrase, encInfo));
}
// Token: 0x0600A0F7 RID: 41207 RVA: 0x00218468 File Offset: 0x00216668
[Token(Token = "0x600A0F7")]
[Address(RVA = "0x5E5BE0", Offset = "0x5E4BE0", VA = "0x1805E5BE0")]
public static AsymmetricKeyParameter DecryptKey(char[] passPhrase, byte[] encryptedPrivateKeyInfoData)
{
EncryptedPrivateKeyInfo instance = EncryptedPrivateKeyInfo.GetInstance(Asn1Object.FromByteArray(encryptedPrivateKeyInfoData));
return PrivateKeyFactory.CreateKey(PrivateKeyInfoFactory.CreatePrivateKeyInfo(passPhrase, instance));
}
// Token: 0x0600A0F8 RID: 41208 RVA: 0x00218490 File Offset: 0x00216690
[Token(Token = "0x600A0F8")]
[Address(RVA = "0x5E5C80", Offset = "0x5E4C80", VA = "0x1805E5C80")]
public static AsymmetricKeyParameter DecryptKey(char[] passPhrase, Stream encryptedPrivateKeyInfoStream)
{
EncryptedPrivateKeyInfo instance = EncryptedPrivateKeyInfo.GetInstance(Asn1Object.FromStream(encryptedPrivateKeyInfoStream));
return PrivateKeyFactory.CreateKey(PrivateKeyInfoFactory.CreatePrivateKeyInfo(passPhrase, instance));
}
// Token: 0x0600A0F9 RID: 41209 RVA: 0x002184B8 File Offset: 0x002166B8
[Token(Token = "0x600A0F9")]
[Address(RVA = "0x5E5C20", Offset = "0x5E4C20", VA = "0x1805E5C20")]
private static AsymmetricKeyParameter DecryptKey(char[] passPhrase, Asn1Object asn1Object)
{
EncryptedPrivateKeyInfo instance = EncryptedPrivateKeyInfo.GetInstance(asn1Object);
return PrivateKeyFactory.CreateKey(PrivateKeyInfoFactory.CreatePrivateKeyInfo(passPhrase, instance));
}
// Token: 0x0600A0FA RID: 41210 RVA: 0x002184D8 File Offset: 0x002166D8
[Token(Token = "0x600A0FA")]
[Address(RVA = "0x5E5D00", Offset = "0x5E4D00", VA = "0x1805E5D00")]
public static byte[] EncryptKey(DerObjectIdentifier algorithm, char[] passPhrase, byte[] salt, int iterationCount, AsymmetricKeyParameter key)
{
EncryptedPrivateKeyInfo encryptedPrivateKeyInfo;
return encryptedPrivateKeyInfo.GetEncoded();
}
// Token: 0x0600A0FB RID: 41211 RVA: 0x002184F4 File Offset: 0x002166F4
[Token(Token = "0x600A0FB")]
[Address(RVA = "0x5E5CC0", Offset = "0x5E4CC0", VA = "0x1805E5CC0")]
public static byte[] EncryptKey(string algorithm, char[] passPhrase, byte[] salt, int iterationCount, AsymmetricKeyParameter key)
{
EncryptedPrivateKeyInfo encryptedPrivateKeyInfo;
return encryptedPrivateKeyInfo.GetEncoded();
}
}
}
@@ -0,0 +1,113 @@
using System;
using System.IO;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Parameters;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Math;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A92 RID: 6802
[Token(Token = "0x2001A92")]
public sealed class PublicKeyFactory
{
// Token: 0x0600A0FC RID: 41212 RVA: 0x00218510 File Offset: 0x00216710
[Token(Token = "0x600A0FC")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private PublicKeyFactory()
{
}
// Token: 0x0600A0FD RID: 41213 RVA: 0x00218524 File Offset: 0x00216724
[Token(Token = "0x600A0FD")]
[Address(RVA = "0x5E72A0", Offset = "0x5E62A0", VA = "0x1805E72A0")]
public static AsymmetricKeyParameter CreateKey(byte[] keyInfoData)
{
return PublicKeyFactory.CreateKey(SubjectPublicKeyInfo.GetInstance(Asn1Object.FromByteArray(keyInfoData)));
}
// Token: 0x0600A0FE RID: 41214 RVA: 0x00218544 File Offset: 0x00216744
[Token(Token = "0x600A0FE")]
[Address(RVA = "0x5E5E00", Offset = "0x5E4E00", VA = "0x1805E5E00")]
public static AsymmetricKeyParameter CreateKey(Stream inStr)
{
return PublicKeyFactory.CreateKey(SubjectPublicKeyInfo.GetInstance(Asn1Object.FromStream(inStr)));
}
// Token: 0x0600A0FF RID: 41215 RVA: 0x0000220F File Offset: 0x0000040F
[Token(Token = "0x600A0FF")]
[Address(RVA = "0x5E5E30", Offset = "0x5E4E30", VA = "0x1805E5E30")]
public static AsymmetricKeyParameter CreateKey(SubjectPublicKeyInfo keyInfo)
{
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
}
// Token: 0x0600A100 RID: 41216 RVA: 0x00218564 File Offset: 0x00216764
[Token(Token = "0x600A100")]
[Address(RVA = "0x5E72D0", Offset = "0x5E62D0", VA = "0x1805E72D0")]
private static byte[] GetRawKey(SubjectPublicKeyInfo keyInfo, int expectedSize)
{
/*
An exception occurred when decompiling this method (0600A100)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Byte[] BestHTTP.SecureProtocol.Org.BouncyCastle.Security.PublicKeyFactory::GetRawKey(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509.SubjectPublicKeyInfo,System.Int32)
---> System.Exception: Basic block has to end with unconditional control flow.
{
Block_0:
stloc:string(var_0_0B, callvirt:string(DerBitString::GetString, ldfld:DerBitString(SubjectPublicKeyInfo::keyData, ldloc:SubjectPublicKeyInfo(keyInfo))))
stloc:SecurityUtilityException(var_1_16, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldstr:string("public key encoding has incorrect length")))
}
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: 0x0600A101 RID: 41217 RVA: 0x00218588 File Offset: 0x00216788
[Token(Token = "0x600A101")]
[Address(RVA = "0x5E7370", Offset = "0x5E6370", VA = "0x1805E7370")]
private static bool IsPkcsDHParam(Asn1Sequence seq)
{
Asn1Encodable asn1Encodable;
if (asn1Encodable != (ulong)2L)
{
Asn1SequenceParser parser = seq.Parser;
Asn1SequenceParser parser2 = seq.Parser;
DerInteger derInteger;
BigInteger value = derInteger.Value;
DerInteger derInteger2;
BigInteger bigInteger = BigInteger.ValueOf((long)derInteger2.Value.BitLength);
return value.CompareTo(bigInteger) <= 0;
}
return true;
}
// Token: 0x0600A102 RID: 41218 RVA: 0x002185E0 File Offset: 0x002167E0
[Token(Token = "0x600A102")]
[Address(RVA = "0x5E74E0", Offset = "0x5E64E0", VA = "0x1805E74E0")]
private static DHPublicKeyParameters ReadPkcsDHParam(DerObjectIdentifier algOid, BigInteger y, Asn1Sequence seq)
{
DHParameter dhparameter = new DHParameter(seq);
BigInteger l = dhparameter.L;
if (l == 0)
{
}
int intValue = l.IntValue;
BigInteger p = dhparameter.P;
BigInteger g = dhparameter.G;
int num;
DHParameters dhparameters = new DHParameters(p, g, num, intValue);
num = 0;
return new DHPublicKeyParameters(y, dhparameters, algOid);
}
}
}
@@ -0,0 +1,312 @@
using System;
using System.ComponentModel;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Prng;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A93 RID: 6803
[Token(Token = "0x2001A93")]
public class SecureRandom : Random
{
// Token: 0x0600A103 RID: 41219 RVA: 0x00218634 File Offset: 0x00216834
[Token(Token = "0x600A103")]
[Address(RVA = "0x5E7DD0", Offset = "0x5E6DD0", VA = "0x1805E7DD0")]
private static long NextCounterValue()
{
long num;
return num;
}
// Token: 0x170019A4 RID: 6564
// (get) Token: 0x0600A104 RID: 41220 RVA: 0x00218644 File Offset: 0x00216844
[Token(Token = "0x170019A4")]
private static SecureRandom Master
{
[Token(Token = "0x600A104")]
[Address(RVA = "0x5E85E0", Offset = "0x5E75E0", VA = "0x1805E85E0")]
get
{
return SecureRandom.master;
}
}
// Token: 0x0600A105 RID: 41221 RVA: 0x00218658 File Offset: 0x00216858
[Token(Token = "0x600A105")]
[Address(RVA = "0x5E7600", Offset = "0x5E6600", VA = "0x1805E7600")]
private static DigestRandomGenerator CreatePrng(string digestName, bool autoSeed)
{
IDigest digest = DigestUtilities.GetDigest(digestName);
if (digest != 0)
{
DigestRandomGenerator digestRandomGenerator = new DigestRandomGenerator(digest);
if (autoSeed)
{
long num;
digestRandomGenerator.AddSeedMaterial(num);
byte[] array;
digestRandomGenerator.AddSeedMaterial(array);
}
return digestRandomGenerator;
}
throw new NullReferenceException();
}
// Token: 0x0600A106 RID: 41222 RVA: 0x00218690 File Offset: 0x00216890
[Token(Token = "0x600A106")]
[Address(RVA = "0x5E7B80", Offset = "0x5E6B80", VA = "0x1805E7B80")]
public static byte[] GetNextBytes(SecureRandom secureRandom, int length)
{
byte[] array = new byte[length];
double num = secureRandom.NextDouble();
return array;
}
// Token: 0x0600A107 RID: 41223 RVA: 0x002186B4 File Offset: 0x002168B4
[Token(Token = "0x600A107")]
[Address(RVA = "0x5E7880", Offset = "0x5E6880", VA = "0x1805E7880")]
public static SecureRandom GetInstance(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A107)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SecureRandom BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SecureRandom::GetInstance(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_4B:
stloc:ArgumentException(var_7_60, newobj:ArgumentException(ArgumentException::.ctor, call:string(string::Concat, ldstr:string("Unrecognised PRNG algorithm: "), ldloc:string(algorithm)), ldstr:string("algorithm")))
}
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: 0x0600A108 RID: 41224 RVA: 0x00218724 File Offset: 0x00216924
[Token(Token = "0x600A108")]
[Address(RVA = "0x5E7A20", Offset = "0x5E6A20", VA = "0x1805E7A20")]
public static SecureRandom GetInstance(string algorithm, bool autoSeed)
{
/*
An exception occurred when decompiling this method (0600A108)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SecureRandom BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SecureRandom::GetInstance(System.String,System.Boolean)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_48:
stloc:ArgumentException(var_6_5D, newobj:ArgumentException(ArgumentException::.ctor, call:string(string::Concat, ldstr:string("Unrecognised PRNG algorithm: "), ldloc:string(algorithm)), ldstr:string("algorithm")))
}
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: 0x0600A109 RID: 41225 RVA: 0x00218790 File Offset: 0x00216990
[Token(Token = "0x600A109")]
[Address(RVA = "0x5E7BF0", Offset = "0x5E6BF0", VA = "0x1805E7BF0")]
[Obsolete]
public static byte[] GetSeed(int length)
{
SecureRandom secureRandom = SecureRandom.master;
byte[] array = new byte[length];
double num = secureRandom.NextDouble();
return array;
}
// Token: 0x0600A10A RID: 41226 RVA: 0x002187B8 File Offset: 0x002169B8
[Token(Token = "0x600A10A")]
[Address(RVA = "0x5E8560", Offset = "0x5E7560", VA = "0x1805E8560")]
public SecureRandom()
{
DigestRandomGenerator digestRandomGenerator = SecureRandom.CreatePrng("SHA256", true);
int num = 0;
base..ctor(num);
this.generator = digestRandomGenerator;
}
// Token: 0x0600A10B RID: 41227 RVA: 0x002187E4 File Offset: 0x002169E4
[Token(Token = "0x600A10B")]
[Address(RVA = "0x5E8450", Offset = "0x5E7450", VA = "0x1805E8450")]
[Obsolete]
public SecureRandom(byte[] seed)
{
IDigest digest = DigestUtilities.GetDigest("SHA1");
if (digest != 0)
{
DigestRandomGenerator digestRandomGenerator = new DigestRandomGenerator(digest);
}
int num = 0;
int num2 = 0;
base..ctor(num2);
this.generator = num;
((IEditableObject)this).BeginEdit();
}
// Token: 0x0600A10C RID: 41228 RVA: 0x00218820 File Offset: 0x00216A20
[Token(Token = "0x600A10C")]
[Address(RVA = "0x5E8420", Offset = "0x5E7420", VA = "0x1805E8420")]
public SecureRandom(IRandomGenerator generator)
{
int num = 0;
base..ctor(num);
this.generator = generator;
}
// Token: 0x0600A10D RID: 41229 RVA: 0x00218840 File Offset: 0x00216A40
[Token(Token = "0x600A10D")]
[Address(RVA = "0x5E7780", Offset = "0x5E6780", VA = "0x1805E7780", Slot = "10")]
public virtual byte[] GenerateSeed(int length)
{
SecureRandom secureRandom = SecureRandom.master;
byte[] array = new byte[length];
double num = secureRandom.NextDouble();
return array;
}
// Token: 0x0600A10E RID: 41230 RVA: 0x00218868 File Offset: 0x00216A68
[Token(Token = "0x600A10E")]
[Address(RVA = "0x5E82C0", Offset = "0x5E72C0", VA = "0x1805E82C0", Slot = "11")]
public virtual void SetSeed(byte[] seed)
{
IRandomGenerator randomGenerator = this.generator;
throw new NullReferenceException();
}
// Token: 0x0600A10F RID: 41231 RVA: 0x00218884 File Offset: 0x00216A84
[Token(Token = "0x600A10F")]
[Address(RVA = "0x5E8200", Offset = "0x5E7200", VA = "0x1805E8200", Slot = "12")]
public virtual void SetSeed(long seed)
{
IRandomGenerator randomGenerator = this.generator;
int num = 0;
num += num;
num++;
randomGenerator.AddSeedMaterial(seed);
}
// Token: 0x0600A110 RID: 41232 RVA: 0x0000220F File Offset: 0x0000040F
[Token(Token = "0x600A110")]
[Address(RVA = "0x5E81E0", Offset = "0x5E71E0", VA = "0x1805E81E0", Slot = "5")]
public override int Next()
{
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
}
// Token: 0x0600A111 RID: 41233 RVA: 0x002188B0 File Offset: 0x00216AB0
[Token(Token = "0x600A111")]
[Address(RVA = "0x5E80F0", Offset = "0x5E70F0", VA = "0x1805E80F0", Slot = "7")]
public override int Next(int maxValue)
{
int num = maxValue - 1;
if (maxValue != num)
{
}
return 0;
}
// Token: 0x0600A112 RID: 41234 RVA: 0x002188D8 File Offset: 0x00216AD8
[Token(Token = "0x600A112")]
[Address(RVA = "0x5E8010", Offset = "0x5E7010", VA = "0x1805E8010", Slot = "6")]
public override int Next(int minValue, int maxValue)
{
if (maxValue > minValue)
{
int num;
num += minValue;
return num;
}
return minValue;
}
// Token: 0x0600A113 RID: 41235 RVA: 0x002188FC File Offset: 0x00216AFC
[Token(Token = "0x600A113")]
[Address(RVA = "0x5E7CF0", Offset = "0x5E6CF0", VA = "0x1805E7CF0", Slot = "9")]
public override void NextBytes(byte[] buf)
{
IRandomGenerator randomGenerator = this.generator;
throw new NullReferenceException();
}
// Token: 0x0600A114 RID: 41236 RVA: 0x00218918 File Offset: 0x00216B18
[Token(Token = "0x600A114")]
[Address(RVA = "0x5E7D50", Offset = "0x5E6D50", VA = "0x1805E7D50", Slot = "13")]
public virtual void NextBytes(byte[] buf, int off, int len)
{
IRandomGenerator randomGenerator = this.generator;
}
// Token: 0x0600A115 RID: 41237 RVA: 0x00218934 File Offset: 0x00216B34
[Token(Token = "0x600A115")]
[Address(RVA = "0x5E7E30", Offset = "0x5E6E30", VA = "0x1805E7E30", Slot = "8")]
public override double NextDouble()
{
return Convert.ToDouble((ulong)this.NextInt());
}
// Token: 0x0600A116 RID: 41238 RVA: 0x0021894C File Offset: 0x00216B4C
[Token(Token = "0x600A116")]
[Address(RVA = "0x5E7EE0", Offset = "0x5E6EE0", VA = "0x1805E7EE0", Slot = "14")]
public virtual int NextInt()
{
byte[] array = new byte[4];
double num = this.NextDouble();
int length = array.Length;
byte b = array[0];
throw new NullReferenceException();
}
// Token: 0x0600A117 RID: 41239 RVA: 0x0000220F File Offset: 0x0000040F
[Token(Token = "0x600A117")]
[Address(RVA = "0x5E7FC0", Offset = "0x5E6FC0", VA = "0x1805E7FC0", Slot = "15")]
public virtual long NextLong()
{
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
}
// Token: 0x0600A118 RID: 41240 RVA: 0x0021897C File Offset: 0x00216B7C
// Note: this type is marked as 'beforefieldinit'.
[Token(Token = "0x600A118")]
[Address(RVA = "0x5E8320", Offset = "0x5E7320", VA = "0x1805E8320")]
static SecureRandom()
{
CryptoApiRandomGenerator cryptoApiRandomGenerator = new CryptoApiRandomGenerator();
int num;
SecureRandom secureRandom = new SecureRandom(num);
num = 0;
secureRandom.generator = cryptoApiRandomGenerator;
SecureRandom.master = secureRandom;
}
// Token: 0x04006BA3 RID: 27555
[Token(Token = "0x4006BA3")]
private static long counter = Times.NanoTime();
// Token: 0x04006BA4 RID: 27556
[Token(Token = "0x4006BA4")]
private static readonly SecureRandom master;
// Token: 0x04006BA5 RID: 27557
[FieldOffset(Offset = "0x20")]
[Token(Token = "0x4006BA5")]
protected readonly IRandomGenerator generator;
// Token: 0x04006BA6 RID: 27558
[Token(Token = "0x4006BA6")]
private static readonly double DoubleScale;
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A94 RID: 6804
[Token(Token = "0x2001A94")]
[Serializable]
public class SecurityUtilityException : Exception
{
// Token: 0x0600A119 RID: 41241 RVA: 0x002189B4 File Offset: 0x00216BB4
[Token(Token = "0x600A119")]
[Address(RVA = "0x5E8790", Offset = "0x5E7790", VA = "0x1805E8790")]
public SecurityUtilityException()
{
}
// Token: 0x0600A11A RID: 41242 RVA: 0x002189C8 File Offset: 0x00216BC8
[Token(Token = "0x600A11A")]
[Address(RVA = "0x5E8720", Offset = "0x5E7720", VA = "0x1805E8720")]
public SecurityUtilityException(string message)
: base(message)
{
}
// Token: 0x0600A11B RID: 41243 RVA: 0x002189DC File Offset: 0x00216BDC
[Token(Token = "0x600A11B")]
[Address(RVA = "0x5E86A0", Offset = "0x5E76A0", VA = "0x1805E86A0")]
public SecurityUtilityException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,34 @@
using System;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A95 RID: 6805
[Token(Token = "0x2001A95")]
[Serializable]
public class SignatureException : GeneralSecurityException
{
// Token: 0x0600A11C RID: 41244 RVA: 0x002189F4 File Offset: 0x00216BF4
[Token(Token = "0x600A11C")]
[Address(RVA = "0x5DB0F0", Offset = "0x5DA0F0", VA = "0x1805DB0F0")]
public SignatureException()
{
}
// Token: 0x0600A11D RID: 41245 RVA: 0x00218A08 File Offset: 0x00216C08
[Token(Token = "0x600A11D")]
[Address(RVA = "0x5DB0E0", Offset = "0x5DA0E0", VA = "0x1805DB0E0")]
public SignatureException(string message)
: base(message)
{
}
// Token: 0x0600A11E RID: 41246 RVA: 0x00218A1C File Offset: 0x00216C1C
[Token(Token = "0x600A11E")]
[Address(RVA = "0x5DB0D0", Offset = "0x5DA0D0", VA = "0x1805DB0D0")]
public SignatureException(string message, Exception exception)
: base(message, exception)
{
}
}
}
@@ -0,0 +1,308 @@
using System;
using System.Collections;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Parameters;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A96 RID: 6806
[Token(Token = "0x2001A96")]
public sealed class SignerUtilities
{
// Token: 0x0600A11F RID: 41247 RVA: 0x00218A34 File Offset: 0x00216C34
[Token(Token = "0x600A11F")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private SignerUtilities()
{
}
// Token: 0x0600A120 RID: 41248 RVA: 0x00218A48 File Offset: 0x00216C48
[Token(Token = "0x600A120")]
[Address(RVA = "0x5E9E90", Offset = "0x5E8E90", VA = "0x1805E9E90")]
static SignerUtilities()
{
/*
An exception occurred when decompiling this method (0600A120)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SignerUtilities::.cctor()
---> System.Exception: Basic block has to end with unconditional control flow.
{
Block_0:
stloc:IDictionary(var_1_07, call:IDictionary(Platform::CreateHashtable))
stsfld:IDictionary(SignerUtilities::algorithms, ldloc:IDictionary(var_1_07))
stsfld:IDictionary(SignerUtilities::oids, call:IDictionary(Platform::CreateHashtable))
stloc:IDictionary(var_3_1F, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_5_25, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_7_2C, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_8_33, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD2WithRsaEncryption))
stloc:IDictionary(var_10_3A, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_12_41, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_14_48, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_15_4F, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD4WithRsaEncryption))
stloc:IDictionary(var_17_56, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_18_5D, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::MD4WithRsa))
stloc:IDictionary(var_20_64, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_21_6B, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::MD4WithRsaEncryption))
stloc:IDictionary(var_23_72, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_25_79, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_27_80, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_28_87, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::MD5WithRsaEncryption))
stloc:IDictionary(var_30_8E, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_31_95, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::MD5WithRsa))
stloc:IDictionary(var_33_9C, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_35_A3, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_37_AA, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_39_B1, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_40_B8, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::Sha1WithRsaEncryption))
stloc:IDictionary(var_42_BF, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_43_C6, ldsfld:DerObjectIdentifier(OiwObjectIdentifiers::Sha1WithRsa))
stloc:IDictionary(var_45_CD, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_47_D4, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_49_DB, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_50_E2, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::Sha224WithRsaEncryption))
stloc:IDictionary(var_52_E9, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_54_F0, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_56_F7, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_58_FE, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_59_105, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::Sha256WithRsaEncryption))
stloc:IDictionary(var_61_10C, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_63_113, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_65_11A, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_67_121, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_68_128, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::Sha384WithRsaEncryption))
stloc:IDictionary(var_70_12F, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_72_136, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_74_13D, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_76_144, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_77_14B, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::Sha512WithRsaEncryption))
stloc:IDictionary(var_79_152, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_81_159, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_83_160, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_85_167, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_86_16E, ldsfld:DerObjectIdentifier(PkcsObjectIdentifiers::IdRsassaPss))
stloc:IDictionary(var_88_175, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_90_17C, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_92_183, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_94_18A, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_96_191, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_98_198, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_100_19F, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_102_1A6, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_104_1AD, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_106_1B4, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_108_1BB, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_110_1C2, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_112_1C9, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_114_1D0, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_116_1D7, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_118_1DE, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_120_1E5, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_122_1EC, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_124_1F3, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_126_1FA, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_128_201, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_130_208, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_132_20F, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_134_216, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_135_21D, ldsfld:DerObjectIdentifier(TeleTrusTObjectIdentifiers::RsaSignatureWithRipeMD128))
stloc:IDictionary(var_137_224, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_139_22B, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_141_232, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_142_239, ldsfld:DerObjectIdentifier(TeleTrusTObjectIdentifiers::RsaSignatureWithRipeMD160))
stloc:IDictionary(var_144_240, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_146_247, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_148_24E, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:DerObjectIdentifier(var_149_255, ldsfld:DerObjectIdentifier(TeleTrusTObjectIdentifiers::RsaSignatureWithRipeMD256))
stloc:IDictionary(var_151_25C, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_153_263, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_155_26A, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_157_271, ldsfld:IDictionary(SignerUtilities::algorithms))
stloc:IDictionary(var_159_278, ldsfld:IDictionary(SignerUtilities::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: 0x0600A121 RID: 41249 RVA: 0x00218CD0 File Offset: 0x00216ED0
[Token(Token = "0x600A121")]
[Address(RVA = "0x5E8B20", Offset = "0x5E7B20", VA = "0x1805E8B20")]
public static DerObjectIdentifier GetObjectIdentifier(string mechanism)
{
/*
An exception occurred when decompiling this method (0600A121)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.DerObjectIdentifier BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SignerUtilities::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: 0x170019A5 RID: 6565
// (get) Token: 0x0600A122 RID: 41250 RVA: 0x00218D18 File Offset: 0x00216F18
[Token(Token = "0x170019A5")]
public static ICollection Algorithms
{
[Token(Token = "0x600A122")]
[Address(RVA = "0x5EEEB0", Offset = "0x5EDEB0", VA = "0x1805EEEB0")]
get
{
IDictionary dictionary = SignerUtilities.oids;
throw new NullReferenceException();
}
}
// Token: 0x0600A123 RID: 41251 RVA: 0x00218D30 File Offset: 0x00216F30
[Token(Token = "0x600A123")]
[Address(RVA = "0x5E8A10", Offset = "0x5E7A10", VA = "0x1805E8A10")]
public static Asn1Encodable GetDefaultX509Parameters(DerObjectIdentifier id)
{
return SignerUtilities.GetDefaultX509Parameters(id.identifier);
}
// Token: 0x0600A124 RID: 41252 RVA: 0x00218D50 File Offset: 0x00216F50
[Token(Token = "0x600A124")]
[Address(RVA = "0x5E87F0", Offset = "0x5E77F0", VA = "0x1805E87F0")]
public static Asn1Encodable GetDefaultX509Parameters(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A124)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Asn1Encodable BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SignerUtilities::GetDefaultX509Parameters(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_49:
stloc:ArgumentNullException(var_5_53, newobj:ArgumentNullException(ArgumentNullException::.ctor, ldstr:string("algorithm")))
}
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: 0x0600A125 RID: 41253 RVA: 0x00218DB4 File Offset: 0x00216FB4
[Token(Token = "0x600A125")]
[Address(RVA = "0x5E8CD0", Offset = "0x5E7CD0", VA = "0x1805E8CD0")]
private static Asn1Encodable GetPssX509Parameters(string digestName)
{
DerObjectIdentifier objectIdentifier = DigestUtilities.GetObjectIdentifier(digestName);
DerNull instance = DerNull.Instance;
AlgorithmIdentifier algorithmIdentifier = new AlgorithmIdentifier(objectIdentifier, instance);
AlgorithmIdentifier algorithmIdentifier2 = new AlgorithmIdentifier(PkcsObjectIdentifiers.IdMgf1, algorithmIdentifier);
IDigest digest = DigestUtilities.GetDigest(digestName);
DerInteger derInteger = new DerInteger(1);
DerInteger derInteger2;
RsassaPssParameters rsassaPssParameters = new RsassaPssParameters(algorithmIdentifier, algorithmIdentifier2, derInteger2, derInteger);
throw new NullReferenceException();
}
// Token: 0x0600A126 RID: 41254 RVA: 0x00218E04 File Offset: 0x00217004
[Token(Token = "0x600A126")]
[Address(RVA = "0x5E9BA0", Offset = "0x5E8BA0", VA = "0x1805E9BA0")]
public static ISigner GetSigner(DerObjectIdentifier id)
{
return SignerUtilities.GetSigner(id.identifier);
}
// Token: 0x0600A127 RID: 41255 RVA: 0x00218E24 File Offset: 0x00217024
[Token(Token = "0x600A127")]
[Address(RVA = "0x5E8E90", Offset = "0x5E7E90", VA = "0x1805E8E90")]
public static ISigner GetSigner(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A127)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.ISigner BestHTTP.SecureProtocol.Org.BouncyCastle.Security.SignerUtilities::GetSigner(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_30D:
stloc:SecurityUtilityException(var_86_314, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, ldloc:string(var_85)))
}
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: 0x0600A128 RID: 41256 RVA: 0x00219148 File Offset: 0x00217348
[Token(Token = "0x600A128")]
[Address(RVA = "0x5E8A70", Offset = "0x5E7A70", VA = "0x1805E8A70")]
public static string GetEncodingName(DerObjectIdentifier oid)
{
IDictionary dictionary = SignerUtilities.algorithms;
throw new NullReferenceException();
}
// Token: 0x0600A129 RID: 41257 RVA: 0x00219160 File Offset: 0x00217360
[Token(Token = "0x600A129")]
[Address(RVA = "0x5E9D20", Offset = "0x5E8D20", VA = "0x1805E9D20")]
public static ISigner InitSigner(DerObjectIdentifier algorithmOid, bool forSigning, AsymmetricKeyParameter privateKey, SecureRandom random)
{
ISigner signer = SignerUtilities.GetSigner(algorithmOid.identifier);
if (random != 0)
{
ParametersWithRandom parametersWithRandom = new ParametersWithRandom(privateKey, random);
}
return signer;
}
// Token: 0x0600A12A RID: 41258 RVA: 0x0021918C File Offset: 0x0021738C
[Token(Token = "0x600A12A")]
[Address(RVA = "0x5E9C00", Offset = "0x5E8C00", VA = "0x1805E9C00")]
public static ISigner InitSigner(string algorithm, bool forSigning, AsymmetricKeyParameter privateKey, SecureRandom random)
{
ISigner signer = SignerUtilities.GetSigner(algorithm);
if (random != 0)
{
ParametersWithRandom parametersWithRandom = new ParametersWithRandom(privateKey, random);
}
return signer;
}
// Token: 0x04006BA7 RID: 27559
[Token(Token = "0x4006BA7")]
internal static readonly IDictionary algorithms;
// Token: 0x04006BA8 RID: 27560
[Token(Token = "0x4006BA8")]
internal static readonly IDictionary oids;
}
}
@@ -0,0 +1,223 @@
using System;
using System.Collections;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Kisa;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Nist;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Ntt;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Security
{
// Token: 0x02001A97 RID: 6807
[Token(Token = "0x2001A97")]
public sealed class WrapperUtilities
{
// Token: 0x0600A12B RID: 41259 RVA: 0x002191B4 File Offset: 0x002173B4
[Token(Token = "0x600A12B")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
private WrapperUtilities()
{
}
// Token: 0x0600A12C RID: 41260 RVA: 0x002191C8 File Offset: 0x002173C8
[Token(Token = "0x600A12C")]
[Address(RVA = "0x5F3C70", Offset = "0x5F2C70", VA = "0x1805F3C70")]
static WrapperUtilities()
{
IDictionary dictionary = Platform.CreateHashtable();
Enum arbitraryValue = Enums.GetArbitraryValue(typeof(WrapperUtilities.WrapAlgorithm));
DerObjectIdentifier idAes128Wrap = NistObjectIdentifiers.IdAes128Wrap;
DerObjectIdentifier idAes192Wrap = NistObjectIdentifiers.IdAes192Wrap;
DerObjectIdentifier idAes256Wrap = NistObjectIdentifiers.IdAes256Wrap;
DerObjectIdentifier idCamellia128Wrap = NttObjectIdentifiers.IdCamellia128Wrap;
DerObjectIdentifier idCamellia192Wrap = NttObjectIdentifiers.IdCamellia192Wrap;
DerObjectIdentifier idCamellia256Wrap = NttObjectIdentifiers.IdCamellia256Wrap;
DerObjectIdentifier idAlgCms3DesWrap = PkcsObjectIdentifiers.IdAlgCms3DesWrap;
DerObjectIdentifier idAlgCmsRC2Wrap = PkcsObjectIdentifiers.IdAlgCmsRC2Wrap;
DerObjectIdentifier idNpkiAppCmsSeedWrap = KisaObjectIdentifiers.IdNpkiAppCmsSeedWrap;
}
// Token: 0x0600A12D RID: 41261 RVA: 0x0021923C File Offset: 0x0021743C
[Token(Token = "0x600A12D")]
[Address(RVA = "0x5F3C10", Offset = "0x5F2C10", VA = "0x1805F3C10")]
public static IWrapper GetWrapper(DerObjectIdentifier oid)
{
return WrapperUtilities.GetWrapper(oid.identifier);
}
// Token: 0x0600A12E RID: 41262 RVA: 0x0021925C File Offset: 0x0021745C
[Token(Token = "0x600A12E")]
[Address(RVA = "0x5F3870", Offset = "0x5F2870", VA = "0x1805F3870")]
public static IWrapper GetWrapper(string algorithm)
{
/*
An exception occurred when decompiling this method (0600A12E)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IWrapper BestHTTP.SecureProtocol.Org.BouncyCastle.Security.WrapperUtilities::GetWrapper(System.String)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_94:
stloc:SecurityUtilityException(var_13_A9, newobj:SecurityUtilityException(SecurityUtilityException::.ctor, call:string(string::Concat, ldstr:string("Wrapper "), ldloc:string(algorithm), ldstr:string(" not recognised."))))
}
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: 0x0600A12F RID: 41263 RVA: 0x00219314 File Offset: 0x00217514
[Token(Token = "0x600A12F")]
[Address(RVA = "0x5F37C0", Offset = "0x5F27C0", VA = "0x1805F37C0")]
public static string GetAlgorithmName(DerObjectIdentifier oid)
{
throw new NullReferenceException();
}
// Token: 0x04006BA9 RID: 27561
[Token(Token = "0x4006BA9")]
private static readonly IDictionary algorithms;
// Token: 0x02001A98 RID: 6808
[Token(Token = "0x2001A98")]
private enum WrapAlgorithm
{
// Token: 0x04006BAB RID: 27563
[Token(Token = "0x4006BAB")]
AESWRAP,
// Token: 0x04006BAC RID: 27564
[Token(Token = "0x4006BAC")]
CAMELLIAWRAP,
// Token: 0x04006BAD RID: 27565
[Token(Token = "0x4006BAD")]
DESEDEWRAP,
// Token: 0x04006BAE RID: 27566
[Token(Token = "0x4006BAE")]
RC2WRAP,
// Token: 0x04006BAF RID: 27567
[Token(Token = "0x4006BAF")]
SEEDWRAP,
// Token: 0x04006BB0 RID: 27568
[Token(Token = "0x4006BB0")]
DESEDERFC3211WRAP,
// Token: 0x04006BB1 RID: 27569
[Token(Token = "0x4006BB1")]
AESRFC3211WRAP,
// Token: 0x04006BB2 RID: 27570
[Token(Token = "0x4006BB2")]
CAMELLIARFC3211WRAP
}
// Token: 0x02001A99 RID: 6809
[Token(Token = "0x2001A99")]
private class BufferedCipherWrapper : IWrapper
{
// Token: 0x0600A130 RID: 41264 RVA: 0x00219328 File Offset: 0x00217528
[Token(Token = "0x600A130")]
[Address(RVA = "0x493D90", Offset = "0x492D90", VA = "0x180493D90")]
public BufferedCipherWrapper(IBufferedCipher cipher)
{
this.cipher = cipher;
}
// Token: 0x170019A6 RID: 6566
// (get) Token: 0x0600A131 RID: 41265 RVA: 0x00219344 File Offset: 0x00217544
[Token(Token = "0x170019A6")]
public string AlgorithmName
{
[Token(Token = "0x600A131")]
[Address(RVA = "0x5DA9A0", Offset = "0x5D99A0", VA = "0x1805DA9A0", Slot = "4")]
get
{
IBufferedCipher bufferedCipher = this.cipher;
int num = 0;
num += num;
num++;
return bufferedCipher.AlgorithmName;
}
}
// Token: 0x0600A132 RID: 41266 RVA: 0x00219378 File Offset: 0x00217578
[Token(Token = "0x600A132")]
[Address(RVA = "0x5DA7B0", Offset = "0x5D97B0", VA = "0x1805DA7B0", Slot = "5")]
public void Init(bool forWrapping, ICipherParameters parameters)
{
IBufferedCipher bufferedCipher = this.cipher;
this.forWrapping = forWrapping;
}
// Token: 0x0600A133 RID: 41267 RVA: 0x0021939C File Offset: 0x0021759C
[Token(Token = "0x600A133")]
[Address(RVA = "0x5DA8E0", Offset = "0x5D98E0", VA = "0x1805DA8E0", Slot = "6")]
public byte[] Wrap(byte[] input, int inOff, int length)
{
/*
An exception occurred when decompiling this method (0600A133)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Byte[] BestHTTP.SecureProtocol.Org.BouncyCastle.Security.WrapperUtilities/BufferedCipherWrapper::Wrap(System.Byte[],System.Int32,System.Int32)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_10:
stloc:InvalidOperationException(var_1_1A, newobj:InvalidOperationException(InvalidOperationException::.ctor, ldstr:string("Not initialised for wrapping")))
}
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: 0x0600A134 RID: 41268 RVA: 0x002193C4 File Offset: 0x002175C4
[Token(Token = "0x600A134")]
[Address(RVA = "0x5DA820", Offset = "0x5D9820", VA = "0x1805DA820", Slot = "7")]
public byte[] Unwrap(byte[] input, int inOff, int length)
{
/*
An exception occurred when decompiling this method (0600A134)
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Byte[] BestHTTP.SecureProtocol.Org.BouncyCastle.Security.WrapperUtilities/BufferedCipherWrapper::Unwrap(System.Byte[],System.Int32,System.Int32)
---> System.Exception: Basic block has to end with unconditional control flow.
{
IL_10:
stloc:InvalidOperationException(var_1_1A, newobj:InvalidOperationException(InvalidOperationException::.ctor, ldstr:string("Not initialised for unwrapping")))
}
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: 0x04006BB3 RID: 27571
[FieldOffset(Offset = "0x10")]
[Token(Token = "0x4006BB3")]
private readonly IBufferedCipher cipher;
// Token: 0x04006BB4 RID: 27572
[FieldOffset(Offset = "0x18")]
[Token(Token = "0x4006BB4")]
private bool forWrapping;
}
}
}