253 lines
9.5 KiB
C#
253 lines
9.5 KiB
C#
using System;
|
|
using System.Runtime.InteropServices;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
|
|
using Cpp2IlInjected;
|
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Ocsp
|
|
{
|
|
// Token: 0x020018C4 RID: 6340
|
|
[Token(Token = "0x20018C4")]
|
|
[StructLayout(3)]
|
|
public class BasicOcspResponse : Asn1Encodable
|
|
{
|
|
// Token: 0x0600AA5A RID: 43610 RVA: 0x0027C284 File Offset: 0x0027A484
|
|
[Token(Token = "0x600AA5A")]
|
|
[Address(RVA = "0x27C96C0", Offset = "0x27C80C0", VA = "0x1827C96C0")]
|
|
public static BasicOcspResponse GetInstance(Asn1TaggedObject obj, bool explicitly)
|
|
{
|
|
return BasicOcspResponse.GetInstance(Asn1Sequence.GetInstance(obj, explicitly));
|
|
}
|
|
|
|
// Token: 0x0600AA5B RID: 43611 RVA: 0x0027C2A0 File Offset: 0x0027A4A0
|
|
[Token(Token = "0x600AA5B")]
|
|
[Address(RVA = "0x27C96E0", Offset = "0x27C80E0", VA = "0x1827C96E0")]
|
|
public static BasicOcspResponse GetInstance(object obj)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600AA5B)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Ocsp.BasicOcspResponse BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Ocsp.BasicOcspResponse::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: 0x0600AA5C RID: 43612 RVA: 0x0027C2F4 File Offset: 0x0027A4F4
|
|
[Token(Token = "0x600AA5C")]
|
|
[Address(RVA = "0x9BCAC0", Offset = "0x9BB4C0", VA = "0x1809BCAC0")]
|
|
public BasicOcspResponse(ResponseData tbsResponseData, AlgorithmIdentifier signatureAlgorithm, DerBitString signature, Asn1Sequence certs)
|
|
{
|
|
this.tbsResponseData = tbsResponseData;
|
|
this.signature = signature;
|
|
this.certs = 0;
|
|
this.signatureAlgorithm = signatureAlgorithm;
|
|
}
|
|
|
|
// Token: 0x0600AA5D RID: 43613 RVA: 0x0027C324 File Offset: 0x0027A524
|
|
[Token(Token = "0x600AA5D")]
|
|
[Address(RVA = "0x27C9B30", Offset = "0x27C8530", VA = "0x1827C9B30")]
|
|
private BasicOcspResponse(Asn1Sequence seq)
|
|
{
|
|
for (;;)
|
|
{
|
|
base..ctor();
|
|
Asn1SequenceParser parser = seq.Parser;
|
|
ResponseData responseData;
|
|
this.tbsResponseData = responseData;
|
|
Asn1SequenceParser parser2 = seq.Parser;
|
|
AlgorithmIdentifier algorithmIdentifier;
|
|
this.signatureAlgorithm = algorithmIdentifier;
|
|
Asn1SequenceParser parser3 = seq.Parser;
|
|
if (parser3 == 0)
|
|
{
|
|
}
|
|
if (parser3 != 0)
|
|
{
|
|
this.signature = parser3;
|
|
Asn1Encodable asn1Encodable;
|
|
if (asn1Encodable <= (ulong)3L)
|
|
{
|
|
return;
|
|
}
|
|
Asn1SequenceParser parser4 = seq.Parser;
|
|
if (parser4 == 0 || parser4 != 0)
|
|
{
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
Asn1Sequence asn1Sequence;
|
|
this.certs = asn1Sequence;
|
|
}
|
|
|
|
// Token: 0x0600AA5E RID: 43614 RVA: 0x0027C39C File Offset: 0x0027A59C
|
|
[Token(Token = "0x600AA5E")]
|
|
[Address(RVA = "0x3C39A0", Offset = "0x3C23A0", VA = "0x1803C39A0")]
|
|
[Obsolete]
|
|
public ResponseData GetTbsResponseData()
|
|
{
|
|
return this.tbsResponseData;
|
|
}
|
|
|
|
// Token: 0x17001ADD RID: 6877
|
|
// (get) Token: 0x0600AA5F RID: 43615 RVA: 0x0027C3B0 File Offset: 0x0027A5B0
|
|
[Token(Token = "0x17001ADD")]
|
|
public ResponseData TbsResponseData
|
|
{
|
|
[Token(Token = "0x600AA5F")]
|
|
[Address(RVA = "0x3C39A0", Offset = "0x3C23A0", VA = "0x1803C39A0")]
|
|
get
|
|
{
|
|
return this.tbsResponseData;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600AA60 RID: 43616 RVA: 0x0027C3C4 File Offset: 0x0027A5C4
|
|
[Token(Token = "0x600AA60")]
|
|
[Address(RVA = "0x3C1240", Offset = "0x3BFC40", VA = "0x1803C1240")]
|
|
[Obsolete]
|
|
public AlgorithmIdentifier GetSignatureAlgorithm()
|
|
{
|
|
return this.signatureAlgorithm;
|
|
}
|
|
|
|
// Token: 0x17001ADE RID: 6878
|
|
// (get) Token: 0x0600AA61 RID: 43617 RVA: 0x0027C3D8 File Offset: 0x0027A5D8
|
|
[Token(Token = "0x17001ADE")]
|
|
public AlgorithmIdentifier SignatureAlgorithm
|
|
{
|
|
[Token(Token = "0x600AA61")]
|
|
[Address(RVA = "0x3C1240", Offset = "0x3BFC40", VA = "0x1803C1240")]
|
|
get
|
|
{
|
|
return this.signatureAlgorithm;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600AA62 RID: 43618 RVA: 0x0027C3EC File Offset: 0x0027A5EC
|
|
[Token(Token = "0x600AA62")]
|
|
[Address(RVA = "0x3C1220", Offset = "0x3BFC20", VA = "0x1803C1220")]
|
|
[Obsolete]
|
|
public DerBitString GetSignature()
|
|
{
|
|
return this.signature;
|
|
}
|
|
|
|
// Token: 0x17001ADF RID: 6879
|
|
// (get) Token: 0x0600AA63 RID: 43619 RVA: 0x0027C400 File Offset: 0x0027A600
|
|
[Token(Token = "0x17001ADF")]
|
|
public DerBitString Signature
|
|
{
|
|
[Token(Token = "0x600AA63")]
|
|
[Address(RVA = "0x3C1220", Offset = "0x3BFC20", VA = "0x1803C1220")]
|
|
get
|
|
{
|
|
return this.signature;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600AA64 RID: 43620 RVA: 0x0027C414 File Offset: 0x0027A614
|
|
[Token(Token = "0x600AA64")]
|
|
[Address(RVA = "0xE583F0", Offset = "0xE56DF0", VA = "0x180E583F0")]
|
|
public byte[] GetSignatureOctets()
|
|
{
|
|
Asn1Object asn1Object = this.signature.ToAsn1Object();
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x0600AA65 RID: 43621 RVA: 0x0027C434 File Offset: 0x0027A634
|
|
[Token(Token = "0x600AA65")]
|
|
[Address(RVA = "0x3C1230", Offset = "0x3BFC30", VA = "0x1803C1230")]
|
|
[Obsolete]
|
|
public Asn1Sequence GetCerts()
|
|
{
|
|
return this.certs;
|
|
}
|
|
|
|
// Token: 0x17001AE0 RID: 6880
|
|
// (get) Token: 0x0600AA66 RID: 43622 RVA: 0x0027C448 File Offset: 0x0027A648
|
|
[Token(Token = "0x17001AE0")]
|
|
public Asn1Sequence Certs
|
|
{
|
|
[Token(Token = "0x600AA66")]
|
|
[Address(RVA = "0x3C1230", Offset = "0x3BFC30", VA = "0x1803C1230")]
|
|
get
|
|
{
|
|
return this.certs;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600AA67 RID: 43623 RVA: 0x0027C45C File Offset: 0x0027A65C
|
|
[Token(Token = "0x600AA67")]
|
|
[Address(RVA = "0x27C98E0", Offset = "0x27C82E0", VA = "0x1827C98E0", Slot = "5")]
|
|
public override Asn1Object ToAsn1Object()
|
|
{
|
|
Asn1Encodable[] array = new Asn1Encodable[3];
|
|
ResponseData responseData = this.tbsResponseData;
|
|
if (responseData != 0)
|
|
{
|
|
}
|
|
array[0] = responseData;
|
|
AlgorithmIdentifier algorithmIdentifier = this.signatureAlgorithm;
|
|
if (algorithmIdentifier != 0)
|
|
{
|
|
}
|
|
array[1] = algorithmIdentifier;
|
|
DerBitString derBitString = this.signature;
|
|
if (derBitString != 0)
|
|
{
|
|
}
|
|
array[2] = derBitString;
|
|
Asn1EncodableVector asn1EncodableVector = new Asn1EncodableVector(array);
|
|
if (this.certs != (ulong)0L)
|
|
{
|
|
Asn1Encodable[] array2 = new Asn1Encodable[1];
|
|
Asn1Sequence asn1Sequence = this.certs;
|
|
int num;
|
|
DerTaggedObject derTaggedObject = new DerTaggedObject(true, num, asn1Sequence);
|
|
num = 0;
|
|
if (derTaggedObject != 0)
|
|
{
|
|
}
|
|
array2[0] = derTaggedObject;
|
|
asn1EncodableVector.Add(array2);
|
|
}
|
|
DerSequence derSequence = new DerSequence(asn1EncodableVector);
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x04006FA6 RID: 28582
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x4006FA6")]
|
|
private readonly ResponseData tbsResponseData;
|
|
|
|
// Token: 0x04006FA7 RID: 28583
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x4006FA7")]
|
|
private readonly AlgorithmIdentifier signatureAlgorithm;
|
|
|
|
// Token: 0x04006FA8 RID: 28584
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x4006FA8")]
|
|
private readonly DerBitString signature;
|
|
|
|
// Token: 0x04006FA9 RID: 28585
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x28")]
|
|
[Token(Token = "0x4006FA9")]
|
|
private readonly Asn1Sequence certs;
|
|
}
|
|
}
|