Skip to content
This repository has been archived by the owner on Oct 7, 2022. It is now read-only.

Commit

Permalink
more cross-site scripting fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
K-Felk committed Jul 19, 2018
1 parent d2bd8f9 commit e81fc2c
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions detail_nologin.php
Expand Up @@ -59,8 +59,11 @@
//in all cases, a type and an id for the issue or update must be passed or the page won't display
if (isset($_GET['id'])) {
$ID = $_GET['id'];
settype($ID, "integer");

} else if (isset($_POST['id'])) {
$ID = $_POST['id'];
set_type($ID, "integer");
} else {
$ID = false;
$userMessage = "<div class=\"alert alert-danger\">No system ID provided.</div>";
Expand All @@ -69,11 +72,18 @@

//get the type of posting (issue or update), either from GET or POST.
if (isset($_GET['type'])) {
$type = $_GET['type'];
if ($_GET['type'] == "issue") {
$type = "issue";
} else if ($_GET['type'] == "update") {
$type = "update";
} else {
$type = false;
$userMessage = "<div class=\"alert alert-danger\">Type of data not specified</div>";
}

} else if (isset($_POST['type'])) {
$ID = $_POST['type'];

set_type($ID, "integer");
} else {
$type = false;
$userMessage = "<div class=\"alert alert-danger\">Type of data not specified</div>";
Expand Down

0 comments on commit e81fc2c

Please sign in to comment.