217 lines
12 KiB
C#
217 lines
12 KiB
C#
using System;
|
|
using System.Runtime.InteropServices;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Math;
|
|
using Cpp2IlInjected;
|
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509
|
|
{
|
|
// Token: 0x02001819 RID: 6169
|
|
[Token(Token = "0x2001819")]
|
|
[StructLayout(3)]
|
|
public class BasicConstraints : Asn1Encodable
|
|
{
|
|
// Token: 0x0600A632 RID: 42546 RVA: 0x0026A1A4 File Offset: 0x002683A4
|
|
[Token(Token = "0x600A632")]
|
|
[Address(RVA = "0x2AFEBE0", Offset = "0x2AFD5E0", VA = "0x182AFEBE0")]
|
|
public static BasicConstraints GetInstance(Asn1TaggedObject obj, bool explicitly)
|
|
{
|
|
return BasicConstraints.GetInstance(Asn1Sequence.GetInstance(obj, explicitly));
|
|
}
|
|
|
|
// Token: 0x0600A633 RID: 42547 RVA: 0x0026A1C0 File Offset: 0x002683C0
|
|
[Token(Token = "0x600A633")]
|
|
[Address(RVA = "0x2AFEC00", Offset = "0x2AFD600", VA = "0x182AFEC00")]
|
|
public static BasicConstraints GetInstance(object obj)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600A633)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509.BasicConstraints BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509.BasicConstraints::GetInstance(System.Object)
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{
|
|
IL_40:
|
|
stloc:string(var_9_46, call:string(Platform::GetTypeName, ldloc:object(obj)))
|
|
stloc:ArgumentException(var_10_5E, newobj:ArgumentException(ArgumentException::.ctor, call:string(string::Concat, ldstr:string("unknown object in factory: "), ldloc:string(var_9_46)), ldstr:string("obj")))
|
|
}
|
|
|
|
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: 0x0600A634 RID: 42548 RVA: 0x0026A22C File Offset: 0x0026842C
|
|
[Token(Token = "0x600A634")]
|
|
[Address(RVA = "0x2AFF2B0", Offset = "0x2AFDCB0", VA = "0x182AFF2B0")]
|
|
private BasicConstraints(Asn1Sequence seq)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600A634)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509.BasicConstraints::.ctor(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Asn1Sequence)
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{
|
|
IL_66:
|
|
stloc:ArgumentException(var_11_75, newobj:ArgumentException(ArgumentException::.ctor, ldstr:string("wrong sequence in constructor"), ldstr:string("seq")))
|
|
}
|
|
|
|
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.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: 0x0600A635 RID: 42549 RVA: 0x0026A2B0 File Offset: 0x002684B0
|
|
[Token(Token = "0x600A635")]
|
|
[Address(RVA = "0x2AFF510", Offset = "0x2AFDF10", VA = "0x182AFF510")]
|
|
public BasicConstraints(bool cA)
|
|
{
|
|
if (cA)
|
|
{
|
|
DerBoolean @true = DerBoolean.True;
|
|
this.cA = @true;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600A636 RID: 42550 RVA: 0x0026A2D4 File Offset: 0x002684D4
|
|
[Token(Token = "0x600A636")]
|
|
[Address(RVA = "0x2AFF470", Offset = "0x2AFDE70", VA = "0x182AFF470")]
|
|
public BasicConstraints(int pathLenConstraint)
|
|
{
|
|
DerBoolean @true = DerBoolean.True;
|
|
this.cA = @true;
|
|
DerInteger derInteger = new DerInteger(pathLenConstraint);
|
|
this.pathLenConstraint = derInteger;
|
|
}
|
|
|
|
// Token: 0x0600A637 RID: 42551 RVA: 0x0026A304 File Offset: 0x00268504
|
|
[Token(Token = "0x600A637")]
|
|
[Address(RVA = "0x2AFEE90", Offset = "0x2AFD890", VA = "0x182AFEE90")]
|
|
public bool IsCA()
|
|
{
|
|
DerBoolean derBoolean = this.cA;
|
|
if (derBoolean == 0)
|
|
{
|
|
}
|
|
return derBoolean.IsTrue;
|
|
}
|
|
|
|
// Token: 0x170019F4 RID: 6644
|
|
// (get) Token: 0x0600A638 RID: 42552 RVA: 0x0026A324 File Offset: 0x00268524
|
|
[Token(Token = "0x170019F4")]
|
|
public BigInteger PathLenConstraint
|
|
{
|
|
[Token(Token = "0x600A638")]
|
|
[Address(RVA = "0x2AFF590", Offset = "0x2AFDF90", VA = "0x182AFF590")]
|
|
get
|
|
{
|
|
DerInteger derInteger = this.pathLenConstraint;
|
|
if (derInteger == 0)
|
|
{
|
|
}
|
|
return derInteger.Value;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600A639 RID: 42553 RVA: 0x0026A344 File Offset: 0x00268544
|
|
[Token(Token = "0x600A639")]
|
|
[Address(RVA = "0x2AFEEB0", Offset = "0x2AFD8B0", VA = "0x182AFEEB0", Slot = "5")]
|
|
public override Asn1Object ToAsn1Object()
|
|
{
|
|
Asn1EncodableVector asn1EncodableVector;
|
|
if (this.cA != (ulong)0L)
|
|
{
|
|
Asn1Encodable[] array = new Asn1Encodable[1];
|
|
DerBoolean derBoolean = this.cA;
|
|
if (derBoolean != 0)
|
|
{
|
|
}
|
|
array[0] = derBoolean;
|
|
asn1EncodableVector.Add(array);
|
|
}
|
|
if (this.pathLenConstraint != (ulong)0L)
|
|
{
|
|
Asn1Encodable[] array2 = new Asn1Encodable[1];
|
|
DerInteger derInteger = this.pathLenConstraint;
|
|
if (derInteger != 0)
|
|
{
|
|
}
|
|
array2[0] = derInteger;
|
|
asn1EncodableVector.Add(array2);
|
|
}
|
|
DerSequence derSequence = new DerSequence(asn1EncodableVector);
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x0600A63A RID: 42554 RVA: 0x0026A3BC File Offset: 0x002685BC
|
|
[Token(Token = "0x600A63A")]
|
|
[Address(RVA = "0x2AFF060", Offset = "0x2AFDA60", VA = "0x182AFF060", Slot = "3")]
|
|
public override string ToString()
|
|
{
|
|
if (this.pathLenConstraint != (ulong)0L)
|
|
{
|
|
object[] array = new object[4];
|
|
if ("BasicConstraints: isCa(" != 0)
|
|
{
|
|
}
|
|
array[0] = "BasicConstraints: isCa(";
|
|
DerBoolean derBoolean = this.cA;
|
|
if (derBoolean == 0)
|
|
{
|
|
}
|
|
bool isTrue = derBoolean.IsTrue;
|
|
if (isTrue)
|
|
{
|
|
}
|
|
array[1] = isTrue;
|
|
if ("), pathLenConstraint = " != 0)
|
|
{
|
|
}
|
|
array[2] = "), pathLenConstraint = ";
|
|
BigInteger value = this.pathLenConstraint.Value;
|
|
if (value != 0)
|
|
{
|
|
}
|
|
array[3] = value;
|
|
return string.Concat(array);
|
|
}
|
|
DerBoolean derBoolean2 = this.cA;
|
|
if (derBoolean2 == 0)
|
|
{
|
|
}
|
|
bool isTrue2 = derBoolean2.IsTrue;
|
|
string text;
|
|
return text;
|
|
}
|
|
|
|
// Token: 0x04006C2B RID: 27691
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x4006C2B")]
|
|
private readonly DerBoolean cA;
|
|
|
|
// Token: 0x04006C2C RID: 27692
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x4006C2C")]
|
|
private readonly DerInteger pathLenConstraint;
|
|
}
|
|
}
|