Files
Aug2021-Cpp2IL-Dump/Assembly-CSharp/BestHTTP/SecureProtocol/Org/BouncyCastle/Asn1/Cms/SignerInfo.cs
T
2026-04-10 22:50:51 +02:00

319 lines
11 KiB
C#

using System;
using System.Collections;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cms
{
// Token: 0x02001F41 RID: 8001
[Token(Token = "0x2001F41")]
public class SignerInfo : Asn1Encodable
{
// Token: 0x0600CA65 RID: 51813 RVA: 0x002E5B24 File Offset: 0x002E3D24
[Token(Token = "0x600CA65")]
[Address(RVA = "0x2AE7EC0", Offset = "0x2AE6CC0", VA = "0x182AE7EC0")]
public static SignerInfo GetInstance(object obj)
{
/*
An exception occurred when decompiling this method (0600CA65)
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cms.SignerInfo BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cms.SignerInfo::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: 0x0600CA66 RID: 51814 RVA: 0x002E5B78 File Offset: 0x002E3D78
[Token(Token = "0x600CA66")]
[Address(RVA = "0x2AE84A0", Offset = "0x2AE72A0", VA = "0x182AE84A0")]
public SignerInfo(SignerIdentifier sid, AlgorithmIdentifier digAlgorithm, Asn1Set authenticatedAttributes, AlgorithmIdentifier digEncryptionAlgorithm, Asn1OctetString encryptedDigest, Asn1Set unauthenticatedAttributes)
{
bool isTagged = sid.IsTagged;
DerInteger derInteger = new DerInteger(3);
this.version = derInteger;
this.digEncryptionAlgorithm = 0;
this.encryptedDigest = 0;
this.authenticatedAttributes = authenticatedAttributes;
this.unauthenticatedAttributes = 0;
this.sid = sid;
this.digAlgorithm = digAlgorithm;
}
// Token: 0x0600CA67 RID: 51815 RVA: 0x002E5BD0 File Offset: 0x002E3DD0
[Token(Token = "0x600CA67")]
[Address(RVA = "0x2AE88B0", Offset = "0x2AE76B0", VA = "0x182AE88B0")]
public SignerInfo(SignerIdentifier sid, AlgorithmIdentifier digAlgorithm, Attributes authenticatedAttributes, AlgorithmIdentifier digEncryptionAlgorithm, Asn1OctetString encryptedDigest, Attributes unauthenticatedAttributes)
{
bool isTagged = sid.IsTagged;
DerInteger derInteger = new DerInteger(3);
this.version = derInteger;
this.sid = sid;
this.digAlgorithm = digAlgorithm;
Asn1Set instance = Asn1Set.GetInstance(authenticatedAttributes);
this.authenticatedAttributes = instance;
this.digEncryptionAlgorithm = 0;
this.encryptedDigest = 0;
Asn1Set asn1Set;
this.unauthenticatedAttributes = asn1Set;
}
// Token: 0x0600CA68 RID: 51816 RVA: 0x002E5C30 File Offset: 0x002E3E30
[Token(Token = "0x600CA68")]
[Address(RVA = "0x2AE8580", Offset = "0x2AE7380", VA = "0x182AE8580")]
[Obsolete]
public SignerInfo(Asn1Sequence seq)
{
int num;
for (;;)
{
base..ctor();
IEnumerator enumerator = seq.GetEnumerator();
if (enumerator == 0)
{
}
num = 0;
if (enumerator != 0)
{
this.version = enumerator;
SignerIdentifier signerIdentifier;
this.sid = signerIdentifier;
AlgorithmIdentifier instance = AlgorithmIdentifier.GetInstance(signerIdentifier);
this.digAlgorithm = instance;
Asn1Set asn1Set;
if (instance != 0 && instance != 0)
{
if (instance == 0)
{
continue;
}
this.authenticatedAttributes = asn1Set;
}
this.authenticatedAttributes = num;
AlgorithmIdentifier instance2 = AlgorithmIdentifier.GetInstance(asn1Set);
this.digEncryptionAlgorithm = instance2;
Asn1OctetString instance3 = Asn1OctetString.GetInstance(instance2);
this.encryptedDigest = instance3;
if (instance3 == 0)
{
break;
}
if (instance3 == 0 || instance3 != 0)
{
goto IL_9A;
}
}
}
this.unauthenticatedAttributes = num;
return;
IL_9A:
Asn1Set asn1Set2;
this.unauthenticatedAttributes = asn1Set2;
}
// Token: 0x17002004 RID: 8196
// (get) Token: 0x0600CA69 RID: 51817 RVA: 0x002E5CE8 File Offset: 0x002E3EE8
[Token(Token = "0x17002004")]
public DerInteger Version
{
[Token(Token = "0x600CA69")]
[Address(RVA = "0x3F6E20", Offset = "0x3F5C20", VA = "0x1803F6E20")]
get
{
return this.version;
}
}
// Token: 0x17002005 RID: 8197
// (get) Token: 0x0600CA6A RID: 51818 RVA: 0x002E5CFC File Offset: 0x002E3EFC
[Token(Token = "0x17002005")]
public SignerIdentifier SignerID
{
[Token(Token = "0x600CA6A")]
[Address(RVA = "0x3F5F40", Offset = "0x3F4D40", VA = "0x1803F5F40")]
get
{
return this.sid;
}
}
// Token: 0x17002006 RID: 8198
// (get) Token: 0x0600CA6B RID: 51819 RVA: 0x002E5D10 File Offset: 0x002E3F10
[Token(Token = "0x17002006")]
public Asn1Set AuthenticatedAttributes
{
[Token(Token = "0x600CA6B")]
[Address(RVA = "0x3F63E0", Offset = "0x3F51E0", VA = "0x1803F63E0")]
get
{
return this.authenticatedAttributes;
}
}
// Token: 0x17002007 RID: 8199
// (get) Token: 0x0600CA6C RID: 51820 RVA: 0x002E5D24 File Offset: 0x002E3F24
[Token(Token = "0x17002007")]
public AlgorithmIdentifier DigestAlgorithm
{
[Token(Token = "0x600CA6C")]
[Address(RVA = "0x3F6400", Offset = "0x3F5200", VA = "0x1803F6400")]
get
{
return this.digAlgorithm;
}
}
// Token: 0x17002008 RID: 8200
// (get) Token: 0x0600CA6D RID: 51821 RVA: 0x002E5D38 File Offset: 0x002E3F38
[Token(Token = "0x17002008")]
public Asn1OctetString EncryptedDigest
{
[Token(Token = "0x600CA6D")]
[Address(RVA = "0x3F63D0", Offset = "0x3F51D0", VA = "0x1803F63D0")]
get
{
return this.encryptedDigest;
}
}
// Token: 0x17002009 RID: 8201
// (get) Token: 0x0600CA6E RID: 51822 RVA: 0x002E5D4C File Offset: 0x002E3F4C
[Token(Token = "0x17002009")]
public AlgorithmIdentifier DigestEncryptionAlgorithm
{
[Token(Token = "0x600CA6E")]
[Address(RVA = "0x3FA180", Offset = "0x3F8F80", VA = "0x1803FA180")]
get
{
return this.digEncryptionAlgorithm;
}
}
// Token: 0x1700200A RID: 8202
// (get) Token: 0x0600CA6F RID: 51823 RVA: 0x002E5D60 File Offset: 0x002E3F60
[Token(Token = "0x1700200A")]
public Asn1Set UnauthenticatedAttributes
{
[Token(Token = "0x600CA6F")]
[Address(RVA = "0x408890", Offset = "0x407690", VA = "0x180408890")]
get
{
return this.unauthenticatedAttributes;
}
}
// Token: 0x0600CA70 RID: 51824 RVA: 0x002E5D74 File Offset: 0x002E3F74
[Token(Token = "0x600CA70")]
[Address(RVA = "0x2AE80C0", Offset = "0x2AE6EC0", VA = "0x182AE80C0", Slot = "5")]
public override Asn1Object ToAsn1Object()
{
Asn1Encodable[] array = new Asn1Encodable[3];
DerInteger derInteger = this.version;
if (derInteger != 0)
{
}
array[0] = derInteger;
SignerIdentifier signerIdentifier = this.sid;
if (signerIdentifier != 0)
{
}
array[1] = signerIdentifier;
AlgorithmIdentifier algorithmIdentifier = this.digAlgorithm;
if (algorithmIdentifier != 0)
{
}
array[2] = algorithmIdentifier;
Asn1EncodableVector asn1EncodableVector = new Asn1EncodableVector(array);
if (this.authenticatedAttributes != (ulong)0L)
{
Asn1Encodable[] array2 = new Asn1Encodable[1];
Asn1Set asn1Set = this.authenticatedAttributes;
int num;
int num2;
DerTaggedObject derTaggedObject = new DerTaggedObject(num != 0, num2, asn1Set);
num2 = 0;
num = 0;
if (derTaggedObject != 0)
{
}
array2[0] = derTaggedObject;
asn1EncodableVector.Add(array2);
}
Asn1Encodable[] array3 = new Asn1Encodable[2];
AlgorithmIdentifier algorithmIdentifier2 = this.digEncryptionAlgorithm;
if (algorithmIdentifier2 != 0)
{
}
array3[0] = algorithmIdentifier2;
Asn1OctetString asn1OctetString = this.encryptedDigest;
if (asn1OctetString != 0)
{
}
array3[1] = asn1OctetString;
asn1EncodableVector.Add(array3);
if (this.unauthenticatedAttributes != (ulong)0L)
{
Asn1Encodable[] array4 = new Asn1Encodable[1];
Asn1Set asn1Set2 = this.unauthenticatedAttributes;
int num3;
DerTaggedObject derTaggedObject2 = new DerTaggedObject(num3 != 0, 1, asn1Set2);
num3 = 0;
if (derTaggedObject2 != 0)
{
}
array4[0] = derTaggedObject2;
asn1EncodableVector.Add(array4);
}
DerSequence derSequence = new DerSequence(asn1EncodableVector);
throw new NullReferenceException();
}
// Token: 0x040080DB RID: 32987
[FieldOffset(Offset = "0x10")]
[Token(Token = "0x40080DB")]
private DerInteger version;
// Token: 0x040080DC RID: 32988
[FieldOffset(Offset = "0x18")]
[Token(Token = "0x40080DC")]
private SignerIdentifier sid;
// Token: 0x040080DD RID: 32989
[FieldOffset(Offset = "0x20")]
[Token(Token = "0x40080DD")]
private AlgorithmIdentifier digAlgorithm;
// Token: 0x040080DE RID: 32990
[FieldOffset(Offset = "0x28")]
[Token(Token = "0x40080DE")]
private Asn1Set authenticatedAttributes;
// Token: 0x040080DF RID: 32991
[FieldOffset(Offset = "0x30")]
[Token(Token = "0x40080DF")]
private AlgorithmIdentifier digEncryptionAlgorithm;
// Token: 0x040080E0 RID: 32992
[FieldOffset(Offset = "0x38")]
[Token(Token = "0x40080E0")]
private Asn1OctetString encryptedDigest;
// Token: 0x040080E1 RID: 32993
[FieldOffset(Offset = "0x40")]
[Token(Token = "0x40080E1")]
private Asn1Set unauthenticatedAttributes;
}
}