107 lines
3.0 KiB
C#
107 lines
3.0 KiB
C#
using System;
|
|
using System.Collections;
|
|
using System.Runtime.InteropServices;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities.Collections;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.X509;
|
|
using Cpp2IlInjected;
|
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Pkix
|
|
{
|
|
// Token: 0x0200139B RID: 5019
|
|
[Token(Token = "0x200139B")]
|
|
[StructLayout(3)]
|
|
public class PkixCertPathBuilder
|
|
{
|
|
// Token: 0x06007F3A RID: 32570 RVA: 0x001AACF4 File Offset: 0x001A8EF4
|
|
[Token(Token = "0x6007F3A")]
|
|
[Address(RVA = "0x4EABD0", Offset = "0x4E95D0", VA = "0x1804EABD0", Slot = "4")]
|
|
public virtual PkixCertPathBuilderResult Build(PkixBuilderParameters pkixParams)
|
|
{
|
|
int num;
|
|
ICollection collection;
|
|
do
|
|
{
|
|
num = 0;
|
|
HashSet hashSet = new HashSet();
|
|
IList additionalStores = pkixParams.GetAdditionalStores();
|
|
}
|
|
while (collection != 0);
|
|
PkixCertPathBuilderResult pkixCertPathBuilderResult;
|
|
if (Platform.CreateArrayList() != 0)
|
|
{
|
|
while (pkixCertPathBuilderResult == 0)
|
|
{
|
|
}
|
|
}
|
|
if (pkixCertPathBuilderResult != 0)
|
|
{
|
|
}
|
|
if (num != -1)
|
|
{
|
|
}
|
|
if (num == 0 && (pkixCertPathBuilderResult != 0 || this.certPathException == pkixCertPathBuilderResult))
|
|
{
|
|
return pkixCertPathBuilderResult;
|
|
}
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x06007F3B RID: 32571 RVA: 0x001AADBC File Offset: 0x001A8FBC
|
|
[Token(Token = "0x6007F3B")]
|
|
[Address(RVA = "0x4EB250", Offset = "0x4E9C50", VA = "0x1804EB250", Slot = "5")]
|
|
protected virtual PkixCertPathBuilderResult Build(X509Certificate tbvCert, PkixBuilderParameters pkixParams, IList tbvPath)
|
|
{
|
|
int num = 0;
|
|
PkixCertPathValidator pkixCertPathValidator = new PkixCertPathValidator();
|
|
bool flag;
|
|
int count;
|
|
if (!flag)
|
|
{
|
|
PkixCertPathValidatorUtilities.AddAdditionalStoresFromAltNames(tbvCert, pkixParams);
|
|
HashSet hashSet = new HashSet();
|
|
ICollection collection = PkixCertPathValidatorUtilities.FindIssuerCerts(tbvCert, pkixParams);
|
|
if (hashSet.GetEnumerator() == 0)
|
|
{
|
|
count = hashSet.Count;
|
|
if (count != 0)
|
|
{
|
|
while (count == 0)
|
|
{
|
|
}
|
|
}
|
|
if (count != 0)
|
|
{
|
|
}
|
|
if (num != -1)
|
|
{
|
|
}
|
|
if (num == 0)
|
|
{
|
|
goto IL_4A;
|
|
}
|
|
}
|
|
Exception ex = new Exception("No issuer certificate for certificate in certification path found.");
|
|
throw new NullReferenceException();
|
|
}
|
|
IL_4A:
|
|
PkixCertPath pkixCertPath = new PkixCertPath(tbvPath);
|
|
string text = count.ToString();
|
|
PkixCertPathBuilderResult pkixCertPathBuilderResult;
|
|
return pkixCertPathBuilderResult;
|
|
}
|
|
|
|
// Token: 0x06007F3C RID: 32572 RVA: 0x001AAEA0 File Offset: 0x001A90A0
|
|
[Token(Token = "0x6007F3C")]
|
|
[Address(RVA = "0x3C1670", Offset = "0x3C0070", VA = "0x1803C1670")]
|
|
public PkixCertPathBuilder()
|
|
{
|
|
}
|
|
|
|
// Token: 0x04005A99 RID: 23193
|
|
[global::Cpp2IlInjected.FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x4005A99")]
|
|
private Exception certPathException;
|
|
}
|
|
}
|