using System; using System.Collections; using Cpp2IlInjected; namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cms { // Token: 0x02001F3E RID: 7998 [Token(Token = "0x2001F3E")] public class SignedData : Asn1Encodable { // Token: 0x0600CA49 RID: 51785 RVA: 0x002E53B0 File Offset: 0x002E35B0 [Token(Token = "0x600CA49")] [Address(RVA = "0x2AE6DC0", Offset = "0x2AE5BC0", VA = "0x182AE6DC0")] public static SignedData GetInstance(object obj) { /* An exception occurred when decompiling this method (0600CA49) ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cms.SignedData BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cms.SignedData::GetInstance(System.Object) ---> System.Exception: Basic block has to end with unconditional control flow. { IL_22: stloc:string(var_6_28, call:string(Platform::GetTypeName, ldloc:object(obj))) stloc:ArgumentException(var_7_40, newobj:ArgumentException(ArgumentException::.ctor, call:string(string::Concat, ldstr:string("Unknown object in factory: "), ldloc:string(var_6_28)), 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: 0x0600CA4A RID: 51786 RVA: 0x002E5400 File Offset: 0x002E3600 [Token(Token = "0x600CA4A")] [Address(RVA = "0x2AE78C0", Offset = "0x2AE66C0", VA = "0x182AE78C0")] public SignedData(Asn1Set digestAlgorithms, ContentInfo contentInfo, Asn1Set certificates, Asn1Set crls, Asn1Set signerInfos) { this.signerInfos = 0; DerInteger derInteger; this.version = derInteger; this.digestAlgorithms = digestAlgorithms; this.contentInfo = contentInfo; this.certificates = certificates; this.crls = 0; bool flag; this.crlsBer = flag; if (certificates != 0) { } bool flag2 = certificates != 0; this.certsBer = flag2; } // Token: 0x0600CA4B RID: 51787 RVA: 0x002E5468 File Offset: 0x002E3668 [Token(Token = "0x600CA4B")] [Address(RVA = "0x2AE6770", Offset = "0x2AE5570", VA = "0x182AE6770")] private DerInteger CalculateVersion(DerObjectIdentifier contentOid, Asn1Set certs, Asn1Set crls, Asn1Set signerInfs) { int num; do { num = 0; if (certs != 0) { IEnumerator enumerator = certs.GetEnumerator(); if (enumerator != 0) { while (enumerator == 0) { } while (enumerator == 0) { } if (enumerator == 0) { goto IL_8B; } if (enumerator != (ulong)1L && enumerator != (ulong)2L) { while (enumerator != (ulong)3L) { } } } if (enumerator != 0) { } if (num != 0) { goto IL_91; } if (num != -1) { } if ((ulong)1L != 0UL) { goto IL_85; } } if (crls == 0) { break; } IEnumerator enumerator2 = crls.GetEnumerator(); if (enumerator2 != 0) { while (enumerator2 == 0) { } } if ((uint)(-1) != 0U) { } } while (num != 0); DerObjectIdentifier data = CmsObjectIdentifiers.Data; bool flag; if (!flag) { return SignedData.Version1; } return SignedData.Version3; IL_85: return SignedData.Version5; IL_8B: throw new NullReferenceException(); IL_91: throw new NullReferenceException(); } // Token: 0x0600CA4C RID: 51788 RVA: 0x002E550C File Offset: 0x002E370C [Token(Token = "0x600CA4C")] [Address(RVA = "0x2AE6C10", Offset = "0x2AE5A10", VA = "0x182AE6C10")] private bool CheckForVersion3(Asn1Set signerInfs) { int num; do { num = 0; int intValue; if (signerInfs.GetEnumerator() != 0) { SignerInfo signerInfo; intValue = signerInfo.version.Value.IntValue; while (intValue != 3) { } } if (intValue != 0) { } } while (num != 0); if (num != -1) { return true; } throw new NullReferenceException(); } // Token: 0x0600CA4D RID: 51789 RVA: 0x002E5568 File Offset: 0x002E3768 [Token(Token = "0x600CA4D")] [Address(RVA = "0x2AE7530", Offset = "0x2AE6330", VA = "0x182AE7530")] private SignedData(Asn1Sequence seq) { ContentInfo contentInfo; for (;;) { base..ctor(); IEnumerator enumerator = seq.GetEnumerator(); if (enumerator == 0 || enumerator != 0) { this.version = enumerator; if (enumerator == 0 || enumerator != 0) { this.digestAlgorithms = enumerator; this.contentInfo = contentInfo; if (contentInfo == 0) { return; } if (contentInfo == 0) { } if (contentInfo != 0) { if (contentInfo == 0) { this.signerInfos = contentInfo; } if (contentInfo != 0) { break; } } } } } DerObjectIdentifier contentType = contentInfo.contentType; Asn1Set asn1Set; if (contentType == 0) { bool flag = contentType != 0; this.certsBer = flag; this.certificates = asn1Set; } bool flag2 = asn1Set != 0; this.crlsBer = flag2; Asn1Set asn1Set2; this.crls = asn1Set2; } // Token: 0x17001FFB RID: 8187 // (get) Token: 0x0600CA4E RID: 51790 RVA: 0x002E562C File Offset: 0x002E382C [Token(Token = "0x17001FFB")] public DerInteger Version { [Token(Token = "0x600CA4E")] [Address(RVA = "0x3F6E20", Offset = "0x3F5C20", VA = "0x1803F6E20")] get { return this.version; } } // Token: 0x17001FFC RID: 8188 // (get) Token: 0x0600CA4F RID: 51791 RVA: 0x002E5640 File Offset: 0x002E3840 [Token(Token = "0x17001FFC")] public Asn1Set DigestAlgorithms { [Token(Token = "0x600CA4F")] [Address(RVA = "0x3F5F40", Offset = "0x3F4D40", VA = "0x1803F5F40")] get { return this.digestAlgorithms; } } // Token: 0x17001FFD RID: 8189 // (get) Token: 0x0600CA50 RID: 51792 RVA: 0x002E5654 File Offset: 0x002E3854 [Token(Token = "0x17001FFD")] public ContentInfo EncapContentInfo { [Token(Token = "0x600CA50")] [Address(RVA = "0x3F6400", Offset = "0x3F5200", VA = "0x1803F6400")] get { return this.contentInfo; } } // Token: 0x17001FFE RID: 8190 // (get) Token: 0x0600CA51 RID: 51793 RVA: 0x002E5668 File Offset: 0x002E3868 [Token(Token = "0x17001FFE")] public Asn1Set Certificates { [Token(Token = "0x600CA51")] [Address(RVA = "0x3F63E0", Offset = "0x3F51E0", VA = "0x1803F63E0")] get { return this.certificates; } } // Token: 0x17001FFF RID: 8191 // (get) Token: 0x0600CA52 RID: 51794 RVA: 0x002E567C File Offset: 0x002E387C [Token(Token = "0x17001FFF")] public Asn1Set CRLs { [Token(Token = "0x600CA52")] [Address(RVA = "0x3FA180", Offset = "0x3F8F80", VA = "0x1803FA180")] get { return this.crls; } } // Token: 0x17002000 RID: 8192 // (get) Token: 0x0600CA53 RID: 51795 RVA: 0x002E5690 File Offset: 0x002E3890 [Token(Token = "0x17002000")] public Asn1Set SignerInfos { [Token(Token = "0x600CA53")] [Address(RVA = "0x3F63D0", Offset = "0x3F51D0", VA = "0x1803F63D0")] get { return this.signerInfos; } } // Token: 0x0600CA54 RID: 51796 RVA: 0x002E56A4 File Offset: 0x002E38A4 [Token(Token = "0x600CA54")] [Address(RVA = "0x2AE6FB0", Offset = "0x2AE5DB0", VA = "0x182AE6FB0", Slot = "5")] public override Asn1Object ToAsn1Object() { Asn1Encodable[] array = new Asn1Encodable[3]; DerInteger derInteger = this.version; if (derInteger != 0) { } array[0] = derInteger; Asn1Set asn1Set = this.digestAlgorithms; if (asn1Set != 0) { } array[1] = asn1Set; ContentInfo contentInfo = this.contentInfo; if (contentInfo != 0) { } array[2] = contentInfo; Asn1EncodableVector asn1EncodableVector = new Asn1EncodableVector(array); int num = 0; if (this.certificates != num) { if ((this.certsBer ? 1 : 0) == num) { Asn1Encodable[] array2 = new Asn1Encodable[0]; Asn1Set asn1Set2 = this.certificates; int num2; int num3; DerTaggedObject derTaggedObject = new DerTaggedObject(num2 != 0, num3, asn1Set2); num3 = 0; num2 = 0; if (derTaggedObject != 0) { } } Asn1Set asn1Set3 = this.certificates; int num4; int num5; BerTaggedObject berTaggedObject = new BerTaggedObject(num4 != 0, num5, asn1Set3); num5 = 0; num4 = 0; if (berTaggedObject != 0) { } } if (this.crls != num) { if ((this.crlsBer ? 1 : 0) == num) { Asn1Encodable[] array3 = new Asn1Encodable[1]; Asn1Set asn1Set4 = this.crls; int num6; DerTaggedObject derTaggedObject2 = new DerTaggedObject(num6 != 0, 1, asn1Set4); num6 = 0; if (derTaggedObject2 != 0) { } } Asn1Set asn1Set5 = this.crls; int num7; BerTaggedObject berTaggedObject2 = new BerTaggedObject(num7 != 0, 1, asn1Set5); num7 = 0; if (berTaggedObject2 != 0) { } } Asn1Encodable[] array4 = new Asn1Encodable[1]; Asn1Set asn1Set6 = this.signerInfos; if (asn1Set6 != 0) { } array4[0] = asn1Set6; asn1EncodableVector.Add(array4); BerSequence berSequence = new BerSequence(asn1EncodableVector); throw new NullReferenceException(); } // Token: 0x040080C9 RID: 32969 [Token(Token = "0x40080C9")] private static readonly DerInteger Version1 = new DerInteger(1); // Token: 0x040080CA RID: 32970 [Token(Token = "0x40080CA")] private static readonly DerInteger Version3 = new DerInteger(3); // Token: 0x040080CB RID: 32971 [Token(Token = "0x40080CB")] private static readonly DerInteger Version4 = new DerInteger(4); // Token: 0x040080CC RID: 32972 [Token(Token = "0x40080CC")] private static readonly DerInteger Version5 = new DerInteger(5); // Token: 0x040080CD RID: 32973 [FieldOffset(Offset = "0x10")] [Token(Token = "0x40080CD")] private readonly DerInteger version; // Token: 0x040080CE RID: 32974 [FieldOffset(Offset = "0x18")] [Token(Token = "0x40080CE")] private readonly Asn1Set digestAlgorithms; // Token: 0x040080CF RID: 32975 [FieldOffset(Offset = "0x20")] [Token(Token = "0x40080CF")] private readonly ContentInfo contentInfo; // Token: 0x040080D0 RID: 32976 [FieldOffset(Offset = "0x28")] [Token(Token = "0x40080D0")] private readonly Asn1Set certificates; // Token: 0x040080D1 RID: 32977 [FieldOffset(Offset = "0x30")] [Token(Token = "0x40080D1")] private readonly Asn1Set crls; // Token: 0x040080D2 RID: 32978 [FieldOffset(Offset = "0x38")] [Token(Token = "0x40080D2")] private readonly Asn1Set signerInfos; // Token: 0x040080D3 RID: 32979 [FieldOffset(Offset = "0x40")] [Token(Token = "0x40080D3")] private readonly bool certsBer; // Token: 0x040080D4 RID: 32980 [FieldOffset(Offset = "0x41")] [Token(Token = "0x40080D4")] private readonly bool crlsBer; } }