Project: Github Paroxyste/Simply-Blog 20190102

Vulnerability: #9224530 (2019-01-02 06:08:03)

Warning

There are many false positives, or unexploitable vulnerabilities. Please create working "PoC" exploit before reporting anything to vendor!

Details:

Sink PHP::echo
Risk _GET
/Simply-Blog-master/admin/editPost.php:18 (show/hide source)
1  <?php
2  
3  require_once("../includes/database.php");
4  require_once("../includes/sessions.php");
5  require_once("../includes/functions.php");
6  
7  $Admin = "Laurent Echeverria";
8  
9  if(isset($_POST["submit"])) {
10  	$Title = mysqli_real_escape_string($Connection, $_POST["Title"]);
11  	$Category = mysqli_real_escape_string($Connection, $_POST["Category"]);
12    $Post = mysqli_real_escape_string($Connection, $_POST["Post"]);
13  	$CurrentTime = time();
14  	$DateTime = date('d M Y', $CurrentTime);
15  	$DateTime;
16  	$Image = $_FILES["Image"]["name"];
17  	$Target = "../assets/img/uploads/" . basename($_FILES["Image"]["name"]);
18 $SearchQueryParam = $_GET["edit"];
19 20 if(empty($Title) || empty($Category) || empty($Image) || empty($Post)) {
Threat level 2

Callstack:

@INLINE::/Simply-Blog-master/admin/editPost.php /Simply-Blog-master/admin/editPost.php:158 (show/hide source)
138  
139        <div class="content">
140          <div class="container-fluid">
141  
142            <?php
143  						echo ErrorMessage();
144  						echo SuccessMessage();
145  
146              $SearchQueryParam = $_GET["edit"];
147              $ViewQuery = "SELECT * FROM admin_panel WHERE id='$SearchQueryParam'";
148              $Execute = mysqli_query($Connection, $ViewQuery);
149  
150              while($DataRows = mysqli_fetch_array($Execute)) {
151                $CurrentTitle = $DataRows["title"];
152                $CurrentCategory = $DataRows["category"];
153                $CurrentImage = $DataRows["image"];
154                $CurrentPost = $DataRows["post"];
155              }
156            ?>
157  
158 <form action="editPost.php?edit=<?php echo $SearchQueryParam; ?>" method="post" enctype="multipart/form-data">
159 <div class="row"> 160 <div class="col-md-8">