Änderungen

This commit is contained in:
ja
2022-02-07 10:19:50 +01:00
parent 45d0824b7e
commit 9350bd5903
3 changed files with 96 additions and 98 deletions

View File

@@ -57,16 +57,16 @@ 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)
'Argon.MemorySize = Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password)).Length
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)
'Argon.MemorySize = Encoding.UTF8.GetBytes(VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(password)).Length
Return Argon.GetBytes(nHash)
End If
End Function
@@ -78,16 +78,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 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.MemorySize = (((nIterations * 21.98 - (nIterations * 10.23) / 14 * 2) / 4.058) + 1 * 190)
Return Await Argon.GetBytesAsync(nHash)
End If
End Function

View File

@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0"?>
<!--
Weitere Informationen zum Konfigurieren der ASP.NET-Anwendung finden Sie unter
http://go.microsoft.com/fwlink/?LinkId=169433
@@ -43,7 +43,7 @@
<trustLevel name="Full" policyFile="internal"/>
</securityPolicy>-->
<customErrors mode="Off"/>
<compilation strict="false" explicit="true" targetFramework="4.7.2">
<compilation strict="false" explicit="true" targetFramework="4.7.2" debug="true">
<!-- <assemblies>
<add assembly="MySql.Data, Version=5.5, Culture=neutral, PublicKeyToken=C5687FC88969C44D"/>
</assemblies>

View File

@@ -171,7 +171,7 @@ Partial Class login_FLEX
reqfieldvalpassw_M.Enabled = False
reqfieldvalpassw.Validate()
If reqfieldvalpassw.IsValid = True Then
intzahl = VERAG_VARIABLES.RandomInteger(107, Math.Pow(2, 10))
intzahl = VERAG_VARIABLES.RandomInteger(107, Math.Pow(2, 9))
Dim hashpw1 As Byte() = Await VERAG_VARIABLES.HashPasswordAsync(tb3_M.Text, salt, intzahliterats, intzahl)
passw = tb3_M.Text
End If