mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-05-24 16:28:40 -04:00
Do proper XSS sanity check with excel files (#39)
This commit is contained in:
@@ -578,12 +578,7 @@ class Items extends Secure_area implements iData_controller
|
||||
while (($data = fgetcsv($handle)) !== FALSE)
|
||||
{
|
||||
// XSS file data sanity check
|
||||
if ($this->security->xss_clean($data) === FALSE)
|
||||
{
|
||||
echo json_encode( array('success'=>false, 'message'=>'Your uploaded file contains malicious data') );
|
||||
|
||||
return;
|
||||
}
|
||||
$data = $this->security->xss_clean($data);
|
||||
|
||||
if (sizeof($data) >= 23)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user