This commit is contained in:
niko
2026-06-04 11:42:34 +02:00
parent f39ba70a9f
commit e720b98cd1
7488 changed files with 2493818 additions and 0 deletions
@@ -0,0 +1,47 @@
using System;
using System.Security.Cryptography;
namespace Mono.Security.Cryptography
{
// Token: 0x020000A2 RID: 162
internal sealed class KeyBuilder
{
// Token: 0x060008E7 RID: 2279 RVA: 0x00023034 File Offset: 0x00021234
private KeyBuilder()
{
}
// Token: 0x170000F1 RID: 241
// (get) Token: 0x060008E8 RID: 2280 RVA: 0x0002303C File Offset: 0x0002123C
private static RandomNumberGenerator Rng
{
get
{
if (KeyBuilder.rng == null)
{
KeyBuilder.rng = RandomNumberGenerator.Create();
}
return KeyBuilder.rng;
}
}
// Token: 0x060008E9 RID: 2281 RVA: 0x00023058 File Offset: 0x00021258
public static byte[] Key(int size)
{
byte[] array = new byte[size];
KeyBuilder.Rng.GetBytes(array);
return array;
}
// Token: 0x060008EA RID: 2282 RVA: 0x00023078 File Offset: 0x00021278
public static byte[] IV(int size)
{
byte[] array = new byte[size];
KeyBuilder.Rng.GetBytes(array);
return array;
}
// Token: 0x040001DA RID: 474
private static RandomNumberGenerator rng;
}
}