VYPR
High severityNVD Advisory· Published Apr 27, 2023· Updated Jan 30, 2025

Pimcore SQL Injection Vulnerability in Admin Search Find API

CVE-2023-30848

Description

Pimcore is an open source data and experience management platform. Prior to version 10.5.21, the admin search find API has a SQL injection vulnerability. Users should upgrade to version 10.5.21 to receive a patch or, as a workaround, apply the patch manually.

Affected packages

Versions sourced from the GitHub Security Advisory.

PackageAffected versionsPatched versions
pimcore/pimcorePackagist
< 10.5.2110.5.21

Affected products

1

Patches

1
25ad8674886f

Remove sql comments and add different exception on syntax error (#14972)

https://github.com/pimcore/pimcoreMatthias SchuhmayerApr 25, 2023via ghsa
1 file changed · +8 1
  • bundles/AdminBundle/Controller/Searchadmin/SearchController.php+8 1 modified
    @@ -15,6 +15,7 @@
     
     namespace Pimcore\Bundle\AdminBundle\Controller\Searchadmin;
     
    +use Doctrine\DBAL\Exception\SyntaxErrorException;
     use Pimcore\Bundle\AdminBundle\Controller\AdminController;
     use Pimcore\Bundle\AdminBundle\Controller\Traits\AdminStyleTrait;
     use Pimcore\Bundle\AdminBundle\Helper\GridHelperService;
    @@ -111,6 +112,8 @@ public function findAction(Request $request, EventDispatcherInterface $eventDisp
             $bricks = [];
             if (!empty($allParams['fields'])) {
                 $fields = $allParams['fields'];
    +            //remove sql comments
    +            $fields = str_replace('--', '', $fields);
     
                 foreach ($fields as $f) {
                     $parts = explode('~', $f);
    @@ -310,7 +313,11 @@ public function findAction(Request $request, EventDispatcherInterface $eventDisp
                 $searcherList = $beforeListLoadEvent->getArgument('list');
             }
     
    -        $hits = $searcherList->load();
    +        try {
    +            $hits = $searcherList->load();
    +        } catch (SyntaxErrorException $syntaxErrorException) {
    +            throw new \InvalidArgumentException('Check your arguments.');
    +        }
     
             $elements = [];
             foreach ($hits as $hit) {
    

Vulnerability mechanics

Generated by null/stub on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.

References

6

News mentions

0

No linked articles in our index yet.