Änderung Implementierung async hasratetestfunktion
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
Imports System.Data.SqlClient
|
Imports System.Data.SqlClient
|
||||||
|
Imports System.Diagnostics
|
||||||
Imports Microsoft.VisualBasic
|
Imports Microsoft.VisualBasic
|
||||||
|
|
||||||
|
|
||||||
@@ -109,5 +110,41 @@ Public Class TestPerformance
|
|||||||
|
|
||||||
End Using
|
End Using
|
||||||
End Sub
|
End Sub
|
||||||
Public Shared DeleteUsers()
|
Public Shared Sub DeleteUsers()
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Async Function TestHashrateServer(zahlint As Integer) As Threading.Tasks.Task(Of Boolean)
|
||||||
|
Dim arrkeys As New List(Of Byte())
|
||||||
|
Dim arrzahl As New List(Of Integer)
|
||||||
|
Dim arrzahl_iterats As New List(Of Integer)
|
||||||
|
Dim hashbytes As New List(Of Byte())
|
||||||
|
Dim arrzeitp1 As New List(Of Long)
|
||||||
|
Dim arrzeitp2 As New List(Of Long)
|
||||||
|
Dim arrzeitp3 As New List(Of Long)
|
||||||
|
Dim arrzeitp4 As New List(Of Long)
|
||||||
|
|
||||||
|
Dim sw1 As Stopwatch = New Stopwatch
|
||||||
|
Dim sw2 As Stopwatch = New Stopwatch
|
||||||
|
|
||||||
|
For zahl As Integer = 0 To zahlint
|
||||||
|
sw1.Start()
|
||||||
|
arrkeys.Add(VERAG_VARIABLES.GenerateSalt(VERAG_VARIABLES.RandomInteger(0, zahlint)))
|
||||||
|
arrzahl_iterats.Add(VERAG_VARIABLES.getiterationnumber)
|
||||||
|
arrzahl.Add(VERAG_VARIABLES.RandomInteger(Math.Pow(2, 4), VERAG_VARIABLES.RandomInteger(Math.Pow(2, 10), Math.Pow(2, 14))))
|
||||||
|
sw1.Stop()
|
||||||
|
arrzeitp1.Add(sw1.ElapsedMilliseconds)
|
||||||
|
sw1.Reset()
|
||||||
|
Next
|
||||||
|
Dim pw As String = "q~^Vd$fS§§nS4!q"
|
||||||
|
For zahl As Integer = 0 To zahlint
|
||||||
|
sw2.Start()
|
||||||
|
hashbytes.Add(Await VERAG_VARIABLES.HashPassword(pw, arrkeys(zahl), arrzahl_iterats(zahl), arrzahl(zahl)))
|
||||||
|
sw2.Stop()
|
||||||
|
arrzeitp2.Add(sw2.ElapsedMilliseconds)
|
||||||
|
sw2.Reset()
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return False
|
||||||
|
End Function
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ Partial Class Customers_Default2
|
|||||||
VERAG_VARIABLES.initerrorcount()
|
VERAG_VARIABLES.initerrorcount()
|
||||||
Dim vals As New List(Of String)
|
Dim vals As New List(Of String)
|
||||||
Dim finalstr As String = ""
|
Dim finalstr As String = ""
|
||||||
For i As Integer = Integer.Parse(TextBox1.Text)+1 To Integer.Parse(TextBox2.Text)
|
For i As Integer = Integer.Parse(TextBox1.Text) + 1 To Integer.Parse(TextBox2.Text)
|
||||||
|
|
||||||
Dim strtemp As String = ""
|
Dim strtemp As String = ""
|
||||||
VERAG_VARIABLES.seterrorcount(Integer.Parse(i))
|
VERAG_VARIABLES.seterrorcount(Integer.Parse(i))
|
||||||
|
|||||||
@@ -98,6 +98,8 @@ Partial Class LKWS
|
|||||||
initcells(tblhrow, tbhc_KFZKennz, tbhc_Nat, tblhc_Verk, tblhc_Kz, tblhc_Verm, tr1, tc_KfzKennz, tc_Nationalitaet, tc_Verk, tc_KZ_Ab, tc_Vermerk, cnt)
|
initcells(tblhrow, tbhc_KFZKennz, tbhc_Nat, tblhc_Verk, tblhc_Kz, tblhc_Verm, tr1, tc_KfzKennz, tc_Nationalitaet, tc_Verk, tc_KZ_Ab, tc_Vermerk, cnt)
|
||||||
Dim Stringtemp As String = String.Empty
|
Dim Stringtemp As String = String.Empty
|
||||||
Dim strtemparr As String = String.Empty
|
Dim strtemparr As String = String.Empty
|
||||||
|
Dim strtemp2 As String = String.Empty
|
||||||
|
Dim strarrtemp = String.Empty
|
||||||
For Each l2 In list2
|
For Each l2 In list2
|
||||||
Dim String2 As String = String.Empty
|
Dim String2 As String = String.Empty
|
||||||
|
|
||||||
@@ -108,19 +110,17 @@ Partial Class LKWS
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
list3.Add(l2.SDLNr.ToString + ";" + Stringtemp + ";" + l2.GültigBis.ToString + ";" + l2.KartenNr.ToString)
|
list3.Add(l2.SDLNr.ToString + ";" + Stringtemp + ";" + l2.GültigBis.ToString + ";" + l2.KartenNr.ToString)
|
||||||
|
Next
|
||||||
Dim strtemp2 As String = String.Empty
|
|
||||||
If String.IsNullOrEmpty(l1.Nationalität) = True Then
|
If String.IsNullOrEmpty(l1.Nationalität) = True Then
|
||||||
strtemp2 = "Keine Angabe"
|
strtemp2 = "Keine Angabe"
|
||||||
Else
|
Else
|
||||||
strtemp2 = l1.Nationalität
|
strtemp2 = l1.Nationalität
|
||||||
End If
|
End If
|
||||||
Dim strarrtemp = String.Empty
|
|
||||||
For Each l4 In list3
|
For Each l4 In list3
|
||||||
strarrtemp = String.Join("-", l4)
|
strarrtemp = String.Join("-", l4.ToString)
|
||||||
Next
|
Next
|
||||||
tr1.Attributes.Add("OnClick", "Javascript:TableRowClick(""" & strarrtemp & """,""" & l1.KfzKennzeichen & """,""" & strtemp2 & """)")
|
tr1.Attributes.Add("OnClick", "Javascript:TableRowClick(""" & strarrtemp & """,""" & l1.KfzKennzeichen & """,""" & strtemp2 & """)")
|
||||||
Next
|
|
||||||
cnt += 1
|
cnt += 1
|
||||||
tbl_sidemenue.Rows.Add(tr1)
|
tbl_sidemenue.Rows.Add(tr1)
|
||||||
Next
|
Next
|
||||||
|
|||||||
Reference in New Issue
Block a user