Le puse puntos xq no me deja identar correctamente.
Codigo PHP vulnerable
Código
<? $mysqli = new mysqli('localhost','root', ,'seguridad'); if($mysqli->connect_errno){ echo 'error db'; } $id=$_GET['id']; $sql = "SELECT text,title FROM news where id=" $id; #echo $sql; $row = $q->fetch_assoc(); echo 'Titulo: ' $row['title']; echo "<br>"; echo 'Texto: ' $row['text']; echo "<br>"; } } else{ echo 'pase algun valor en la variable id'; } ?>
· Los códigos deben ir en etiquetas GeSHi
>aquí las reglas del foro
-Engel Lex