258 lines
9.3 KiB
C#
258 lines
9.3 KiB
C#
using System;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
|
|
using Cpp2IlInjected;
|
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Ocsp
|
|
{
|
|
// Token: 0x02001EB1 RID: 7857
|
|
[Token(Token = "0x2001EB1")]
|
|
public class TbsRequest : Asn1Encodable
|
|
{
|
|
// Token: 0x0600C6AF RID: 50863 RVA: 0x002D6408 File Offset: 0x002D4608
|
|
[Token(Token = "0x600C6AF")]
|
|
[Address(RVA = "0x2BD5530", Offset = "0x2BD4330", VA = "0x182BD5530")]
|
|
public static TbsRequest GetInstance(Asn1TaggedObject obj, bool explicitly)
|
|
{
|
|
return TbsRequest.GetInstance(Asn1Sequence.GetInstance(obj, explicitly));
|
|
}
|
|
|
|
// Token: 0x0600C6B0 RID: 50864 RVA: 0x002D6424 File Offset: 0x002D4624
|
|
[Token(Token = "0x600C6B0")]
|
|
[Address(RVA = "0x2BD55A0", Offset = "0x2BD43A0", VA = "0x182BD55A0")]
|
|
public static TbsRequest GetInstance(object obj)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600C6B0)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Ocsp.TbsRequest BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Ocsp.TbsRequest::GetInstance(System.Object)
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{
|
|
IL_26:
|
|
stloc:string(var_6_2C, call:string(Platform::GetTypeName, ldloc:object(obj)))
|
|
stloc:ArgumentException(var_7_44, newobj:ArgumentException(ArgumentException::.ctor, call:string(string::Concat, ldstr:string("unknown object in factory: "), ldloc:string(var_6_2C)), 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: 0x0600C6B1 RID: 50865 RVA: 0x002D6478 File Offset: 0x002D4678
|
|
[Token(Token = "0x600C6B1")]
|
|
[Address(RVA = "0x2BD5F00", Offset = "0x2BD4D00", VA = "0x182BD5F00")]
|
|
public TbsRequest(GeneralName requestorName, Asn1Sequence requestList, X509Extensions requestExtensions)
|
|
{
|
|
DerInteger v = TbsRequest.V1;
|
|
this.requestorName = requestorName;
|
|
this.requestList = requestList;
|
|
this.version = v;
|
|
this.requestExtensions = requestExtensions;
|
|
}
|
|
|
|
// Token: 0x0600C6B2 RID: 50866 RVA: 0x002D64B0 File Offset: 0x002D46B0
|
|
[Token(Token = "0x600C6B2")]
|
|
[Address(RVA = "0x2BD5BA0", Offset = "0x2BD49A0", VA = "0x182BD5BA0")]
|
|
private TbsRequest(Asn1Sequence seq)
|
|
{
|
|
for (;;)
|
|
{
|
|
base..ctor();
|
|
int num = 0;
|
|
Asn1SequenceParser parser = seq.Parser;
|
|
if (parser == 0 || parser == 0 || parser != 0)
|
|
{
|
|
DerInteger v = TbsRequest.V1;
|
|
this.version = v;
|
|
Asn1SequenceParser parser2 = seq.Parser;
|
|
if (parser2 != 0 && parser2 != 0)
|
|
{
|
|
num++;
|
|
Asn1SequenceParser parser3 = seq.Parser;
|
|
if (parser3 == 0)
|
|
{
|
|
}
|
|
if (parser3 == 0)
|
|
{
|
|
continue;
|
|
}
|
|
GeneralName generalName;
|
|
this.requestorName = generalName;
|
|
}
|
|
Asn1SequenceParser parser4 = seq.Parser;
|
|
if (parser4 == 0)
|
|
{
|
|
}
|
|
if (parser4 != 0)
|
|
{
|
|
this.requestList = parser4;
|
|
Asn1Encodable asn1Encodable;
|
|
if (asn1Encodable != 2)
|
|
{
|
|
return;
|
|
}
|
|
Asn1SequenceParser parser5 = seq.Parser;
|
|
if (parser5 == 0 || parser5 != 0)
|
|
{
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
X509Extensions x509Extensions;
|
|
this.requestExtensions = x509Extensions;
|
|
}
|
|
|
|
// Token: 0x17001F05 RID: 7941
|
|
// (get) Token: 0x0600C6B3 RID: 50867 RVA: 0x002D656C File Offset: 0x002D476C
|
|
[Token(Token = "0x17001F05")]
|
|
public DerInteger Version
|
|
{
|
|
[Token(Token = "0x600C6B3")]
|
|
[Address(RVA = "0x3F6E20", Offset = "0x3F5C20", VA = "0x1803F6E20")]
|
|
get
|
|
{
|
|
return this.version;
|
|
}
|
|
}
|
|
|
|
// Token: 0x17001F06 RID: 7942
|
|
// (get) Token: 0x0600C6B4 RID: 50868 RVA: 0x002D6580 File Offset: 0x002D4780
|
|
[Token(Token = "0x17001F06")]
|
|
public GeneralName RequestorName
|
|
{
|
|
[Token(Token = "0x600C6B4")]
|
|
[Address(RVA = "0x3F5F40", Offset = "0x3F4D40", VA = "0x1803F5F40")]
|
|
get
|
|
{
|
|
return this.requestorName;
|
|
}
|
|
}
|
|
|
|
// Token: 0x17001F07 RID: 7943
|
|
// (get) Token: 0x0600C6B5 RID: 50869 RVA: 0x002D6594 File Offset: 0x002D4794
|
|
[Token(Token = "0x17001F07")]
|
|
public Asn1Sequence RequestList
|
|
{
|
|
[Token(Token = "0x600C6B5")]
|
|
[Address(RVA = "0x3F6400", Offset = "0x3F5200", VA = "0x1803F6400")]
|
|
get
|
|
{
|
|
return this.requestList;
|
|
}
|
|
}
|
|
|
|
// Token: 0x17001F08 RID: 7944
|
|
// (get) Token: 0x0600C6B6 RID: 50870 RVA: 0x002D65A8 File Offset: 0x002D47A8
|
|
[Token(Token = "0x17001F08")]
|
|
public X509Extensions RequestExtensions
|
|
{
|
|
[Token(Token = "0x600C6B6")]
|
|
[Address(RVA = "0x3F63E0", Offset = "0x3F51E0", VA = "0x1803F63E0")]
|
|
get
|
|
{
|
|
return this.requestExtensions;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600C6B7 RID: 50871 RVA: 0x002D65BC File Offset: 0x002D47BC
|
|
[Token(Token = "0x600C6B7")]
|
|
[Address(RVA = "0x2BD57A0", Offset = "0x2BD45A0", VA = "0x182BD57A0", Slot = "5")]
|
|
public override Asn1Object ToAsn1Object()
|
|
{
|
|
DerInteger derInteger = this.version;
|
|
Asn1EncodableVector asn1EncodableVector;
|
|
if (this.versionSet)
|
|
{
|
|
Asn1Encodable[] array = new Asn1Encodable[1];
|
|
DerInteger derInteger2 = this.version;
|
|
int num;
|
|
DerTaggedObject derTaggedObject = new DerTaggedObject(true, num, derInteger2);
|
|
num = 0;
|
|
if (derTaggedObject != 0)
|
|
{
|
|
}
|
|
array[0] = derTaggedObject;
|
|
asn1EncodableVector.Add(array);
|
|
}
|
|
if (this.requestorName != (ulong)0L)
|
|
{
|
|
Asn1Encodable[] array2 = new Asn1Encodable[1];
|
|
GeneralName generalName = this.requestorName;
|
|
DerTaggedObject derTaggedObject2 = new DerTaggedObject(16777216 != 0, 16777216, generalName);
|
|
if (derTaggedObject2 != 0)
|
|
{
|
|
}
|
|
array2[0] = derTaggedObject2;
|
|
asn1EncodableVector.Add(array2);
|
|
}
|
|
Asn1Encodable[] array3 = new Asn1Encodable[1];
|
|
Asn1Sequence asn1Sequence = this.requestList;
|
|
if (asn1Sequence != 0)
|
|
{
|
|
}
|
|
array3[0] = asn1Sequence;
|
|
asn1EncodableVector.Add(array3);
|
|
if (this.requestExtensions != (ulong)0L)
|
|
{
|
|
Asn1Encodable[] array4 = new Asn1Encodable[1];
|
|
X509Extensions x509Extensions = this.requestExtensions;
|
|
DerTaggedObject derTaggedObject3 = new DerTaggedObject(true, 2, x509Extensions);
|
|
if (derTaggedObject3 != 0)
|
|
{
|
|
}
|
|
array4[0] = derTaggedObject3;
|
|
asn1EncodableVector.Add(array4);
|
|
}
|
|
DerSequence derSequence = new DerSequence(asn1EncodableVector);
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x0600C6B8 RID: 50872 RVA: 0x002D66C0 File Offset: 0x002D48C0
|
|
// Note: this type is marked as 'beforefieldinit'.
|
|
[Token(Token = "0x600C6B8")]
|
|
[Address(RVA = "0x2BD5B40", Offset = "0x2BD4940", VA = "0x182BD5B40")]
|
|
static TbsRequest()
|
|
{
|
|
int num;
|
|
DerInteger derInteger = new DerInteger(num);
|
|
num = 0;
|
|
TbsRequest.V1 = derInteger;
|
|
}
|
|
|
|
// Token: 0x04007E21 RID: 32289
|
|
[Token(Token = "0x4007E21")]
|
|
private static readonly DerInteger V1;
|
|
|
|
// Token: 0x04007E22 RID: 32290
|
|
[FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x4007E22")]
|
|
private readonly DerInteger version;
|
|
|
|
// Token: 0x04007E23 RID: 32291
|
|
[FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x4007E23")]
|
|
private readonly GeneralName requestorName;
|
|
|
|
// Token: 0x04007E24 RID: 32292
|
|
[FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x4007E24")]
|
|
private readonly Asn1Sequence requestList;
|
|
|
|
// Token: 0x04007E25 RID: 32293
|
|
[FieldOffset(Offset = "0x28")]
|
|
[Token(Token = "0x4007E25")]
|
|
private readonly X509Extensions requestExtensions;
|
|
|
|
// Token: 0x04007E26 RID: 32294
|
|
[FieldOffset(Offset = "0x30")]
|
|
[Token(Token = "0x4007E26")]
|
|
private bool versionSet;
|
|
}
|
|
}
|