southbeach
Programmer
Hello!
I just came across this construct using a WHERE clause:
First thing that jumps to mind is that I need to insert mysql_escape_string() and wrap $data with it.
Now, to explain the potential security hole with above snippet, what would be a sample string user could type on processed form?
I am afraid that this may be a wide range problem across the application and I am looking for solid and must be able to proof so that I am not thought of as one trying to take advantage ...
Thank,
--
SouthBeach
The good thing about not knowing is the opportunity to learn - Yours truly, 2008.
I just came across this construct using a WHERE clause:
Code:
$query.= "WHERE file_data.id = '".$data."' ";
$query.= "OR file_data.booking_num = '".$data."' ";
$query.= "OR fie_data.po_num = '".$data."%' ";
$query.= "OR file_data.container_num = '".$data."' ";
$query.= "OR file_data.shipping_num = '".$data."' ";
First thing that jumps to mind is that I need to insert mysql_escape_string() and wrap $data with it.
Now, to explain the potential security hole with above snippet, what would be a sample string user could type on processed form?
I am afraid that this may be a wide range problem across the application and I am looking for solid and must be able to proof so that I am not thought of as one trying to take advantage ...
Thank,
--
SouthBeach
The good thing about not knowing is the opportunity to learn - Yours truly, 2008.