VDB
Sign up
CRITICAL

GHSA-fxf7-vhh8-7vpq

CakePHP: FunctionsBuilder::jsonValue() vulerable to SQL injection with PostgresDriver

Quick fix

GHSA-fxf7-vhh8-7vpq — cakephp/cakephp: upgrade to the fixed version with the command below.

composer require cakephp/cakephp:^5.3.7

Details

### Impact The `FunctionsBuilder::jsonValue($field, $jsonPath)` methods with the Postgres driver is vulnerable to SQL injection if user controlled data is supplied to the `$jsonPath` parameter.

### Patches 5.1.10, 5.2.15, 5.3.7

### Workarounds Don't provide user controlled data to these functions/parameters.

Are you affected?

Enter the version of the package you're using.

Affected packages

Packagist/cakephp/cakephp
Introduced in: 5.3.0Fixed in: 5.3.7
Fixcomposer require cakephp/cakephp:^5.3.7
Packagist/cakephp/cakephp
Introduced in: 5.2.0Fixed in: 5.2.15
Fixcomposer require cakephp/cakephp:^5.2.15
Packagist/cakephp/cakephp
Introduced in: 5.1.0Fixed in: 5.1.10
Fixcomposer require cakephp/cakephp:^5.1.10
Packagist/cakephp/database
Introduced in: 5.3.0Fixed in: 5.3.7
Fixcomposer require cakephp/database:^5.3.7
Packagist/cakephp/database
Introduced in: 5.2.0Fixed in: 5.2.15
Fixcomposer require cakephp/database:^5.2.15
Packagist/cakephp/database
Introduced in: 5.1.0Fixed in: 5.1.10
Fixcomposer require cakephp/database:^5.1.10

References