Files
27Aug2021-Cpp2IL-Dump/Assembly-CSharp/BestHTTP/SecureProtocol/Org/BouncyCastle/Crypto/Prng/Drbg/DrbgUtilities.cs
T
niko c12fbe3fc6 m
2026-04-12 16:51:38 +02:00

130 lines
3.1 KiB
C#

using System;
using System.Collections;
using BestHTTP.SecureProtocol.Org.BouncyCastle.Utilities;
using Cpp2IlInjected;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto.Prng.Drbg
{
// Token: 0x02001CB4 RID: 7348
[Token(Token = "0x2001CB4")]
internal class DrbgUtilities
{
// Token: 0x0600B5F0 RID: 46576 RVA: 0x002760F4 File Offset: 0x002742F4
[Token(Token = "0x600B5F0")]
[Address(RVA = "0x2355430", Offset = "0x2354430", VA = "0x182355430")]
static DrbgUtilities()
{
IDictionary dictionary = Platform.CreateHashtable();
}
// Token: 0x0600B5F1 RID: 46577 RVA: 0x00276110 File Offset: 0x00274310
[Token(Token = "0x600B5F1")]
[Address(RVA = "0x2354CE0", Offset = "0x2353CE0", VA = "0x182354CE0")]
internal static int GetMaxSecurityStrength(IDigest d)
{
throw new NullReferenceException();
}
// Token: 0x0600B5F2 RID: 46578 RVA: 0x00276124 File Offset: 0x00274324
[Token(Token = "0x600B5F2")]
[Address(RVA = "0x2354DB0", Offset = "0x2353DB0", VA = "0x182354DB0")]
internal static int GetMaxSecurityStrength(IMac m)
{
throw new NullReferenceException();
}
// Token: 0x0600B5F3 RID: 46579 RVA: 0x00276140 File Offset: 0x00274340
[Token(Token = "0x600B5F3")]
[Address(RVA = "0x2354EB0", Offset = "0x2353EB0", VA = "0x182354EB0")]
internal static byte[] HashDF(IDigest digest, byte[] seedMaterial, int seedLength)
{
byte[] array = new byte[seedMaterial];
byte[] array2 = new byte[array.Length];
int num = 0;
if (num < digest)
{
num += num;
num++;
}
num += num;
num++;
num += num;
num++;
num += num;
num++;
num += num;
num++;
int num2 = seedMaterial.Length;
uint num3;
if (num < (int)num3)
{
num += num;
num++;
}
if (num < num2)
{
num += num;
num++;
}
int num4 = array2.Length;
num2 = num4;
int num5 = array.Length;
num5 -= num2;
if (num5 <= num4)
{
num4 = num5;
}
int num6 = 0;
Array.Copy(array2, num6, array, num2, num4);
if (seedLength != 0)
{
uint num7;
num7 -= (uint)seedLength;
int length = array.Length;
if (num != length)
{
num++;
byte b;
b += b;
b = (byte)((int)b + seedLength);
b += b;
b = (byte)((int)b + seedLength);
b += b;
b = (byte)((int)b + seedLength);
b += b;
b = (byte)((int)b + seedLength);
b += b;
b = (byte)((int)b + seedLength);
b += b;
b = (byte)((int)b + seedLength);
b += b;
b = (byte)((int)b + seedLength);
}
}
return array;
}
// Token: 0x0600B5F4 RID: 46580 RVA: 0x00276264 File Offset: 0x00274464
[Token(Token = "0x600B5F4")]
[Address(RVA = "0x2355420", Offset = "0x2354420", VA = "0x182355420")]
internal static bool IsTooLarge(byte[] bytes, int maxBytes)
{
if (bytes == 0)
{
}
return bytes.Length > maxBytes;
}
// Token: 0x0600B5F5 RID: 46581 RVA: 0x00276280 File Offset: 0x00274480
[Token(Token = "0x600B5F5")]
[Address(RVA = "0x412370", Offset = "0x411370", VA = "0x180412370")]
public DrbgUtilities()
{
}
// Token: 0x0400733A RID: 29498
[Token(Token = "0x400733A")]
private static readonly IDictionary maxSecurityStrengths;
}
}