1
0
mirror of https://github.com/dg/dibi.git synced 2025-08-09 23:56:58 +02:00

fixed sql injection vulnerability through conditions and comments [closes #30]

This commit is contained in:
Filip Procházka
2011-01-24 18:53:07 +08:00
committed by David Grudl
parent af6352d0af
commit af715a8044

View File

@@ -182,6 +182,10 @@ final class DibiTranslator extends DibiObject
*/
public function formatValue($value, $modifier)
{
if ($this->comment) {
return "...";
}
// array processing (with or without modifier)
if ($value instanceof Traversable) {
$value = iterator_to_array($value);