Änderungen Sicherheitsaspekte Passworthashingiterationen sowie Speicherplatznutzung zur Hashdechiffrierung und Anpassung der LKWs-Seite.

This commit is contained in:
ja
2022-01-11 11:58:54 +01:00
parent 3f7b85ac2b
commit 2199fc877c
8 changed files with 1430 additions and 1184 deletions

View File

@@ -6,7 +6,11 @@ Imports System.Threading.Tasks
Public Class VERAG_VARIABLES Public Class VERAG_VARIABLES
Public Shared errornumb As Integer = 0 Public Shared errornumb As Integer = 0
Shared Function getiterationnumber() As Integer Shared Function getiterationnumber() As Integer
Return RandomInteger(Math.Pow(2, 5), Math.Pow(2, 10)) If HttpContext.Current.Request.ServerVariables("SERVER_NAME") = "localhost" Then
Return RandomInteger(Math.Pow(2, 7), Math.Pow(2, 10))
Else
Return RandomInteger(Math.Pow(2, 9), Math.Pow(2, 18))
End If
End Function End Function
Shared Sub initerrorcount() Shared Sub initerrorcount()

View File

@@ -50,6 +50,8 @@ Nam pretium turpis et arcu. Duis arcu tortor, suscipit eget, imperdiet nec, impe
<!--<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js" integrity="sha384-cs/chFZiN24E4KMATLdqdvsezGxaGsi4hLGOzlXwp5UZB1LY//20VyM2taTB4QvJ" crossorigin="anonymous"></script>--> <!--<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js" integrity="sha384-cs/chFZiN24E4KMATLdqdvsezGxaGsi4hLGOzlXwp5UZB1LY//20VyM2taTB4QvJ" crossorigin="anonymous"></script>-->
<!-- Production version --> <!-- Production version -->
<script src="https://unpkg.com/@popperjs/core@2"></script> <script src="https://unpkg.com/@popperjs/core@2"></script>
<!-- jQuery CDN - min version -->
<script src="https://code.jquery.com/jquery-3.3.1.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script>
</ContentTemplate></asp:UpdatePanel> </ContentTemplate></asp:UpdatePanel>
</asp:Content> </asp:Content>

View File

@@ -51,7 +51,8 @@
<link rel="stylesheet" type="text/css" href="../css/Customers/Invoices.css"/> <link rel="stylesheet" type="text/css" href="../css/Customers/Invoices.css"/>
<link href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.1/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/> <link href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.1/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> <!-- jQuery CDN - min version -->
<script src="https://code.jquery.com/jquery-3.3.1.min.js" integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8=" crossorigin="anonymous"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.1/jquery-ui.min.js"></script> <script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.1/jquery-ui.min.js"></script>
</asp:Content> </asp:Content>

View File

@@ -1,8 +1,7 @@
<%@ Page Title="" Language="VB" MasterPageFile="~/Customers/Customers.master" AutoEventWireup="false" CodeFile="LKWs.aspx.vb" Inherits="LKWS" %> <%@ Page Title="" Language="VB" MasterPageFile="~/Customers/Customers.master" AutoEventWireup="false" CodeFile="LKWs.aspx.vb" Inherits="LKWS" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server" > <asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server" >
<!-- Bootstrap -->
<html lang="en"></html>
<!-- Required meta tags --> <!-- Required meta tags -->
<meta charset="utf-8"/> <meta charset="utf-8"/>
@@ -88,9 +87,29 @@
</div> </div>
<div class="col-12"style="height:10px;"></div> <div class="col-12"style="height:10px;"></div>
<div id="conovertab" class="col-12" style="margin-left:-10px;background-color:#fff;overflow-y:auto;"> <div id="conovertab" class="col-12" style="margin-left:-10px;background-color:#fff;overflow-y:auto;">
<asp:Table ID="tbl_mainpage" ClientIDMode="Static" runat="server" Width="100%" style="background-color:#fff;overflow-y:auto;" CssClass="table table-striped col-12"> <!-- <asp:Table ID="tbl_mainpage" ClientIDMode="Static" runat="server" Width="100%" style="background-color:#fff;overflow-y:auto;" CssClass="table table-striped col-12">
<asp:TableHeaderRow ID="headrow1" runat="server" style="background-color:#043381;color:#fff;height:10px"><asp:TableHeaderCell ID="tblhc_SDLNr">SDL-Nr</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Bez">Bezeichnung</asp:TableHeaderCell><asp:TableHeaderCell ID="tbl_gueltig">Gültig Bis</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_KarteNr">Karten-Nummer</asp:TableHeaderCell></asp:TableHeaderRow> <asp:TableHeaderRow ID="headrow1" runat="server" style="background-color:#043381;color:#fff;height:10px"><asp:TableHeaderCell ID="tblhc_SDLNr">SDL-Nr</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Bez">Bezeichnung</asp:TableHeaderCell><asp:TableHeaderCell ID="tbl_gueltig">Gültig Bis</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_KarteNr">Karten-Nummer</asp:TableHeaderCell></asp:TableHeaderRow>
</asp:Table> </asp:Table>-->
<table runat="server" id="tablemain" class="col-12">
<tr style="background-color: #043381; color: #fff">
<th style="text-align: center">
<td style="font-weight: 600; color: white; text-align: center">SDL
</td>
</th>
<th style="text-align: center">
<td style="font-weight: 600; color: white; text-align: center">Bezeichnung
</td>
</th>
<th style="text-align: center">
<td style="font-weight: 600; color: white; text-align: center">Gültig bis
</td>
</th>
<th style="text-align: center">
<td style="font-weight: 600; color: white; text-align: center">Kartennummer
</td>
</th>
</tr>
</table>
</div> </div>
</div> </div>
</div> </div>
@@ -130,17 +149,43 @@
</div> </div>
<div class="col-12" style="height:15px"></div> <div class="col-12" style="height:15px"></div>
<div id="conovertab_M" class="col-12" style="margin-left:-10px;background-color:#fff;overflow-x:auto"> <div id="conovertab_M" class="col-12" style="margin-left:-10px;background-color:#fff;overflow-x:auto">
<asp:Table ID="tbl_mainpage_M" ClientIDMode="Static" runat="server" Width="100%" CssClass="table table-striped col-12"> <!-- <asp:Table ID="tbl_mainpage_M" ClientIDMode="Static" runat="server" Width="100%" CssClass="table table-striped col-12">
<asp:TableHeaderRow runat="server" ID="headrow_M" style="background-color:#043381;color:#fff"><asp:TableHeaderCell ID="tblhc_SDLNr_M">SDL_Nr</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Bez_M">Bezeichnung</asp:TableHeaderCell><asp:TableHeaderCell ID="tbl_gueltig_M">Gültig Bis</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_KarteNr_M">Karten-Nummer</asp:TableHeaderCell></asp:TableHeaderRow> <asp:TableHeaderRow runat="server" ID="headrow_M" style="background-color:#043381;color:#fff"><asp:TableHeaderCell ID="tblhc_SDLNr_M">SDL_Nr</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Bez_M">Bezeichnung</asp:TableHeaderCell><asp:TableHeaderCell ID="tbl_gueltig_M">Gültig Bis</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_KarteNr_M">Karten-Nummer</asp:TableHeaderCell></asp:TableHeaderRow>
</asp:Table> </asp:Table>-->
<table runat="server" id="tablemain_m" class="col-12">
<tr style="background-color:#043381;color:#fff">
<th style="text-align:center">
<td style="font-weight: 600;color:white">
SDL
</td>
</th>
<th style="text-align: center">
<td style="font-weight: 600; color: white; text-align: center">
Bezeichnung
</td>
</th>
<th style="text-align: center">
<td style="font-weight: 600; color: white; text-align: center">
Gültig bis
</td>
</th>
<th style="text-align: center">
<td style="font-weight: 600; color: white; text-align: center">
Kartennummer
</td>
</th>
</tr>
</table>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</ContentTemplate></asp:UpdatePanel> </ContentTemplate></asp:UpdatePanel>
<!-- jQuery CDN - Slim version (=without AJAX) <!-- jQuery CDN - Slim version (=without AJAX)
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>--> <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>-->
<!-- jQuery CDN - min version --> <!--Below is the reference for JQuery as it will be needed for the ajax call and table creation-->
<script src="https://code.jquery.com/jquery-3.1.1.min.js"> <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
<!-- Popper.JS --> <!-- Popper.JS -->
<!--<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js" integrity="sha384-cs/chFZiN24E4KMATLdqdvsezGxaGsi4hLGOzlXwp5UZB1LY//20VyM2taTB4QvJ" crossorigin="anonymous"></script>--> <!--<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js" integrity="sha384-cs/chFZiN24E4KMATLdqdvsezGxaGsi4hLGOzlXwp5UZB1LY//20VyM2taTB4QvJ" crossorigin="anonymous"></script>-->
<!-- Production version --> <!-- Production version -->
@@ -314,7 +359,7 @@
let Speditionslabel = document.getElementById('<%=lbl_sped_Placeholder.ClientID%>'); let Speditionslabel = document.getElementById('<%=lbl_sped_Placeholder.ClientID%>');
let natplaceholder = document.getElementById('<%=lbl_Placeholder.ClientID%>'); let natplaceholder = document.getElementById('<%=lbl_Placeholder.ClientID%>');
alert(id) alert(id)
let table = document.getElementById('<%=tbl_mainpage.ClientID%>'); let table = document.getElementById('<%=tablemain.ClientID%>');
var rowCount = table.rows.length; var rowCount = table.rows.length;
for (let i = rowCount - 1; i > 0; i--) { for (let i = rowCount - 1; i > 0; i--) {
@@ -333,55 +378,47 @@
//addNewRow(SDL,Bez,Datguenstig,KartNr) //addNewRow(SDL,Bez,Datguenstig,KartNr)
// Pagemethods.filltable2(<%' =tbl_mainpage %> , SDL, Bez, Datguenstig, KartNr) // Pagemethods.filltable2(<%' =tbl_mainpage %> , SDL, Bez, Datguenstig, KartNr)
//} //}
var data = {}; var data = {
data['Kennzeichen'] = id.split(',')[0]; "Kennzeichen": id.split(',')[0]
};
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: "LKWs.aspx/filltable2", url: "LKWs.aspx/filltable2",
contentType: "application/json; charset=utf-8", contentType: "application/json; charset=utf-8",
dataType: "json", dataType: "json",
async: true,
data: JSON.stringify(data), data: JSON.stringify(data),
success: function (data) { success: function (data) {
result = data.d; let JSONObj = data.d;
// addheader(); // addheader();
let strHTML = '<tr><th><td>SDL-Nr</td></th><th><td>Bezeichnung</td></th><th><td>Gueltig bis</td></th><th><td>Karten Nummer</td></th></tr>'; let strHTML = '<tr style="background-color:#043381;color:#fff"><th><td style="font-weight:600; color:white">SDL-Nr</td></th><th><td style="font-weight:600; color:white">Bezeichnung</td></th><th><td style="font-weight:600; color:white">Gueltig bis</td></th><th><td style="font-weight:600; color:white">Karten-Nummer</td></th></tr>';
alert('Horray! 200 status code!'); alert('Horray! 200 status code!');
// alert(result.rows.length) // alert(result.rows.length)
$(result).each(function () { $(JSONObj).each(function () {
let row = $(this)[0]; let row = $(this)[0];
strHTML += '<tr><td>' + row["SDL"] + '</td><td>' + row["Bez"] + '</td><td>' + row["Gueltigbis"] + '</td><td>' + row["KartNr"] + '</td></tr>'; strHTML += '<tr><td>' + row["SDL"] + '</td><td>' + row["Bez"] + '</td><td>' + row["Gueltigbis"] + '</td><td>' + row["KartNr"] + '</td></tr>';
alert(strHTML)
alert(row)
$('#<%=tbl_mainpage.ClientID%>').innerHTML = strHTML;
}); });
$('#<%=tablemain.ClientID%>').html(strHTML);
}, },
error: function (jqXHR, textStatus, errorThrown) { error: function (jqXHR, textStatus, errorThrown) {
alert("Status:" + jqXHR.status + "\nStatusText: " + textStatus + "\nError:" + errorThrown); alert("Status:" + jqXHR.status + "\nStatusText: " + textStatus + "\nError:" + errorThrown);
} }
}); });
//filltable2(id.split(',')[0]) //filltable2(id.split(',')[0])
} }
function doPostBack_M(id_M) { function doPostBack_M(id_M) {
let Speditionslabel = document.getElementById('<%=lbl_sped_Placeholder_M.ClientID%>'); let Speditionslabel = document.getElementById('<%=lbl_sped_Placeholder_M.ClientID%>');
let natplaceholder = document.getElementById('<%=lbl_Placeholder_M.ClientID%>'); let natplaceholder = document.getElementById('<%=lbl_Placeholder_M.ClientID%>');
alert(id_M) alert(id_M)
let table_M = document.getElementById('<%=tbl_mainpage_M.ClientID%>'); let table_M = document.getElementById('<%=tablemain_m.ClientID%>');
let rowCount = table_M.rows.length; let rowCount = table_M.rows.length;
for (let i = rowCount - 1; i > 0; i--) { for (let i = rowCount - 1; i > 0; i--) {
table_M.deleteRow(i); table_M.deleteRow(i);
} }
Speditionslabel.textContent = id_M.split(',')[0]; Speditionslabel.textContent = id_M.split(',')[0];
natplaceholder.textContent = id_M.split(',')[1]; natplaceholder.textContent = id_M.split(',')[1];
//debugger
//for (let i = 0; i <= 5; i++) { //for (let i = 0; i <= 5; i++) {
// let SDL = "453543535434334543"; // let SDL = "453543535434334543";
// let Bez = "Diesel"; // let Bez = "Diesel";
@@ -390,36 +427,33 @@
//addNewRow(SDL,Bez,Datguenstig,KartNr) //addNewRow(SDL,Bez,Datguenstig,KartNr)
// Pagemethods.filltable2(<%' =tbl_mainpage_M%> , SDL, Bez, Datguenstig, KartNr) // Pagemethods.filltable2(<%' =tbl_mainpage_M%> , SDL, Bez, Datguenstig, KartNr)
//} //}
var data_m = {}; var data = {
data_m['Kennzeichen'] = id.split(',')[0]; "Kennzeichen": id_M.split(',')[0]
};
$.ajax({ $.ajax({
type: "POST", type: "POST",
url: "LKWs.aspx/filltable2_M", url: "LKWs.aspx/filltable2_M",
contentType: "application/json; charset=utf-8", contentType: "application/json; charset=utf-8",
dataType: "json", dataType: "json",
data: JSON.stringify(data_m), data: JSON.stringify(data),
async: true, success: function (data) {
success: function (data_m) { result = data.d;
result = data_m.d;
// addheader(); // addheader();
let strHTML = '<tr><th><td> SDL-Nr </td></th><th><td> Bezeichnung </td></th><th><td> Gueltig bis</td></th><th><td>Karten Nummer</td></th></tr>'; let strHTML = '<tr style="background-color:#043381;color:#fff"><th><td style="font-weight:600; color:white">SDL-Nr</td></th><th><td style="font-weight:600; color:white">Bezeichnung</td></th><th><td style="font-weight:600; color:white">Gueltig bis</td></th><th><td style="font-weight:600; color:white">Karten-Nummer</td></th></tr>';
alert('Horray! 200 status code!'); alert('Horray! 200 status code!');
$(result).each(function () { $(result).each(function () {
let row = $(this)[0]; let row = $(this)[0];
strHTML += '<tr><td>' + row["SDL"] + '</td><td>' + row["Bez"] + '</td><td>' + row["Gueltigbis"] + '</td><td>' + row["KartNr"] + '</td></tr>'; strHTML += '<tr><td>' + row["SDL"] + '</td><td>' + row["Bez"] + '</td><td>' + row["Gueltigbis"] + '</td><td>' + row["KartNr"] + '</td></tr>';
alert(strHTML)
alert(row)
$('#<%=tbl_mainpage_M.ClientID%>').innerHTML = strHTML;
}); });
$('#<%=tablemain_m.ClientID%>').html(strHTML);
}, },
error: function (jqXHR, textStatus, errorThrown) { error: function (jqXHR, textStatus, errorThrown) {
alert("Status:" + jqXHR.status + "\nStatusText: " + textStatus + "\nError:" + errorThrown); alert("Status:" + jqXHR.status + "\nStatusText: " + textStatus + "\nError:" + errorThrown);
} }
}); });
//filltable2(id.split(',')[0]) //filltable2(id.split(',')[0])
} }
</script> </script>

View File

@@ -32,7 +32,8 @@ Partial Class LKWS
If Me.Page.User.Identity.IsAuthenticated Then If Me.Page.User.Identity.IsAuthenticated Then
Try Try
Kdnrtext = Session.Item("CustomerID") Kdnrtext = Session.Item("CustomerID")
Catch A As UnauthorizedAccessException When String.IsNullOrEmpty(Kdnrtext) Catch A As UnauthorizedAccessException When String.IsNullOrEmpty(Session.Item("CustomerID"))
FormsAuthentication.RedirectToLoginPage()
'MsgBox("Dieser Bereich ist nicht gestattet! Ein Fehler ist bei der Validierung der ID aufgetreten! Bitte erneut versuchen!", MsgBoxStyle.Information, "Error in User Area!") 'MsgBox("Dieser Bereich ist nicht gestattet! Ein Fehler ist bei der Validierung der ID aufgetreten! Bitte erneut versuchen!", MsgBoxStyle.Information, "Error in User Area!")
End Try End Try
Else Else
@@ -55,7 +56,7 @@ Partial Class LKWS
Dim cnt As Integer = 0 Dim cnt As Integer = 0
list = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940) list = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(Integer.Parse(HttpContext.Current.Session.Item("CustomerID")))
Dim tblhrow As TableHeaderRow = New TableHeaderRow Dim tblhrow As TableHeaderRow = New TableHeaderRow
tblhrow.Cells.Add(tbhc_KFZKennz) tblhrow.Cells.Add(tbhc_KFZKennz)
tblhrow.Cells.Add(tbhc_Nat) tblhrow.Cells.Add(tbhc_Nat)
@@ -125,7 +126,7 @@ Partial Class LKWS
Dim strtemparr As String = String.Empty Dim strtemparr As String = String.Empty
Dim strtemp2 As String = String.Empty Dim strtemp2 As String = String.Empty
Dim strarrtemp = String.Empty Dim strarrtemp = String.Empty
Dim list2 As List(Of VERAG_PROG_ALLGEMEIN.cSDL) = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB_LKW(401940, l1.KfzKennzeichen) Dim list2 As List(Of VERAG_PROG_ALLGEMEIN.cSDL) = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB_LKW(Integer.Parse(HttpContext.Current.Session.Item("CustomerID")), l1.KfzKennzeichen)
Dim stringtemtr As String = String.Empty Dim stringtemtr As String = String.Empty
Dim tr As TableRow = New TableRow Dim tr As TableRow = New TableRow
Dim list3 As List(Of String) = New List(Of String) Dim list3 As List(Of String) = New List(Of String)
@@ -198,7 +199,7 @@ Partial Class LKWS
Protected Sub btn_Suchen_Click(sender As Object, e As EventArgs) Protected Sub btn_Suchen_Click(sender As Object, e As EventArgs)
Dim txt_LkwNr As TextBox = txt_lkw Dim txt_LkwNr As TextBox = txt_lkw
list = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940) list = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(Integer.Parse(HttpContext.Current.Session.Item("CustomerID")))
Dim tblhrow As TableHeaderRow = New TableHeaderRow() Dim tblhrow As TableHeaderRow = New TableHeaderRow()
Dim cnt As Integer = 0 Dim cnt As Integer = 0
Dim list3 As List(Of String) = New List(Of String) Dim list3 As List(Of String) = New List(Of String)
@@ -267,7 +268,7 @@ Partial Class LKWS
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
End If End If
tbl_2.Rows.Clear() tbl_2.Rows.Clear()
list_M = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940) list_M = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(Integer.Parse(HttpContext.Current.Session.Item("CustomerID")))
Dim cnt As Integer = 0 Dim cnt As Integer = 0
headrow_M.Cells.Add(tbhc_KFZKennz_M) headrow_M.Cells.Add(tbhc_KFZKennz_M)
@@ -327,7 +328,8 @@ Partial Class LKWS
tbl_mainpage_M.Rows.Clear() tbl_mainpage_M.Rows.Clear()
Dim cnt As Integer = 0 Dim cnt As Integer = 0
list_M = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940)
list_M = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(Integer.Parse(HttpContext.Current.Session.Item("CustomerID")))
Dim tblhrow_M As TableHeaderRow = New TableHeaderRow Dim tblhrow_M As TableHeaderRow = New TableHeaderRow
tblhrow_M.Cells.Add(tbhc_KFZKennz_M) tblhrow_M.Cells.Add(tbhc_KFZKennz_M)
@@ -402,7 +404,8 @@ Partial Class LKWS
<ScriptMethod(ResponseFormat:=ResponseFormat.Json)> <ScriptMethod(ResponseFormat:=ResponseFormat.Json)>
Public Shared Function filltable2(Kennzeichen As String) As List(Of Entry) Public Shared Function filltable2(Kennzeichen As String) As List(Of Entry)
Dim list As List(Of Entry) = New List(Of Entry) Dim list As List(Of Entry) = New List(Of Entry)
Dim list2 As List(Of VERAG_PROG_ALLGEMEIN.cSDL) = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB_LKW(401940, Kennzeichen) Dim list2 As List(Of VERAG_PROG_ALLGEMEIN.cSDL) = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB_LKW(Integer.Parse(HttpContext.Current.Session.Item("CustomerID")), Kennzeichen)
If list2.Count >= 1 Then
For Each l2 In list2 For Each l2 In list2
Dim Entrytemp As New Entry Dim Entrytemp As New Entry
Entrytemp.SDL = l2.SDLNr.ToString Entrytemp.SDL = l2.SDLNr.ToString
@@ -411,6 +414,14 @@ Partial Class LKWS
Entrytemp.KartNr = l2.KartenNr.ToString Entrytemp.KartNr = l2.KartenNr.ToString
list.Add(Entrytemp) list.Add(Entrytemp)
Next Next
ElseIf list2.Count = 0 Then
Dim Entrytempempty As New Entry
Entrytempempty.SDL = "Keine"
Entrytempempty.Bez = "Daten"
Entrytempempty.Gueltigbis = "gefunden!"
Entrytempempty.KartNr = String.Empty
list.Add(Entrytempempty)
End If
Return list Return list
End Function End Function
Public Class Entry Public Class Entry
@@ -423,7 +434,8 @@ Partial Class LKWS
<ScriptMethod(ResponseFormat:=ResponseFormat.Json, UseHttpGet:=False)> <ScriptMethod(ResponseFormat:=ResponseFormat.Json, UseHttpGet:=False)>
Public Shared Function filltable2_M(Kennzeichen As String) As List(Of Entry) Public Shared Function filltable2_M(Kennzeichen As String) As List(Of Entry)
Dim list As List(Of Entry) = New List(Of Entry) Dim list As List(Of Entry) = New List(Of Entry)
Dim list2 As List(Of VERAG_PROG_ALLGEMEIN.cSDL) = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB_LKW(401940, Kennzeichen) Dim list2 As List(Of VERAG_PROG_ALLGEMEIN.cSDL) = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB_LKW(Integer.Parse(HttpContext.Current.Session.Item("CustomerID")), Kennzeichen)
If list2.Count >= 1 Then
For Each l2 In list2 For Each l2 In list2
Dim Entrytemp As New Entry Dim Entrytemp As New Entry
Entrytemp.SDL = l2.SDLNr.ToString Entrytemp.SDL = l2.SDLNr.ToString
@@ -432,6 +444,14 @@ Partial Class LKWS
Entrytemp.KartNr = l2.KartenNr.ToString Entrytemp.KartNr = l2.KartenNr.ToString
list.Add(Entrytemp) list.Add(Entrytemp)
Next Next
ElseIf list2.Count = 0 Then
Dim Entrytempempty As New Entry
Entrytempempty.SDL = "Keine"
Entrytempempty.Bez = "Daten"
Entrytempempty.Gueltigbis = "gefunden!"
Entrytempempty.KartNr = String.Empty
list.Add(Entrytempempty)
End If
Return list Return list
End Function End Function
End Class End Class

View File

@@ -52,8 +52,8 @@ Global
{11EF0CDA-BC19-40FB-91C4-25C81F3A27AC}.Release|x64.Build.0 = Debug|Any CPU {11EF0CDA-BC19-40FB-91C4-25C81F3A27AC}.Release|x64.Build.0 = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Any CPU.Build.0 = Debug|Any CPU {A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x64.ActiveCfg = Debug|x64 {A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x64.ActiveCfg = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x64.Build.0 = Debug|x64 {A3B497BD-842C-4A2B-B398-ED1976849DF1}.Debug|x64.Build.0 = Debug|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Any CPU.ActiveCfg = Release|Any CPU {A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Any CPU.Build.0 = Release|Any CPU {A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|Any CPU.Build.0 = Release|Any CPU
{A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x64.ActiveCfg = Release|x64 {A3B497BD-842C-4A2B-B398-ED1976849DF1}.Release|x64.ActiveCfg = Release|x64

View File

@@ -19,8 +19,8 @@ Partial Class login_FLEX
Else Else
Try Try
Dim teststr = String.Empty Dim teststr = String.Empty
intzahliterats = VERAG_VARIABLES.RandomInteger(2, Math.Pow(2, 3)) intzahliterats = VERAG_VARIABLES.RandomInteger(2, Math.Pow(2, 10))
teststr = Await TestPerformance.TestHashrateServerAsync(VERAG_VARIABLES.RandomInteger(2, Math.Pow(2, 2))) teststr = Await TestPerformance.TestHashrateServerAsync(VERAG_VARIABLES.RandomInteger(2, Math.Pow(2, 6)))
If String.Equals(teststr, String.Empty) = False Then If String.Equals(teststr, String.Empty) = False Then
intzahliterats = VERAG_VARIABLES.getiterationnumber intzahliterats = VERAG_VARIABLES.getiterationnumber
End If End If
@@ -246,7 +246,7 @@ Partial Class login_FLEX
Login1.FailureText = VERAG_VARIABLES.geterrornumb + "Username is not in the database!" Login1.FailureText = VERAG_VARIABLES.geterrornumb + "Username is not in the database!"
End If End If
If String.Equals(tb3.Text, dr("Password")) = True Then If String.Equals(tb3.Text, dr("Password")) = True Then
intzahl = VERAG_VARIABLES.RandomInteger(Math.Pow(2, 6), Math.Pow(2, 10)) intzahl = VERAG_VARIABLES.RandomInteger(Math.Pow(2, 8), Math.Pow(2, 10))
salt = VERAG_VARIABLES.GenerateSalt(intzahl) salt = VERAG_VARIABLES.GenerateSalt(intzahl)
Dim hashpw As Byte() = Await VERAG_VARIABLES.HashPasswordAsync(passw, salt, intzahliterats, intzahl) Dim hashpw As Byte() = Await VERAG_VARIABLES.HashPasswordAsync(passw, salt, intzahliterats, intzahl)
If Await VERAG_VARIABLES.VerifyhashAsync(dr("Password").ToString, salt, hashpw, intzahliterats, intzahl) = True Then If Await VERAG_VARIABLES.VerifyhashAsync(dr("Password").ToString, salt, hashpw, intzahliterats, intzahl) = True Then