Anpassungen an Serversettings vs localhost Hosting bzgl Sicherheit
This commit is contained in:
@@ -177,14 +177,23 @@ Public Class TestPerformance
|
||||
|
||||
For zahl As Integer = 0 To zahlint
|
||||
sw1.Start()
|
||||
hashsalts.Add(VERAG_VARIABLES.GenerateSalt(VERAG_VARIABLES.RandomInteger(Math.Pow(2, 4), Math.Pow(2, 8))))
|
||||
If HttpContext.Current.Request.ServerVariables("SERVER_NAME") = "localhost" Then
|
||||
hashsalts.Add(VERAG_VARIABLES.GenerateSalt(VERAG_VARIABLES.RandomInteger(Math.Pow(2, 4), Math.Pow(2, 8))))
|
||||
Else
|
||||
hashsalts.Add(VERAG_VARIABLES.GenerateSalt(VERAG_VARIABLES.RandomInteger(Math.Pow(2, 6), Math.Pow(2, 10))))
|
||||
End If
|
||||
arrzahl_iterats.Add(VERAG_VARIABLES.getiterationnumber)
|
||||
arrzahl.Add(zahlint)
|
||||
sw1.Stop()
|
||||
arrzeitp1.Add(sw1.ElapsedMilliseconds)
|
||||
sw1.Reset()
|
||||
Next
|
||||
Dim pw As String = "PasswordV" + VERAG_VARIABLES.RandomInteger(5, zahlint - 5).ToString + "!!%"
|
||||
Dim pw As String
|
||||
If HttpContext.Current.Request.ServerVariables("SERVER_NAME") = "localhost" Then
|
||||
pw = "PasswordV" + VERAG_VARIABLES.RandomInteger(5, zahlint - 5).ToString + "!!%"
|
||||
Else
|
||||
pw = "&WAS5$WdAG&" + VERAG_VARIABLES.RandomInteger(55, zahlint - VERAG_VARIABLES.RandomInteger(5, 87)).ToString + "#*p(=+UY"
|
||||
End If
|
||||
For zahl As Integer = 0 To zahlint
|
||||
sw2.Start()
|
||||
hashbytes.Add(Await VERAG_VARIABLES.HashPasswordAsync(pw, hashsalts(zahl), arrzahl_iterats(zahl), arrzahl(zahl)))
|
||||
|
||||
Reference in New Issue
Block a user