646 lines
25 KiB
C#
646 lines
25 KiB
C#
using System;
|
|
using BestHTTP.SecureProtocol.Org.BouncyCastle.Security;
|
|
using Cpp2IlInjected;
|
|
|
|
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Signers
|
|
{
|
|
// Token: 0x02001BB4 RID: 7092
|
|
[Token(Token = "0x2001BB4")]
|
|
public class Iso9796d2PssSigner : ISignerWithRecovery, ISigner
|
|
{
|
|
// Token: 0x0600B13E RID: 45374 RVA: 0x0026873C File Offset: 0x0026693C
|
|
[Token(Token = "0x600B13E")]
|
|
[Address(RVA = "0x423DE0", Offset = "0x422BE0", VA = "0x180423DE0", Slot = "5")]
|
|
public byte[] GetRecoveredMessage()
|
|
{
|
|
return this.recoveredMessage;
|
|
}
|
|
|
|
// Token: 0x0600B13F RID: 45375 RVA: 0x00268750 File Offset: 0x00266950
|
|
[Token(Token = "0x600B13F")]
|
|
[Address(RVA = "0x189CEC0", Offset = "0x189BCC0", VA = "0x18189CEC0")]
|
|
public Iso9796d2PssSigner(IAsymmetricBlockCipher cipher, IDigest digest, int saltLength, bool isImplicit)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600B13F)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Signers.Iso9796d2PssSigner::.ctor(BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IAsymmetricBlockCipher,BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IDigest,System.Int32,System.Boolean)
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{
|
|
IL_46:
|
|
stloc:ArgumentException(var_1_55, newobj:ArgumentException(ArgumentException::.ctor, ldstr:string("no valid trailer"), ldstr:string("digest")))
|
|
}
|
|
|
|
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 1660
|
|
*/;
|
|
}
|
|
|
|
// Token: 0x0600B140 RID: 45376 RVA: 0x002687B4 File Offset: 0x002669B4
|
|
[Token(Token = "0x600B140")]
|
|
[Address(RVA = "0x189CDA0", Offset = "0x189BBA0", VA = "0x18189CDA0")]
|
|
public Iso9796d2PssSigner(IAsymmetricBlockCipher cipher, IDigest digest, int saltLength)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600B140)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Void BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Signers.Iso9796d2PssSigner::.ctor(BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IAsymmetricBlockCipher,BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.IDigest,System.Int32)
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{
|
|
IL_39:
|
|
stloc:ArgumentException(var_1_48, newobj:ArgumentException(ArgumentException::.ctor, ldstr:string("no valid trailer"), ldstr:string("digest")))
|
|
}
|
|
|
|
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 1660
|
|
*/;
|
|
}
|
|
|
|
// Token: 0x17001BE9 RID: 7145
|
|
// (get) Token: 0x0600B141 RID: 45377 RVA: 0x0026880C File Offset: 0x00266A0C
|
|
[Token(Token = "0x17001BE9")]
|
|
public virtual string AlgorithmName
|
|
{
|
|
[Token(Token = "0x600B141")]
|
|
[Address(RVA = "0x189CFF0", Offset = "0x189BDF0", VA = "0x18189CFF0", Slot = "14")]
|
|
get
|
|
{
|
|
IDigest digest = this.digest;
|
|
return 0 + "withISO9796-2S2";
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600B142 RID: 45378 RVA: 0x00268834 File Offset: 0x00266A34
|
|
[Token(Token = "0x600B142")]
|
|
[Address(RVA = "0x189B8B0", Offset = "0x189A6B0", VA = "0x18189B8B0", Slot = "15")]
|
|
public virtual void Init(bool forSigning, ICipherParameters parameters)
|
|
{
|
|
while (parameters != 0)
|
|
{
|
|
if (parameters == 0)
|
|
{
|
|
if ((parameters == 0 && parameters == 0) || !forSigning)
|
|
{
|
|
continue;
|
|
}
|
|
int num = 0;
|
|
if (parameters == 0)
|
|
{
|
|
continue;
|
|
}
|
|
this.standardSalt = num;
|
|
int num2 = this.saltLength;
|
|
}
|
|
if (parameters != 0)
|
|
{
|
|
int num3 = 0;
|
|
if (forSigning)
|
|
{
|
|
this.random = num3;
|
|
break;
|
|
}
|
|
IL_5B:
|
|
IAsymmetricBlockCipher asymmetricBlockCipher = this.cipher;
|
|
int num4 = 0;
|
|
int num5;
|
|
this.keyBits = num5;
|
|
num5 += 7;
|
|
num4 += num5;
|
|
byte[] array = new byte[num4];
|
|
this.block = array;
|
|
if (this.trailer != 188)
|
|
{
|
|
IDigest digest = this.digest;
|
|
int num6 = array.Length;
|
|
num6 -= array;
|
|
}
|
|
IDigest digest2 = this.digest;
|
|
int num7 = array.Length;
|
|
num7 -= array;
|
|
byte[] array2 = new byte[num7];
|
|
this.mBuf = array2;
|
|
string algorithmName = ((ISigner)this).AlgorithmName;
|
|
return;
|
|
}
|
|
}
|
|
if (forSigning)
|
|
{
|
|
SecureRandom secureRandom = new SecureRandom();
|
|
this.random = secureRandom;
|
|
goto IL_5B;
|
|
}
|
|
goto IL_5B;
|
|
}
|
|
|
|
// Token: 0x0600B143 RID: 45379 RVA: 0x0026892C File Offset: 0x00266B2C
|
|
[Token(Token = "0x600B143")]
|
|
[Address(RVA = "0x189BC80", Offset = "0x189AA80", VA = "0x18189BC80")]
|
|
private bool IsSameAs(byte[] a, byte[] b)
|
|
{
|
|
int length = b.Length;
|
|
if (this.messageLength == length)
|
|
{
|
|
int num = 0;
|
|
int num2 = 0;
|
|
if (num2 != length)
|
|
{
|
|
num++;
|
|
}
|
|
}
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x0600B144 RID: 45380 RVA: 0x00268960 File Offset: 0x00266B60
|
|
[Token(Token = "0x600B144")]
|
|
[Address(RVA = "0x189B390", Offset = "0x189A190", VA = "0x18189B390")]
|
|
private void ClearBlock(byte[] block)
|
|
{
|
|
int length = block.Length;
|
|
int num = 0;
|
|
Array.Clear(block, num, length);
|
|
}
|
|
|
|
// Token: 0x0600B145 RID: 45381 RVA: 0x00268984 File Offset: 0x00266B84
|
|
[Token(Token = "0x600B145")]
|
|
[Address(RVA = "0x189C3C0", Offset = "0x189B1C0", VA = "0x18189C3C0", Slot = "16")]
|
|
public virtual void UpdateWithRecoveredMessage(byte[] signature)
|
|
{
|
|
int length;
|
|
int num;
|
|
do
|
|
{
|
|
IAsymmetricBlockCipher asymmetricBlockCipher = this.cipher;
|
|
length = signature.Length;
|
|
num = 0;
|
|
int num2 = this.keyBits;
|
|
num2 += 7;
|
|
num2 += typeof(IAsymmetricBlockCipher).TypeHandle;
|
|
int num3 = new byte[num2].Length;
|
|
num3 -= typeof(byte[]).TypeHandle;
|
|
if (asymmetricBlockCipher == 0)
|
|
{
|
|
goto IL_59;
|
|
}
|
|
}
|
|
while (IsoTrailers.NoTrailerAvailable(this.digest));
|
|
int num4 = IsoTrailers.GetTrailer(this.digest);
|
|
IL_59:
|
|
byte[] array = new byte[this.hLen];
|
|
IDigest digest = this.digest;
|
|
int num5 = this.hLen;
|
|
digest -= num5;
|
|
uint num6;
|
|
digest -= num6;
|
|
byte[] array2;
|
|
int length2 = array2.Length;
|
|
if (num != length2)
|
|
{
|
|
num++;
|
|
}
|
|
if (num < 0)
|
|
{
|
|
num++;
|
|
}
|
|
bool flag = num > 1;
|
|
this.fullMessage = flag;
|
|
int num7 = array2.Length;
|
|
num7 -= num;
|
|
byte[] array3 = new byte[num7];
|
|
this.recoveredMessage = array3;
|
|
int length3 = array3.Length;
|
|
byte[] array4 = this.recoveredMessage;
|
|
byte[] array5 = this.mBuf;
|
|
this.preBlock = length;
|
|
this.preMStart = num;
|
|
this.preTLength = (int)num6;
|
|
this.preSig = signature;
|
|
}
|
|
|
|
// Token: 0x0600B146 RID: 45382 RVA: 0x00268AB4 File Offset: 0x00266CB4
|
|
[Token(Token = "0x600B146")]
|
|
[Address(RVA = "0x189C7D0", Offset = "0x189B5D0", VA = "0x18189C7D0", Slot = "17")]
|
|
public virtual void Update(byte input)
|
|
{
|
|
if (this.preSig == (ulong)0L)
|
|
{
|
|
byte[] array = this.mBuf;
|
|
int num = this.messageLength;
|
|
if (num < array.Length)
|
|
{
|
|
int num2 = num + 1;
|
|
this.messageLength = num2;
|
|
return;
|
|
}
|
|
}
|
|
IDigest digest = this.digest;
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x0600B147 RID: 45383 RVA: 0x00268AFC File Offset: 0x00266CFC
|
|
[Token(Token = "0x600B147")]
|
|
[Address(RVA = "0x189B2B0", Offset = "0x189A0B0", VA = "0x18189B2B0", Slot = "18")]
|
|
public virtual void BlockUpdate(byte[] input, int inOff, int length)
|
|
{
|
|
if (this.preSig == (ulong)0L)
|
|
{
|
|
if (length > 0)
|
|
{
|
|
int length2 = this.mBuf.Length;
|
|
if (this.messageLength >= length2)
|
|
{
|
|
goto IL_27;
|
|
}
|
|
}
|
|
return;
|
|
}
|
|
IL_27:
|
|
while (length <= 0)
|
|
{
|
|
}
|
|
IDigest digest = this.digest;
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x0600B148 RID: 45384 RVA: 0x00268B40 File Offset: 0x00266D40
|
|
[Token(Token = "0x600B148")]
|
|
[Address(RVA = "0x189C300", Offset = "0x189B100", VA = "0x18189C300", Slot = "19")]
|
|
public virtual void Reset()
|
|
{
|
|
IDigest digest = this.digest;
|
|
byte[] array = this.mBuf;
|
|
int num = 0;
|
|
this.messageLength = num;
|
|
if (array != 0)
|
|
{
|
|
int length = array.Length;
|
|
int num2 = 0;
|
|
Array.Clear(array, num2, length);
|
|
}
|
|
byte[] array2 = this.recoveredMessage;
|
|
if (array2 != 0)
|
|
{
|
|
int length2 = array2.Length;
|
|
int num3 = 0;
|
|
Array.Clear(array2, num3, length2);
|
|
this.recoveredMessage = num;
|
|
}
|
|
this.fullMessage = num != 0;
|
|
if (this.preSig != num)
|
|
{
|
|
byte[] array3 = this.preBlock;
|
|
this.preSig = num;
|
|
int length3 = array3.Length;
|
|
int num4 = 0;
|
|
Array.Clear(array3, num4, length3);
|
|
this.preBlock = num;
|
|
}
|
|
}
|
|
|
|
// Token: 0x0600B149 RID: 45385 RVA: 0x00268BEC File Offset: 0x00266DEC
|
|
[Token(Token = "0x600B149")]
|
|
[Address(RVA = "0x189B3C0", Offset = "0x189A1C0", VA = "0x18189B3C0", Slot = "20")]
|
|
public virtual byte[] GenerateSignature()
|
|
{
|
|
IDigest digest = this.digest;
|
|
byte[] array = new byte[0];
|
|
IDigest digest2 = this.digest;
|
|
int num = 0;
|
|
byte[] array2 = new byte[0];
|
|
int num2 = this.messageLength;
|
|
this.LtoOSP((long)num2, array2);
|
|
IDigest digest3 = this.digest;
|
|
int length = array2.Length;
|
|
IDigest digest4 = this.digest;
|
|
int num3 = this.messageLength;
|
|
IDigest digest5 = this.digest;
|
|
int length2 = array.Length;
|
|
byte[] array3 = this.standardSalt;
|
|
if (array3 == 0)
|
|
{
|
|
byte[] array4 = new byte[this.saltLength];
|
|
double num4 = this.random.NextDouble();
|
|
}
|
|
IDigest digest6 = this.digest;
|
|
int length3 = array3.Length;
|
|
IDigest digest7 = this.digest;
|
|
byte[] array5 = new byte[length3];
|
|
IDigest digest8 = this.digest;
|
|
byte[] array6 = this.block;
|
|
bool flag = this.trailer != 188;
|
|
int num5 = array6.Length;
|
|
num5 -= (flag ? 1 : 0);
|
|
int num6 = this.messageLength;
|
|
int num7 = 0;
|
|
byte[] array7 = this.block;
|
|
Array.Copy(this.mBuf, num7, array7, num5, num6);
|
|
int num8 = this.messageLength;
|
|
int num9 = 0;
|
|
int length4 = array3.Length;
|
|
num8 += num5;
|
|
byte[] array8 = this.block;
|
|
Array.Copy(array3, num9, array8, num8, length4);
|
|
int num10 = this.block.Length;
|
|
int num11 = 0;
|
|
int length5 = array5.Length;
|
|
num10 -= (flag ? 1 : 0);
|
|
int length6 = this.MaskGeneratorFunction1(array5, num11, length5, num10).Length;
|
|
byte[] array9 = this.block;
|
|
if (num != length6)
|
|
{
|
|
num++;
|
|
}
|
|
int num12 = this.hLen;
|
|
int num13 = 0;
|
|
int num14 = array9.Length;
|
|
num14 -= num12;
|
|
num14 -= (flag ? 1 : 0);
|
|
Array.Copy(array5, num13, array9, num14, num12);
|
|
int num15 = this.trailer;
|
|
byte[] array10 = this.block;
|
|
int length8;
|
|
if (num15 != 188)
|
|
{
|
|
int length7 = array10.Length;
|
|
length8 = this.block.Length;
|
|
int num16 = this.trailer;
|
|
int num17 = length8 - 1;
|
|
}
|
|
int num18 = length8 - 1;
|
|
byte[] array11 = this.block;
|
|
byte[] array12 = this.block;
|
|
IAsymmetricBlockCipher asymmetricBlockCipher = this.cipher;
|
|
int length9 = array12.Length;
|
|
byte[] array13 = this.mBuf;
|
|
int length10 = array13.Length;
|
|
int num19 = 0;
|
|
Array.Clear(array13, num19, length10);
|
|
byte[] array14 = this.block;
|
|
int length11 = array14.Length;
|
|
int num20 = 0;
|
|
Array.Clear(array14, num20, length11);
|
|
this.messageLength = num;
|
|
throw new NullReferenceException();
|
|
}
|
|
|
|
// Token: 0x0600B14A RID: 45386 RVA: 0x00268E54 File Offset: 0x00267054
|
|
[Token(Token = "0x600B14A")]
|
|
[Address(RVA = "0x189C880", Offset = "0x189B680", VA = "0x18189C880", Slot = "21")]
|
|
public virtual bool VerifySignature(byte[] signature)
|
|
{
|
|
/*
|
|
An exception occurred when decompiling this method (0600B14A)
|
|
|
|
ICSharpCode.Decompiler.DecompilerException: Error decompiling System.Boolean BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Signers.Iso9796d2PssSigner::VerifySignature(System.Byte[])
|
|
|
|
---> System.Exception: Basic block has to end with unconditional control flow.
|
|
{
|
|
IL_1EF:
|
|
stloc:InvalidOperationException(var_42_1F9, newobj:InvalidOperationException(InvalidOperationException::.ctor, ldstr:string("UpdateWithRecoveredMessage called on different signature")))
|
|
}
|
|
|
|
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 1660
|
|
*/;
|
|
}
|
|
|
|
// Token: 0x0600B14B RID: 45387 RVA: 0x0026905C File Offset: 0x0026725C
|
|
[Token(Token = "0x600B14B")]
|
|
[Address(RVA = "0x40FFA0", Offset = "0x40EDA0", VA = "0x18040FFA0", Slot = "22")]
|
|
public virtual bool HasFullMessage()
|
|
{
|
|
return this.fullMessage;
|
|
}
|
|
|
|
// Token: 0x0600B14C RID: 45388 RVA: 0x00269070 File Offset: 0x00267270
|
|
[Token(Token = "0x600B14C")]
|
|
[Address(RVA = "0x189BD10", Offset = "0x189AB10", VA = "0x18189BD10")]
|
|
private void ItoOSP(int i, byte[] sp)
|
|
{
|
|
sp[0] = (byte)i;
|
|
sp[0] = (byte)i;
|
|
sp[0] = (byte)i;
|
|
sp[0] = (byte)i;
|
|
}
|
|
|
|
// Token: 0x0600B14D RID: 45389 RVA: 0x002690A4 File Offset: 0x002672A4
|
|
[Token(Token = "0x600B14D")]
|
|
[Address(RVA = "0x189BDA0", Offset = "0x189ABA0", VA = "0x18189BDA0")]
|
|
private void LtoOSP(long l, byte[] sp)
|
|
{
|
|
sp[0] = (byte)l;
|
|
sp[0] = (byte)l;
|
|
sp[0] = (byte)l;
|
|
sp[0] = (byte)l;
|
|
sp[0] = (byte)l;
|
|
sp[0] = (byte)l;
|
|
sp[0] = (byte)l;
|
|
sp[0] = (byte)l;
|
|
}
|
|
|
|
// Token: 0x0600B14E RID: 45390 RVA: 0x002690F8 File Offset: 0x002672F8
|
|
[Token(Token = "0x600B14E")]
|
|
[Address(RVA = "0x189BEE0", Offset = "0x189ACE0", VA = "0x18189BEE0")]
|
|
private byte[] MaskGeneratorFunction1(byte[] Z, int zOff, int zLen, int length)
|
|
{
|
|
byte[] array = new byte[0];
|
|
byte[] array2 = new byte[this.hLen];
|
|
byte[] array3 = new byte[4];
|
|
IDigest digest = this.digest;
|
|
int num = 0;
|
|
array3[0] = (byte)num;
|
|
array3[0] = (byte)num;
|
|
array3[0] = (byte)num;
|
|
array3[0] = (byte)num;
|
|
IDigest digest2 = this.digest;
|
|
int num2 = 0;
|
|
if (num2 < digest)
|
|
{
|
|
num2 += num2;
|
|
num2++;
|
|
}
|
|
IDigest digest3 = this.digest;
|
|
int num3 = 0;
|
|
if (num3 < zOff)
|
|
{
|
|
num3 += num3;
|
|
num3++;
|
|
}
|
|
int num4 = 0;
|
|
IDigest digest4 = this.digest;
|
|
int num5 = 0;
|
|
if (num5 < num4)
|
|
{
|
|
num5 += num5;
|
|
num5++;
|
|
}
|
|
int num6 = this.hLen;
|
|
int num7 = num6 * num;
|
|
int num8 = 0;
|
|
Array.Copy(array2, num8, array, num7, num6);
|
|
int num9 = this.hLen;
|
|
this.ItoOSP(1, array3);
|
|
IDigest digest5 = this.digest;
|
|
IDigest digest6 = this.digest;
|
|
int length2 = array3.Length;
|
|
IDigest digest7 = this.digest;
|
|
int num10 = this.hLen;
|
|
int num11 = array.Length;
|
|
int num12 = 0;
|
|
num11 -= num10;
|
|
Array.Copy(array2, num12, array, num10, num11);
|
|
return array;
|
|
}
|
|
|
|
// Token: 0x040070CC RID: 28876
|
|
[Token(Token = "0x40070CC")]
|
|
[Obsolete]
|
|
public const int TrailerImplicit = 188;
|
|
|
|
// Token: 0x040070CD RID: 28877
|
|
[Token(Token = "0x40070CD")]
|
|
[Obsolete]
|
|
public const int TrailerRipeMD160 = 12748;
|
|
|
|
// Token: 0x040070CE RID: 28878
|
|
[Token(Token = "0x40070CE")]
|
|
[Obsolete]
|
|
public const int TrailerRipeMD128 = 13004;
|
|
|
|
// Token: 0x040070CF RID: 28879
|
|
[Token(Token = "0x40070CF")]
|
|
[Obsolete]
|
|
public const int TrailerSha1 = 13260;
|
|
|
|
// Token: 0x040070D0 RID: 28880
|
|
[Token(Token = "0x40070D0")]
|
|
[Obsolete]
|
|
public const int TrailerSha256 = 13516;
|
|
|
|
// Token: 0x040070D1 RID: 28881
|
|
[Token(Token = "0x40070D1")]
|
|
[Obsolete]
|
|
public const int TrailerSha512 = 13772;
|
|
|
|
// Token: 0x040070D2 RID: 28882
|
|
[Token(Token = "0x40070D2")]
|
|
[Obsolete]
|
|
public const int TrailerSha384 = 14028;
|
|
|
|
// Token: 0x040070D3 RID: 28883
|
|
[Token(Token = "0x40070D3")]
|
|
[Obsolete]
|
|
public const int TrailerWhirlpool = 14284;
|
|
|
|
// Token: 0x040070D4 RID: 28884
|
|
[FieldOffset(Offset = "0x10")]
|
|
[Token(Token = "0x40070D4")]
|
|
private IDigest digest;
|
|
|
|
// Token: 0x040070D5 RID: 28885
|
|
[FieldOffset(Offset = "0x18")]
|
|
[Token(Token = "0x40070D5")]
|
|
private IAsymmetricBlockCipher cipher;
|
|
|
|
// Token: 0x040070D6 RID: 28886
|
|
[FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x40070D6")]
|
|
private SecureRandom random;
|
|
|
|
// Token: 0x040070D7 RID: 28887
|
|
[FieldOffset(Offset = "0x28")]
|
|
[Token(Token = "0x40070D7")]
|
|
private byte[] standardSalt;
|
|
|
|
// Token: 0x040070D8 RID: 28888
|
|
[FieldOffset(Offset = "0x30")]
|
|
[Token(Token = "0x40070D8")]
|
|
private int hLen;
|
|
|
|
// Token: 0x040070D9 RID: 28889
|
|
[FieldOffset(Offset = "0x34")]
|
|
[Token(Token = "0x40070D9")]
|
|
private int trailer;
|
|
|
|
// Token: 0x040070DA RID: 28890
|
|
[FieldOffset(Offset = "0x38")]
|
|
[Token(Token = "0x40070DA")]
|
|
private int keyBits;
|
|
|
|
// Token: 0x040070DB RID: 28891
|
|
[FieldOffset(Offset = "0x40")]
|
|
[Token(Token = "0x40070DB")]
|
|
private byte[] block;
|
|
|
|
// Token: 0x040070DC RID: 28892
|
|
[FieldOffset(Offset = "0x48")]
|
|
[Token(Token = "0x40070DC")]
|
|
private byte[] mBuf;
|
|
|
|
// Token: 0x040070DD RID: 28893
|
|
[FieldOffset(Offset = "0x50")]
|
|
[Token(Token = "0x40070DD")]
|
|
private int messageLength;
|
|
|
|
// Token: 0x040070DE RID: 28894
|
|
[FieldOffset(Offset = "0x54")]
|
|
[Token(Token = "0x40070DE")]
|
|
private readonly int saltLength;
|
|
|
|
// Token: 0x040070DF RID: 28895
|
|
[FieldOffset(Offset = "0x58")]
|
|
[Token(Token = "0x40070DF")]
|
|
private bool fullMessage;
|
|
|
|
// Token: 0x040070E0 RID: 28896
|
|
[FieldOffset(Offset = "0x60")]
|
|
[Token(Token = "0x40070E0")]
|
|
private byte[] recoveredMessage;
|
|
|
|
// Token: 0x040070E1 RID: 28897
|
|
[FieldOffset(Offset = "0x68")]
|
|
[Token(Token = "0x40070E1")]
|
|
private byte[] preSig;
|
|
|
|
// Token: 0x040070E2 RID: 28898
|
|
[FieldOffset(Offset = "0x70")]
|
|
[Token(Token = "0x40070E2")]
|
|
private byte[] preBlock;
|
|
|
|
// Token: 0x040070E3 RID: 28899
|
|
[FieldOffset(Offset = "0x78")]
|
|
[Token(Token = "0x40070E3")]
|
|
private int preMStart;
|
|
|
|
// Token: 0x040070E4 RID: 28900
|
|
[FieldOffset(Offset = "0x7C")]
|
|
[Token(Token = "0x40070E4")]
|
|
private int preTLength;
|
|
}
|
|
}
|