Fixes login using SRP6v2

This commit is contained in:
hondacrx
2024-02-22 16:16:13 -05:00
parent 5de06c30c1
commit 15d714f050
3 changed files with 22 additions and 14 deletions
+1 -1
View File
@@ -539,7 +539,7 @@ namespace BNetServer.REST
{
uint id = result.Read<uint>(0);
byte[] salt = RandomHelper.GetRandomBytes(SRP6.SaltLength);
byte[] salt = new byte[0].GenerateRandomKey(SRP6.SaltLength);
BigInteger x = new BigInteger(SHA256.HashData(salt.Combine(result.Read<string>(1).ToByteArray(true))), true);
byte[] verifier = BigInteger.ModPow(BnetSRP6v1Base.g, x, BnetSRP6v1Base.N).ToByteArray(true, true);