From c5e1ec94a9fa84bc803229243ea5185ccfe055a5 Mon Sep 17 00:00:00 2001 From: ja Date: Mon, 7 Feb 2022 08:48:32 +0100 Subject: [PATCH] =?UTF-8?q?=C3=84nderungen?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App_Code/VERAG_VARIABLES.vb | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/App_Code/VERAG_VARIABLES.vb b/App_Code/VERAG_VARIABLES.vb index 6dc1b2f..77169af 100644 --- a/App_Code/VERAG_VARIABLES.vb +++ b/App_Code/VERAG_VARIABLES.vb @@ -57,16 +57,14 @@ Public Class VERAG_VARIABLES Argon.Salt = salt Argon.DegreeOfParallelism = 8 Argon.Iterations = nIterations * VERAG_VARIABLES.RandomInteger(2, 3) - 'Argon.MemorySize = (((nIterations * 19.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190) - Argon.MemorySize = Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password)).Length + Argon.MemorySize = (((nIterations * 19.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190) Return Argon.GetBytes(nHash) Else Dim Argon As Argon2id = New Argon2id(Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password))) Argon.Salt = salt Argon.DegreeOfParallelism = 10 Argon.Iterations = nIterations * VERAG_VARIABLES.RandomInteger(2, 3) - 'Argon.MemorySize = (((nIterations * 20.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190) - Argon.MemorySize = Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password)).Length + Argon.MemorySize = (((nIterations * 20.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190) Return Argon.GetBytes(nHash) End If End Function @@ -77,17 +75,15 @@ Public Class VERAG_VARIABLES Dim Argon As Argon2id = New Argon2id(Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password))) Argon.Salt = salt Argon.DegreeOfParallelism = 8 - Argon.Iterations = nIterations * VERAG_VARIABLES.RandomInteger(2, 3) - 'Argon.MemorySize = (((nIterations * 19.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190) - Argon.MemorySize = Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password)).Length + Argon.Iterations = nIterations + Argon.MemorySize = (((nIterations * 17.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190) Return Await Argon.GetBytesAsync(nHash) Else Dim Argon As Argon2id = New Argon2id(Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password))) Argon.Salt = salt Argon.DegreeOfParallelism = 10 - Argon.Iterations = nIterations * VERAG_VARIABLES.RandomInteger(2, 3) - 'Argon.MemorySize = (((nIterations * 21.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190) - Argon.MemorySize = Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password)).Length + Argon.Iterations = nIterations + Argon.MemorySize = (((nIterations * 18.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190) Return Await Argon.GetBytesAsync(nHash) End If End Function