256 lines
15 KiB
C#
256 lines
15 KiB
C#
using System;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Oiw;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.X509;
|
|
using Cpp2IlInjected;
|
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs
|
|
{
|
|
// Token: 0x02001F7B RID: 8059
|
|
[Token(Token = "0x2001F7B")]
|
|
public class RsassaPssParameters : Asn1Encodable
|
|
{
|
|
// Token: 0x0600C9D5 RID: 51669 RVA: 0x002DC3CC File Offset: 0x002DA5CC
|
|
[Token(Token = "0x600C9D5")]
|
|
[Address(RVA = "0x2F8FBD0", Offset = "0x2F8EBD0", VA = "0x182F8FBD0")]
|
|
public static RsassaPssParameters GetInstance(object obj)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600C9D5)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs.RsassaPssParameters BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs.RsassaPssParameters::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: 0x0600C9D6 RID: 51670 RVA: 0x002DC420 File Offset: 0x002DA620
|
|
[Token(Token = "0x600C9D6")]
|
|
[Address(RVA = "0x2F90650", Offset = "0x2F8F650", VA = "0x182F90650")]
|
|
public RsassaPssParameters()
|
|
{
|
|
AlgorithmIdentifier defaultHashAlgorithm = RsassaPssParameters.DefaultHashAlgorithm;
|
|
this.hashAlgorithm = defaultHashAlgorithm;
|
|
AlgorithmIdentifier defaultMaskGenFunction = RsassaPssParameters.DefaultMaskGenFunction;
|
|
this.maskGenAlgorithm = defaultMaskGenFunction;
|
|
DerInteger defaultSaltLength = RsassaPssParameters.DefaultSaltLength;
|
|
this.saltLength = defaultSaltLength;
|
|
DerInteger defaultTrailerField = RsassaPssParameters.DefaultTrailerField;
|
|
this.trailerField = defaultTrailerField;
|
|
}
|
|
|
|
// Token: 0x0600C9D7 RID: 51671 RVA: 0x002DC468 File Offset: 0x002DA668
|
|
[Token(Token = "0x600C9D7")]
|
|
[Address(RVA = "0xC5DB60", Offset = "0xC5CB60", VA = "0x180C5DB60")]
|
|
public RsassaPssParameters(AlgorithmIdentifier hashAlgorithm, AlgorithmIdentifier maskGenAlgorithm, DerInteger saltLength, DerInteger trailerField)
|
|
{
|
|
this.hashAlgorithm = hashAlgorithm;
|
|
this.saltLength = saltLength;
|
|
this.trailerField = 0;
|
|
this.maskGenAlgorithm = maskGenAlgorithm;
|
|
}
|
|
|
|
// Token: 0x0600C9D8 RID: 51672 RVA: 0x002DC498 File Offset: 0x002DA698
|
|
[Token(Token = "0x600C9D8")]
|
|
[Address(RVA = "0x2F90430", Offset = "0x2F8F430", VA = "0x182F90430")]
|
|
public RsassaPssParameters(Asn1Sequence seq)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600C9D8)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Pkcs.RsassaPssParameters::.ctor(BestHTTP.SecureProtocol.Org.BouncyCastle.Asn1.Asn1Sequence)
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{
|
|
IL_9E:
|
|
stloc:ArgumentException(var_13_A8, newobj:ArgumentException(ArgumentException::.ctor, ldstr:string("unknown tag")))
|
|
}
|
|
|
|
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.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.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.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: 0x17001F65 RID: 8037
|
|
// (get) Token: 0x0600C9D9 RID: 51673 RVA: 0x002DC550 File Offset: 0x002DA750
|
|
[Token(Token = "0x17001F65")]
|
|
public AlgorithmIdentifier HashAlgorithm
|
|
{
|
|
[Token(Token = "0x600C9D9")]
|
|
[Address(RVA = "0x411530", Offset = "0x410530", VA = "0x180411530")]
|
|
get
|
|
{
|
|
return this.hashAlgorithm;
|
|
}
|
|
}
|
|
|
|
// Token: 0x17001F66 RID: 8038
|
|
// (get) Token: 0x0600C9DA RID: 51674 RVA: 0x002DC564 File Offset: 0x002DA764
|
|
[Token(Token = "0x17001F66")]
|
|
public AlgorithmIdentifier MaskGenAlgorithm
|
|
{
|
|
[Token(Token = "0x600C9DA")]
|
|
[Address(RVA = "0x4157B0", Offset = "0x4147B0", VA = "0x1804157B0")]
|
|
get
|
|
{
|
|
return this.maskGenAlgorithm;
|
|
}
|
|
}
|
|
|
|
// Token: 0x17001F67 RID: 8039
|
|
// (get) Token: 0x0600C9DB RID: 51675 RVA: 0x002DC578 File Offset: 0x002DA778
|
|
[Token(Token = "0x17001F67")]
|
|
public DerInteger SaltLength
|
|
{
|
|
[Token(Token = "0x600C9DB")]
|
|
[Address(RVA = "0x4157C0", Offset = "0x4147C0", VA = "0x1804157C0")]
|
|
get
|
|
{
|
|
return this.saltLength;
|
|
}
|
|
}
|
|
|
|
// Token: 0x17001F68 RID: 8040
|
|
// (get) Token: 0x0600C9DC RID: 51676 RVA: 0x002DC58C File Offset: 0x002DA78C
|
|
[Token(Token = "0x17001F68")]
|
|
public DerInteger TrailerField
|
|
{
|
|
[Token(Token = "0x600C9DC")]
|
|
[Address(RVA = "0x4157D0", Offset = "0x4147D0", VA = "0x1804157D0")]
|
|
get
|
|
{
|
|
return this.trailerField;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600C9DD RID: 51677 RVA: 0x002DC5A0 File Offset: 0x002DA7A0
|
|
[Token(Token = "0x600C9DD")]
|
|
[Address(RVA = "0x2F8FDD0", Offset = "0x2F8EDD0", VA = "0x182F8FDD0", Slot = "5")]
|
|
public override Asn1Object ToAsn1Object()
|
|
{
|
|
AlgorithmIdentifier algorithmIdentifier = this.hashAlgorithm;
|
|
Asn1Encodable[] array = new Asn1Encodable[0];
|
|
AlgorithmIdentifier algorithmIdentifier2 = this.hashAlgorithm;
|
|
int num;
|
|
DerTaggedObject derTaggedObject = new DerTaggedObject(true, num, algorithmIdentifier2);
|
|
num = 0;
|
|
if (derTaggedObject != 0)
|
|
{
|
|
}
|
|
array[0] = derTaggedObject;
|
|
Asn1EncodableVector asn1EncodableVector;
|
|
asn1EncodableVector.Add(array);
|
|
AlgorithmIdentifier algorithmIdentifier3 = this.maskGenAlgorithm;
|
|
Asn1Encodable[] array2 = new Asn1Encodable[1];
|
|
AlgorithmIdentifier algorithmIdentifier4 = this.maskGenAlgorithm;
|
|
DerTaggedObject derTaggedObject2 = new DerTaggedObject(16777216 != 0, 16777216, algorithmIdentifier4);
|
|
if (derTaggedObject2 != 0)
|
|
{
|
|
}
|
|
array2[0] = derTaggedObject2;
|
|
asn1EncodableVector.Add(array2);
|
|
DerInteger derInteger = this.saltLength;
|
|
Asn1Encodable[] array3 = new Asn1Encodable[1];
|
|
DerInteger derInteger2 = this.saltLength;
|
|
DerTaggedObject derTaggedObject3 = new DerTaggedObject(true, 2, derInteger2);
|
|
if (derTaggedObject3 != 0)
|
|
{
|
|
}
|
|
array3[0] = derTaggedObject3;
|
|
asn1EncodableVector.Add(array3);
|
|
DerInteger derInteger3 = this.trailerField;
|
|
Asn1Encodable[] array4 = new Asn1Encodable[1];
|
|
DerInteger derInteger4 = this.trailerField;
|
|
DerTaggedObject derTaggedObject4 = new DerTaggedObject(true, 3, derInteger4);
|
|
if (derTaggedObject4 != 0)
|
|
{
|
|
}
|
|
array4[0] = derTaggedObject4;
|
|
asn1EncodableVector.Add(array4);
|
|
DerSequence derSequence = new DerSequence(asn1EncodableVector);
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x0600C9DE RID: 51678 RVA: 0x002DC6AC File Offset: 0x002DA8AC
|
|
// Note: this type is marked as 'beforefieldinit'.
|
|
[Token(Token = "0x600C9DE")]
|
|
[Address(RVA = "0x2F90280", Offset = "0x2F8F280", VA = "0x182F90280")]
|
|
static RsassaPssParameters()
|
|
{
|
|
DerObjectIdentifier idSha = OiwObjectIdentifiers.IdSha1;
|
|
DerNull instance = DerNull.Instance;
|
|
RsassaPssParameters.DefaultHashAlgorithm = new AlgorithmIdentifier(idSha, instance);
|
|
DerObjectIdentifier idMgf = PkcsObjectIdentifiers.IdMgf1;
|
|
AlgorithmIdentifier defaultHashAlgorithm = RsassaPssParameters.DefaultHashAlgorithm;
|
|
RsassaPssParameters.DefaultMaskGenFunction = new AlgorithmIdentifier(idMgf, defaultHashAlgorithm);
|
|
RsassaPssParameters.DefaultSaltLength = new DerInteger(20);
|
|
RsassaPssParameters.DefaultTrailerField = new DerInteger(1);
|
|
}
|
|
|
|
// Token: 0x04007F7C RID: 32636
|
|
[FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x4007F7C")]
|
|
private AlgorithmIdentifier hashAlgorithm;
|
|
|
|
// Token: 0x04007F7D RID: 32637
|
|
[FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x4007F7D")]
|
|
private AlgorithmIdentifier maskGenAlgorithm;
|
|
|
|
// Token: 0x04007F7E RID: 32638
|
|
[FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x4007F7E")]
|
|
private DerInteger saltLength;
|
|
|
|
// Token: 0x04007F7F RID: 32639
|
|
[FieldOffset(Offset = "0x28")]
|
|
[Token(Token = "0x4007F7F")]
|
|
private DerInteger trailerField;
|
|
|
|
// Token: 0x04007F80 RID: 32640
|
|
[Token(Token = "0x4007F80")]
|
|
public static readonly AlgorithmIdentifier DefaultHashAlgorithm;
|
|
|
|
// Token: 0x04007F81 RID: 32641
|
|
[Token(Token = "0x4007F81")]
|
|
public static readonly AlgorithmIdentifier DefaultMaskGenFunction;
|
|
|
|
// Token: 0x04007F82 RID: 32642
|
|
[Token(Token = "0x4007F82")]
|
|
public static readonly DerInteger DefaultSaltLength;
|
|
|
|
// Token: 0x04007F83 RID: 32643
|
|
[Token(Token = "0x4007F83")]
|
|
public static readonly DerInteger DefaultTrailerField;
|
|
}
|
|
}
|