using System; using System.Collections; using System.Runtime.InteropServices; using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1; using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.IsisMtt; using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509; using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto; using BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Parameters; using BestHTTP.SecureProtocol.Org.BouncyCastle.Math; using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities; using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Collections; using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Date; using BestHTTP.SecureProtocol.Org.BouncyCastle.X509; using BestHTTP.SecureProtocol.Org.BouncyCastle.X509.Store; using Cpp2IlInjected; namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Pkix { // Token: 0x020013A2 RID: 5026 [Token(Token = "0x20013A2")] [StructLayout(3)] public class PkixCertPathValidatorUtilities { // Token: 0x06007F59 RID: 32601 RVA: 0x001AB44C File Offset: 0x001A964C [Token(Token = "0x6007F59")] [Address(RVA = "0x4ECAA0", Offset = "0x4EB4A0", VA = "0x1804ECAA0")] internal static TrustAnchor FindTrustAnchor(X509Certificate cert, ISet trustAnchors) { /* An exception occurred when decompiling this method (06007F59) ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Pkix.TrustAnchor BestHTTP.SecureProtocol.Org.BouncyCastle.Pkix.PkixCertPathValidatorUtilities::FindTrustAnchor(BestHTTP.SecureProtocol.Org.BouncyCastle.X509.X509Certificate,BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Collections.ISet) ---> System.Exception: Basic block has to end with unconditional control flow. { IL_95: stloc:Exception(var_9_A0, newobj:Exception(Exception::.ctor, ldstr:string("TrustAnchor found but certificate validation failed."), ldloc:int32[exp:Exception](var_1_03))) } 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.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: 0x06007F5A RID: 32602 RVA: 0x001AB4FC File Offset: 0x001A96FC [Token(Token = "0x6007F5A")] [Address(RVA = "0x4EEFC0", Offset = "0x4ED9C0", VA = "0x1804EEFC0")] internal static bool IsIssuerTrustAnchor(X509Certificate cert, ISet trustAnchors) { /* An exception occurred when decompiling this method (06007F5A) ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Boolean BestHTTP.SecureProtocol.Org.BouncyCastle.Pkix.PkixCertPathValidatorUtilities::IsIssuerTrustAnchor(BestHTTP.SecureProtocol.Org.BouncyCastle.X509.X509Certificate,BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Collections.ISet) ---> System.Exception: Basic block has to end with unconditional control flow. { Block_0: stloc:TrustAnchor(var_0_07, call:TrustAnchor(PkixCertPathValidatorUtilities::FindTrustAnchor, ldloc:X509Certificate(cert), ldloc:ISet(trustAnchors))) } 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: 0x06007F5B RID: 32603 RVA: 0x001AB514 File Offset: 0x001A9714 [Token(Token = "0x6007F5B")] [Address(RVA = "0x4EBE60", Offset = "0x4EA860", VA = "0x1804EBE60")] internal static void AddAdditionalStoresFromAltNames(X509Certificate cert, PkixParameters pkixParams) { while (cert.GetSubjectAlternativeNames() != 0) { ICollection subjectAlternativeNames = cert.GetSubjectAlternativeNames(); if (subjectAlternativeNames == 0) { break; } if (subjectAlternativeNames != 0) { int num; while (num == 0) { } if (num == 0 || num != 0) { break; } } } } // Token: 0x06007F5C RID: 32604 RVA: 0x001AB548 File Offset: 0x001A9748 [Token(Token = "0x6007F5C")] [Address(RVA = "0x4EEEA0", Offset = "0x4ED8A0", VA = "0x1804EEEA0")] internal static DateTime GetValidDate(PkixParameters paramsPKIX) { return DateTime.UtcNow; } // Token: 0x06007F5D RID: 32605 RVA: 0x001AB564 File Offset: 0x001A9764 [Token(Token = "0x6007F5D")] [Address(RVA = "0x4EE2E0", Offset = "0x4ECCE0", VA = "0x1804EE2E0")] internal static X509Name GetIssuerPrincipal(object cert) { for (;;) { if (cert == 0) { if (cert != 0 && cert != 0) { break; } } else if (cert != 0 && cert != 0) { goto Block_4; } } X509Name[] array; return array[0]; Block_4: throw new NullReferenceException(); } // Token: 0x06007F5E RID: 32606 RVA: 0x001AB59C File Offset: 0x001A979C [Token(Token = "0x6007F5E")] [Address(RVA = "0x4EF050", Offset = "0x4EDA50", VA = "0x1804EF050")] internal static bool IsSelfIssued(X509Certificate cert) { X509Name issuerDN = cert.IssuerDN; BigInteger serialNumber = cert.SerialNumber; bool flag; return flag; } // Token: 0x06007F5F RID: 32607 RVA: 0x001AB5C0 File Offset: 0x001A97C0 [Token(Token = "0x6007F5F")] [Address(RVA = "0x4ECE50", Offset = "0x4EB850", VA = "0x1804ECE50")] internal static AlgorithmIdentifier GetAlgorithmIdentifier(AsymmetricKeyParameter key) { return SubjectPublicKeyInfoFactory.CreateSubjectPublicKeyInfo(key).algID; } // Token: 0x06007F60 RID: 32608 RVA: 0x001AB5E0 File Offset: 0x001A97E0 [Token(Token = "0x6007F60")] [Address(RVA = "0x4EEF20", Offset = "0x4ED920", VA = "0x1804EEF20")] internal static bool IsAnyPolicy(ISet policySet) { bool flag; return policySet == 0 || flag; } // Token: 0x06007F61 RID: 32609 RVA: 0x001AB5F4 File Offset: 0x001A97F4 [Token(Token = "0x6007F61")] [Address(RVA = "0x4EBCC0", Offset = "0x4EA6C0", VA = "0x1804EBCC0")] internal static void AddAdditionalStoreFromLocation(string location, PkixParameters pkixParams) { if (pkixParams.GetStores() != 0) { if (!Platform.StartsWith(location, "ldap://")) { } string text = location.Substring(7); } } // Token: 0x06007F62 RID: 32610 RVA: 0x001AB664 File Offset: 0x001A9864 [Token(Token = "0x6007F62")] [Address(RVA = "0x4EEA50", Offset = "0x4ED450", VA = "0x1804EEA50")] private static BigInteger GetSerialNumber(object cert) { while ((cert == 0 && (cert == 0 || cert == 0)) || cert == 0 || cert == 0) { } throw new NullReferenceException(); } // Token: 0x06007F63 RID: 32611 RVA: 0x001AB698 File Offset: 0x001A9898 [Token(Token = "0x6007F63")] [Address(RVA = "0x4EE810", Offset = "0x4ED210", VA = "0x1804EE810")] internal static ISet GetQualifierSet(Asn1Sequence qualifiers) { int num; do { num = 0; HashSet hashSet = new HashSet(); if (qualifiers == 0) { break; } IEnumerator enumerator = qualifiers.GetEnumerator(); if (enumerator != 0) { if (enumerator == 0) { } if (enumerator == 0) { goto IL_3A; } } PolicyQualifierInfo policyQualifierInfo; if (policyQualifierInfo != 0) { } if (num != -1) { } } while (num != 0); throw new NullReferenceException(); IL_3A: throw new NullReferenceException(); } // Token: 0x06007F64 RID: 32612 RVA: 0x001AB6E4 File Offset: 0x001A98E4 [Token(Token = "0x6007F64")] [Address(RVA = "0x4F03D0", Offset = "0x4EEDD0", VA = "0x1804F03D0")] internal static PkixPolicyNode RemovePolicyNode(PkixPolicyNode validPolicyTree, IList[] policyNodes, PkixPolicyNode _node) { if (validPolicyTree != 0) { PkixCertPathValidatorUtilities.RemovePolicyNodeRecurse(policyNodes, _node); return validPolicyTree; } throw new NullReferenceException(); } // Token: 0x06007F65 RID: 32613 RVA: 0x001AB72C File Offset: 0x001A992C [Token(Token = "0x6007F65")] [Address(RVA = "0x4F0170", Offset = "0x4EEB70", VA = "0x1804F0170")] private static void RemovePolicyNodeRecurse(IList[] policyNodes, PkixPolicyNode _node) { int num; do { num = 0; string text = _node.ToString(); IList list = policyNodes[text]; if (_node.ValidPolicy == 0) { break; } int depth = _node.Depth; int num2; if (depth != 0) { if (depth == 0) { } num2 = 0; if (depth == 0) { goto IL_44; } } if (num2 != 0) { } if (num != -1) { } } while (num != 0); return; IL_44: throw new NullReferenceException(); } // Token: 0x06007F66 RID: 32614 RVA: 0x001AB784 File Offset: 0x001A9984 [Token(Token = "0x6007F66")] [Address(RVA = "0x4EF0B0", Offset = "0x4EDAB0", VA = "0x1804EF0B0")] internal static void PrepareNextCertB1(int i, IList[] policyNodes, string id_p, IDictionary m_idp, X509Certificate cert) { IList list = policyNodes[i]; bool flag; while (!flag) { } } // Token: 0x06007F67 RID: 32615 RVA: 0x001AB828 File Offset: 0x001A9A28 [Token(Token = "0x6007F67")] [Address(RVA = "0x4EF810", Offset = "0x4EE210", VA = "0x1804EF810")] internal static PkixPolicyNode PrepareNextCertB2(int i, IList[] policyNodes, string id_p, PkixPolicyNode validPolicyTree) { int num; do { num = 0; IList list = Platform.CreateArrayList(policyNodes[i]); if (list != 0) { if (list == 0) { continue; } bool flag; if (!flag) { num++; } IList list2 = policyNodes[i]; int num2 = i - 1; IList list3 = policyNodes[num2]; PkixPolicyNode pkixPolicyNode; if (num < num2 && pkixPolicyNode != 0) { num++; } } if (num != -1) { } } while (num != 0); return validPolicyTree; } // Token: 0x06007F68 RID: 32616 RVA: 0x001AB88C File Offset: 0x001A9A8C [Token(Token = "0x6007F68")] [Address(RVA = "0x4ECEF0", Offset = "0x4EB8F0", VA = "0x1804ECEF0")] internal static void GetCertStatus(DateTime validDate, X509Crl crl, object cert, CertStatus certStatus) { Asn1Object asn1Object; do { if (asn1Object == 0) { } } while (asn1Object == 0); X509Crl x509Crl = new X509Crl(CertificateList.GetInstance(asn1Object)); BigInteger serialNumber = PkixCertPathValidatorUtilities.GetSerialNumber(cert); if (x509Crl.NextUpdate != 0) { int num = 0; if (!PkixCertPathValidatorUtilities.GetIssuerPrincipal(cert).Equivalent(num, true)) { int version = crl.Version; bool flag; if (!flag) { return; } } bool flag2; DerEnumerated instance; if (flag2) { Asn1Object asn1Object2; instance = DerEnumerated.GetInstance(asn1Object2); } DateTime dateTime; if (instance < dateTime) { if (instance == 0) { goto IL_B7; } BigInteger value = instance.Value; int num2 = 0; if (!value.TestBit(num2) && !instance.Value.TestBit(1) && !instance.Value.TestBit(2) && !instance.Value.TestBit(8)) { return; } } if (instance != 0) { goto IL_C0; } IL_B7: certStatus.status = (int)((ulong)0L); IL_C0: int sign = instance.Value.sign; certStatus.status = sign; DateTime dateTime2; DateTimeObject dateTimeObject = new DateTimeObject(dateTime2); certStatus.revocationDate = dateTimeObject; } } // Token: 0x06007F69 RID: 32617 RVA: 0x001AB994 File Offset: 0x001A9B94 [Token(Token = "0x6007F69")] [Address(RVA = "0x4EE490", Offset = "0x4ECE90", VA = "0x1804EE490")] internal static AsymmetricKeyParameter GetNextWorkingKey(IList certs, int index) { int num; int num2; int num3; for (;;) { num = 0; if (num == 0 || num == 0) { goto IL_35; } num2 = 0; if (num != 0) { num3 = index + 1; if (num3 < num2 && num2 != 0) { break; } } } if (num2 == 0) { num3++; } DsaPublicKeyParameters dsaPublicKeyParameters = new DsaPublicKeyParameters(num, num2); IL_35: throw new NullReferenceException(); } // Token: 0x06007F6A RID: 32618 RVA: 0x001AB9DC File Offset: 0x001A9BDC [Token(Token = "0x6007F6A")] [Address(RVA = "0x4EEBF0", Offset = "0x4ED5F0", VA = "0x1804EEBF0")] internal static DateTime GetValidCertDateFromValidityModel(PkixParameters paramsPkix, PkixCertPath certPath, int index) { if (index > 0 && index == 0) { DerGeneralizedTime instance = DerGeneralizedTime.GetInstance(IsisMttObjectIdentifiers.IdIsisMtt); if (instance != 0) { return instance.ToDateTime(); } } return PkixCertPathValidatorUtilities.GetValidDate(paramsPkix); } // Token: 0x06007F6B RID: 32619 RVA: 0x001ABA14 File Offset: 0x001A9C14 [Token(Token = "0x6007F6B")] [Address(RVA = "0x4EC590", Offset = "0x4EAF90", VA = "0x1804EC590")] internal static ICollection FindCertificates(X509CertStoreSelector certSelect, IList certStores) { int num; do { num = 0; HashSet hashSet = new HashSet(); if (hashSet != 0) { if (hashSet != 0 && hashSet == 0) { goto IL_56; } if (hashSet != 0) { } if ((uint)(-1) != 0U) { } if ((ulong)((uint)(-1)) != (ulong)(-1L)) { } if (num != 0) { goto IL_4A; } } if ((uint)(-1) != 0U) { } if ((ulong)((uint)(-1)) != (ulong)(-1L)) { } } while (num != 0); throw new NullReferenceException(); IL_4A: throw new NullReferenceException(); IL_56: throw new NullReferenceException(); } // Token: 0x06007F6C RID: 32620 RVA: 0x001ABA7C File Offset: 0x001A9C7C [Token(Token = "0x6007F6C")] [Address(RVA = "0x4ED8D0", Offset = "0x4EC2D0", VA = "0x1804ED8D0")] internal static void GetCrlIssuersFromDistributionPoint(DistributionPoint dp, ICollection issuerPrincipals, X509CrlStoreSelector selector, PkixParameters pkixParams) { /* An exception occurred when decompiling this method (06007F6C) ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Pkix.PkixCertPathValidatorUtilities::GetCrlIssuersFromDistributionPoint(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509.DistributionPoint,System.Collections.ICollection,BestHTTP.SecureProtocol.Org.BouncyCastle.X509.Store.X509CrlStoreSelector,BestHTTP.SecureProtocol.Org.BouncyCastle.Pkix.PkixParameters) ---> System.Exception: Basic block has to end with unconditional control flow. { IL_AD: stloc:Exception(var_8_B7, newobj:Exception(Exception::.ctor, ldstr:string("CRL issuer is omitted from distribution point but no distributionPoint field present."))) } 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.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: 0x06007F6D RID: 32621 RVA: 0x001ABB44 File Offset: 0x001A9D44 [Token(Token = "0x6007F6D")] [Address(RVA = "0x4ED350", Offset = "0x4EBD50", VA = "0x1804ED350")] internal static ISet GetCompleteCrls(DistributionPoint dp, object cert, DateTime currentDate, PkixParameters paramsPKIX) { for (;;) { X509CrlStoreSelector x509CrlStoreSelector = new X509CrlStoreSelector(); HashSet hashSet = new HashSet(); if (cert != 0) { if (cert != 0) { if (cert == 0 || cert == 0) { continue; } } } IL_29: X509Name issuerPrincipal = PkixCertPathValidatorUtilities.GetIssuerPrincipal(cert); PkixCertPathValidatorUtilities.GetCrlIssuersFromDistributionPoint(dp, hashSet, x509CrlStoreSelector, paramsPKIX); if (cert == 0) { goto IL_59; } if (cert == 0) { int num = 0; if (cert == 0) { goto IL_59; } if (num != 0) { x509CrlStoreSelector.attrCertChecking = num; goto IL_59; } continue; } IL_6D: int num2 = 0; if (cert != 0) { x509CrlStoreSelector.certificateChecking = cert; goto IL_7B; } continue; IL_59: x509CrlStoreSelector.completeCrlEnabled = true; if (PkixCertPathValidatorUtilities.CrlUtilities.ToString() == 0) { goto IL_6D; } IL_7B: if (num2 == 0) { break; } continue; goto IL_29; } throw new IndexOutOfRangeException(); } // Token: 0x06007F6E RID: 32622 RVA: 0x001ABBEC File Offset: 0x001A9DEC [Token(Token = "0x6007F6E")] [Address(RVA = "0x4EDCB0", Offset = "0x4EC6B0", VA = "0x1804EDCB0")] internal static ISet GetDeltaCrls(DateTime currentDate, PkixParameters paramsPKIX, X509Crl completeCRL) { int num; do { num = 0; X509CrlStoreSelector x509CrlStoreSelector = new X509CrlStoreSelector(); IList list = Platform.CreateArrayList(); int version = completeCRL.Version; x509CrlStoreSelector.Issuers = list; DerObjectIdentifier crlNumber = X509Extensions.CrlNumber; Asn1Object extensionValue = PkixCertPathValidatorUtilities.GetExtensionValue(completeCRL, crlNumber); if (extensionValue != 0) { BigInteger positiveValue = DerInteger.GetInstance(extensionValue).PositiveValue; } DerObjectIdentifier issuingDistributionPoint = X509Extensions.IssuingDistributionPoint; Asn1Object extensionValue2 = PkixCertPathValidatorUtilities.GetExtensionValue(completeCRL, issuingDistributionPoint); byte[] derEncoded; if (extensionValue2 != 0) { derEncoded = extensionValue2.GetDerEncoded(); } if (num == 0) { } BigInteger one = BigInteger.One; BigInteger bigInteger; x509CrlStoreSelector.minCrlNumber = bigInteger; x509CrlStoreSelector.IssuingDistributionPoint = derEncoded; x509CrlStoreSelector.issuingDistributionPointEnabled = true; x509CrlStoreSelector.maxBaseCrlNumber = num; string text = PkixCertPathValidatorUtilities.CrlUtilities.ToString(); HashSet hashSet = new HashSet(); bool flag; if (hashSet != 0) { if (hashSet == 0) { } if (hashSet == 0) { goto IL_D1; } while (!flag) { } } if (flag) { } if (num != -1) { } } while (num != 0); throw new NullReferenceException(); IL_D1: throw new NullReferenceException(); } // Token: 0x06007F6F RID: 32623 RVA: 0x001ABCD0 File Offset: 0x001A9ED0 [Token(Token = "0x6007F6F")] [Address(RVA = "0x4F0A00", Offset = "0x4EF400", VA = "0x1804F0A00")] private static bool isDeltaCrl(X509Crl crl) { ISet nonCriticalExtensionOids = crl.GetNonCriticalExtensionOids(); DerObjectIdentifier deltaCrlIndicator = X509Extensions.DeltaCrlIndicator; throw new NullReferenceException(); } // Token: 0x06007F70 RID: 32624 RVA: 0x001ABCF0 File Offset: 0x001A9EF0 [Token(Token = "0x6007F70")] [Address(RVA = "0x4EC260", Offset = "0x4EAC60", VA = "0x1804EC260")] internal static ICollection FindCertificates(X509AttrCertStoreSelector certSelect, IList certStores) { int num; do { num = 0; HashSet hashSet = new HashSet(); if (hashSet != 0) { if (hashSet != 0 && hashSet == 0) { goto IL_56; } if (hashSet != 0) { } if ((uint)(-1) != 0U) { } if ((ulong)((uint)(-1)) != (ulong)(-1L)) { } if (num != 0) { goto IL_4A; } } if ((uint)(-1) != 0U) { } if ((ulong)((uint)(-1)) != (ulong)(-1L)) { } } while (num != 0); throw new NullReferenceException(); IL_4A: throw new NullReferenceException(); IL_56: throw new NullReferenceException(); } // Token: 0x06007F71 RID: 32625 RVA: 0x001ABD58 File Offset: 0x001A9F58 [Token(Token = "0x6007F71")] [Address(RVA = "0x4EC050", Offset = "0x4EAA50", VA = "0x1804EC050")] internal static void AddAdditionalStoresFromCrlDistributionPoint(CrlDistPoint crldp, PkixParameters pkixParams) { if (crldp != 0) { DistributionPoint[] distributionPoints = crldp.GetDistributionPoints(); int num = 0; int num2 = 0; int length = distributionPoints.Length; if (num2 < length) { DistributionPointName distributionPoint = distributionPoints[num].distributionPoint; if (distributionPoint != 0 && distributionPoint.type == 0) { GeneralName[] names = GeneralNames.GetInstance(distributionPoint.name).GetNames(); int num3 = 0; if (num3 < names.Length) { GeneralName generalName = names[num3]; if (generalName.tag == 6) { PkixCertPathValidatorUtilities.AddAdditionalStoreFromLocation(DerIA5String.GetInstance(generalName.obj).GetString(), pkixParams); } num3++; } } num++; } } } // Token: 0x06007F72 RID: 32626 RVA: 0x001ABE00 File Offset: 0x001AA000 [Token(Token = "0x6007F72")] [Address(RVA = "0x4EFC20", Offset = "0x4EE620", VA = "0x1804EFC20")] internal static bool ProcessCertD1i(int index, IList[] policyNodes, DerObjectIdentifier pOid, ISet pq) { int num; int num2; do { num = index - 1; IList list = policyNodes[num]; num2 = 0; if (0 >= num) { goto IL_40; } } while (num == 0); num2++; HashSet hashSet = new HashSet(); IList list2 = Platform.CreateArrayList(); string identifier = pOid.identifier; IList list3 = policyNodes[index]; return true; IL_40: throw new NullReferenceException(); } // Token: 0x06007F73 RID: 32627 RVA: 0x001ABE54 File Offset: 0x001AA054 [Token(Token = "0x6007F73")] [Address(RVA = "0x4EFEB0", Offset = "0x4EE8B0", VA = "0x1804EFEB0")] internal static void ProcessCertD1ii(int index, IList[] policyNodes, DerObjectIdentifier _poid, ISet _pq) { int num; int num2; do { num = index - 1; IList list = policyNodes[num]; num2 = 0; if (0 >= num) { return; } if (num == 0) { } } while (num == 0); string any_POLICY = PkixCertPathValidatorUtilities.ANY_POLICY; bool flag; if (!flag) { num2++; } HashSet hashSet = new HashSet(); IList list2 = Platform.CreateArrayList(); string identifier = _poid.identifier; IList list3 = policyNodes[index]; } // Token: 0x06007F74 RID: 32628 RVA: 0x001ABEB8 File Offset: 0x001AA0B8 [Token(Token = "0x6007F74")] [Address(RVA = "0x4EC8C0", Offset = "0x4EB2C0", VA = "0x1804EC8C0")] internal static ICollection FindIssuerCerts(X509Certificate cert, PkixBuilderParameters pkixParams) { X509CertStoreSelector x509CertStoreSelector = new X509CertStoreSelector(); HashSet hashSet = new HashSet(); BigInteger serialNumber = cert.SerialNumber; x509CertStoreSelector.subject = serialNumber; IList additionalStores = pkixParams.GetAdditionalStores(); ICollection collection = PkixCertPathValidatorUtilities.FindCertificates(x509CertStoreSelector, additionalStores); throw new NullReferenceException(); } // Token: 0x06007F75 RID: 32629 RVA: 0x001ABF08 File Offset: 0x001AA108 [Token(Token = "0x6007F75")] [Address(RVA = "0x4EE200", Offset = "0x4ECC00", VA = "0x1804EE200")] internal static Asn1Object GetExtensionValue(IX509Extension ext, DerObjectIdentifier oid) { int num = 0; num += num; num++; Asn1Object asn1Object; return asn1Object; } // Token: 0x06007F76 RID: 32630 RVA: 0x001ABF30 File Offset: 0x001AA130 [Token(Token = "0x6007F76")] [Address(RVA = "0x3C1670", Offset = "0x3C0070", VA = "0x1803C1670")] public PkixCertPathValidatorUtilities() { } // Token: 0x06007F77 RID: 32631 RVA: 0x001ABF44 File Offset: 0x001AA144 // Note: this type is marked as 'beforefieldinit'. [Token(Token = "0x6007F77")] [Address(RVA = "0x4F0510", Offset = "0x4EEF10", VA = "0x1804F0510")] static PkixCertPathValidatorUtilities() { string[] array = new string[11]; if ("unspecified" != 0) { } array[0] = "unspecified"; if ("keyCompromise" != 0) { } array[1] = "keyCompromise"; if ("cACompromise" != 0) { } array[2] = "cACompromise"; if ("affiliationChanged" != 0) { } array[3] = "affiliationChanged"; if ("superseded" != 0) { } array[4] = "superseded"; if ("cessationOfOperation" != 0) { } array[5] = "cessationOfOperation"; if ("certificateHold" != 0) { } array[6] = "certificateHold"; if ("unknown" != 0) { } array[7] = "unknown"; if ("removeFromCRL" != 0) { } array[8] = "removeFromCRL"; if ("privilegeWithdrawn" != 0) { } array[9] = "privilegeWithdrawn"; if ("aACompromise" != 0) { } array[10] = "aACompromise"; PkixCertPathValidatorUtilities.crlReasons = array; } // Token: 0x04005AA1 RID: 23201 [Token(Token = "0x4005AA1")] private static readonly PkixCrlUtilities CrlUtilities = new PkixCrlUtilities(); // Token: 0x04005AA2 RID: 23202 [Token(Token = "0x4005AA2")] internal static readonly string ANY_POLICY = "2.5.29.32.0"; // Token: 0x04005AA3 RID: 23203 [Token(Token = "0x4005AA3")] internal static readonly string CRL_NUMBER = X509Extensions.CrlNumber.identifier; // Token: 0x04005AA4 RID: 23204 [Token(Token = "0x4005AA4")] internal static readonly int KEY_CERT_SIGN; // Token: 0x04005AA5 RID: 23205 [Token(Token = "0x4005AA5")] internal static readonly int CRL_SIGN; // Token: 0x04005AA6 RID: 23206 [Token(Token = "0x4005AA6")] internal static readonly string[] crlReasons; } }