oh dear
This commit is contained in:
@@ -0,0 +1,184 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.IO;
|
||||
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
|
||||
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
|
||||
using Cpp2IlInjected;
|
||||
|
||||
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Tls
|
||||
{
|
||||
// Token: 0x02001B02 RID: 6914
|
||||
[Token(Token = "0x2001B02")]
|
||||
public class Certificate
|
||||
{
|
||||
// Token: 0x0600AC05 RID: 44037 RVA: 0x00256E9C File Offset: 0x0025509C
|
||||
[Token(Token = "0x600AC05")]
|
||||
[Address(RVA = "0x18AADE0", Offset = "0x18A9BE0", VA = "0x1818AADE0")]
|
||||
public Certificate(X509CertificateStructure[] certificateList)
|
||||
{
|
||||
/*
|
||||
An exception occurred when decompiling this method (0600AC05)
|
||||
|
||||
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Tls.Certificate::.ctor(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509.X509CertificateStructure[])
|
||||
|
||||
---> System.Exception: Basic block has to end with unconditional control flow.
|
||||
{
|
||||
IL_12:
|
||||
stloc:ArgumentNullException(var_0_1C, newobj:ArgumentNullException(ArgumentNullException::.ctor, ldstr:string("certificateList")))
|
||||
}
|
||||
|
||||
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: 0x0600AC06 RID: 44038 RVA: 0x0000220F File Offset: 0x0000040F
|
||||
[Token(Token = "0x600AC06")]
|
||||
[Address(RVA = "0x51A270", Offset = "0x519070", VA = "0x18051A270", Slot = "4")]
|
||||
public virtual X509CertificateStructure[] GetCertificateList()
|
||||
{
|
||||
throw new AnalysisFailedException("CPP2IL failed to recover any usable IL for this method.");
|
||||
}
|
||||
|
||||
// Token: 0x0600AC07 RID: 44039 RVA: 0x00256EC8 File Offset: 0x002550C8
|
||||
[Token(Token = "0x600AC07")]
|
||||
[Address(RVA = "0x73C670", Offset = "0x73B470", VA = "0x18073C670", Slot = "5")]
|
||||
public virtual X509CertificateStructure GetCertificateAt(int index)
|
||||
{
|
||||
return this.mCertificateList[index];
|
||||
}
|
||||
|
||||
// Token: 0x17001B4C RID: 6988
|
||||
// (get) Token: 0x0600AC08 RID: 44040 RVA: 0x00256EE8 File Offset: 0x002550E8
|
||||
[Token(Token = "0x17001B4C")]
|
||||
public virtual int Length
|
||||
{
|
||||
[Token(Token = "0x600AC08")]
|
||||
[Address(RVA = "0x40DB30", Offset = "0x40C930", VA = "0x18040DB30", Slot = "6")]
|
||||
get
|
||||
{
|
||||
return this.mCertificateList.Length;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x17001B4D RID: 6989
|
||||
// (get) Token: 0x0600AC09 RID: 44041 RVA: 0x00256F08 File Offset: 0x00255108
|
||||
[Token(Token = "0x17001B4D")]
|
||||
public virtual bool IsEmpty
|
||||
{
|
||||
[Token(Token = "0x600AC09")]
|
||||
[Address(RVA = "0x40DB10", Offset = "0x40C910", VA = "0x18040DB10", Slot = "7")]
|
||||
get
|
||||
{
|
||||
return this.mCertificateList.Length == 0;
|
||||
}
|
||||
}
|
||||
|
||||
// Token: 0x0600AC0A RID: 44042 RVA: 0x00256F2C File Offset: 0x0025512C
|
||||
[Token(Token = "0x600AC0A")]
|
||||
[Address(RVA = "0x18AA540", Offset = "0x18A9340", VA = "0x1818AA540", Slot = "8")]
|
||||
public virtual void Encode(Stream output)
|
||||
{
|
||||
int num;
|
||||
do
|
||||
{
|
||||
num = 0;
|
||||
IList list = Platform.CreateArrayList(this.mCertificateList.Length);
|
||||
X509CertificateStructure[] array = this.mCertificateList;
|
||||
int length = array.Length;
|
||||
if (num < length)
|
||||
{
|
||||
X509CertificateStructure x509CertificateStructure = array[num];
|
||||
int num2 = 0;
|
||||
byte[] encoded = x509CertificateStructure.GetEncoded("DER");
|
||||
if (num < num2)
|
||||
{
|
||||
num += num;
|
||||
num++;
|
||||
}
|
||||
num += 3;
|
||||
num++;
|
||||
num += num;
|
||||
}
|
||||
TlsUtilities.CheckUint24(num);
|
||||
TlsUtilities.WriteUint24(num, output);
|
||||
if (num < list)
|
||||
{
|
||||
num += num;
|
||||
num++;
|
||||
}
|
||||
int num3 = 0;
|
||||
if (list != 0)
|
||||
{
|
||||
if (num < num3)
|
||||
{
|
||||
num += num;
|
||||
num++;
|
||||
}
|
||||
num += 19;
|
||||
num++;
|
||||
num += 19;
|
||||
}
|
||||
if (num != 0)
|
||||
{
|
||||
}
|
||||
}
|
||||
while (num != 0);
|
||||
}
|
||||
|
||||
// Token: 0x0600AC0B RID: 44043 RVA: 0x00256FE0 File Offset: 0x002551E0
|
||||
[Token(Token = "0x600AC0B")]
|
||||
[Address(RVA = "0x18AA8F0", Offset = "0x18A96F0", VA = "0x1818AA8F0")]
|
||||
public static Certificate Parse(Stream input)
|
||||
{
|
||||
/*
|
||||
An exception occurred when decompiling this method (0600AC0B)
|
||||
|
||||
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Tls.Certificate BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Tls.Certificate::Parse(System.IO.Stream)
|
||||
|
||||
---> System.Exception: Basic block has to end with unconditional control flow.
|
||||
{
|
||||
IL_D1:
|
||||
stloc:ArgumentNullException(var_15_DB, newobj:ArgumentNullException(ArgumentNullException::.ctor, ldstr:string("certificateList")))
|
||||
}
|
||||
|
||||
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: 0x0600AC0C RID: 44044 RVA: 0x002570CC File Offset: 0x002552CC
|
||||
[Token(Token = "0x600AC0C")]
|
||||
[Address(RVA = "0x18AA4C0", Offset = "0x18A92C0", VA = "0x1818AA4C0", Slot = "9")]
|
||||
protected virtual X509CertificateStructure[] CloneCertificateList()
|
||||
{
|
||||
X509CertificateStructure[] array = this.mCertificateList;
|
||||
throw new NullReferenceException();
|
||||
}
|
||||
|
||||
// Token: 0x04006D08 RID: 27912
|
||||
[Token(Token = "0x4006D08")]
|
||||
public static readonly Certificate EmptyChain = new Certificate(new X509CertificateStructure[0]);
|
||||
|
||||
// Token: 0x04006D09 RID: 27913
|
||||
[FieldOffset(Offset = "0x10")]
|
||||
[Token(Token = "0x4006D09")]
|
||||
protected readonly X509CertificateStructure[] mCertificateList;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user