
16/05/2012, 07:55
|
| | Fecha de Ingreso: marzo-2012
Mensajes: 4
Antigüedad: 13 años Puntos: 0 | |
Prolema SQL Injected Buenas comunidad, tengo un problema que no puedo resolver, el jefe, me ha pedido que verifique estos errores que salen a la hora de revisar la seguridad del website:
Using the POST HTTP method, Site Scanner found that :
+ The following resources may be vulnerable to SQL injection :
+ The 'id_padre' parameter of the /p-pg_4x4-3-15t-form.php CGI :
/p-pg_4x4-3-15t-form.php [id_padre='+convert(int,convert(varchar,0x7b5d)
)+']
-------- output --------
<form action="/p-pg_4x4-3-15t-form.php" method="POST" id="precios" [...]
You have an error in your SQL syntax; check the manual that corresponds
to your MySQL server version for the right syntax to use near 'convert(i
nt,convert(varchar,0x7b5d)) ''' at line 1
------------------------
+ The 'id_padre' parameter of the /c-pg_4x4-3-15t-form.php CGI :
/c-pg_4x4-3-15t-form.php [id_padre='+convert(int,convert(varchar,0x7b5d)
)+']
-------- output --------
<form action="/c-pg_4x4-3-15t-form.php" method="POST" id="precios" [...]
You have an error in your SQL syntax; check the manual that corresponds
to your MySQL server version for the right syntax to use near 'convert(i
nt,convert(varchar,0x7b5d)) ''' at line 1
------------------------
+ The 'id_padre' parameter of the /p-pg_4x4-3-15-form.php CGI :
/p-pg_4x4-3-15-form.php [id_padre='+convert(int,convert(varchar,0x7b5d))
+']
Creo que esta es la consulta a la que se refiere:
SELECT * FROM expedicion_datos WHERE id_salidas='$id_padre'
El $id_padre viene de una variable pasada por un formulario POST
$id_padre = $_POST['id_padre'], que la misma viene de un combo o de una lista.
Que me recomiendan o cual seria una solución posible.
Sin nada mas, muchas gracias. Saludos |