Skip to content
OpenAdvisories
High · 7.2 CVE-2021-21263 BIT-laravel-2021-21263EUVD-2021-0484GHSA-3p32-j457-pg5x

Query Binding Exploitation in Laravel

Published Jan 19, 2021 · Updated Aug 3, 2024 · Assigned by GitHub_M

Description

Laravel is a web application framework. Versions of Laravel before 6.20.11, 7.30.2 and 8.22.1 contain a query binding exploitation. This same exploit applies to the illuminate/database package which is used by Laravel. If a request is crafted where a field that is normally a non-array value is an array, and that input is not validated or cast to its expected type before being passed to the query builder, an unexpected number of query bindings can be added to the query. In some situations, this will simply lead to no results being returned by the query builder; however, it is possible certain queries could be affected in a way that causes the query to return unexpected results.

Affected products

VendorProductAffectedFixed
laravel framework >= 6.0.0, < 6.20.11, >= 7.0.0, < 7.30.2, >= 8.0.0, < 8.22.1 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 php-laravel-framework 6.20.11+dfsg-1 —
Debian 13 php-laravel-framework 6.20.11+dfsg-1 —
Debian 12 php-laravel-framework 6.20.11+dfsg-1 —

Affected packages

EcosystemPackageAffectedFixedRecord
Packagist illuminate/database >= 7.0.0, < 7.30.3 7.30.3 GHSA-3p32-j457-pg5x
Packagist illuminate/database >= 8.0.0, < 8.22.1 8.22.1 GHSA-3p32-j457-pg5x
Packagist illuminate/database >= 6.0.0, < 6.20.12 6.20.12 GHSA-3p32-j457-pg5x
Packagist laravel/framework >= 8.0.0, < 8.22.1 8.22.1 GHSA-3p32-j457-pg5x
Packagist laravel/framework >= 6.0.0, < 6.20.11 6.20.11 GHSA-3p32-j457-pg5x
Packagist laravel/framework >= 7.0.0, < 7.30.2 7.30.2 GHSA-3p32-j457-pg5x

References