Closed lawrenceamer closed 5 years ago
Thanks for bringing this to my notice.
get()
method will prevent the attack.you passed $orderby
input into transaction module as order by query with out escaping , could be fixed by binding , but i think will be better to re write safe one
The TRUE
value passed to the second parameter of $this->input->get() is for XSS filtering. See image below from the documentation:
, i think will be better to use binding to avoid SQL injection on selected module https://www.codeigniter.com/userguide2/database/queries.html
, or wait my patch for that , you can close this ticket as Un resolved , thanks
try this on your browser locally with Mysql Databases , http://demo.com/transactions/latr_/?orderBy=transId%27&orderFormat=DESC&limit=10
the module in line [Transaction ] line 60 is vulnerable to SQL injection . the vulnerable end point is latr_/?orderBy=transId' order by input is being sent with out escape the query , allows attackers to execute malicious SQL Payloads .