fix SQL injection
authorAlan <alan@roojs.com>
Thu, 23 Mar 2023 02:47:53 +0000 (10:47 +0800)
committerAlan <alan@roojs.com>
Thu, 23 Mar 2023 02:47:53 +0000 (10:47 +0800)
DataObjects/Core_person.php

index 80187c3..0a499a4 100644 (file)
@@ -1051,7 +1051,7 @@ class Pman_Core_DataObjects_Core_person extends DB_DataObject
         // #2307 Search Country!!
         if (!empty($q['query']['in_country'])) {
             // DB_DataObject::debugLevel(1);
-            $inc = $q['query']['in_country'];
+            $inc = $this->escape($q['query']['in_country']);
             $this->whereAdd("$tn_p.countries LIKE '%{$inc}%'");
         }