GHSA-4mg9-vhxq-vm7j
SQL Server LIMIT / OFFSET SQL Injection in laravel/framework and illuminate/database
Quick fix
GHSA-4mg9-vhxq-vm7j — laravel/framework: upgrade to the fixed version with the command below.
composer require laravel/framework:^8.40.0Details
### Impact
Those using SQL Server with Laravel and allowing user input to be passed directly to the `limit` and `offset` functions are vulnerable to SQL injection. Other database drivers such as MySQL and Postgres are not affected by this vulnerability.
### Patches
This problem has been patched on Laravel versions 6.20.26, 7.30.5, and 8.40.0.
### Workarounds
You may workaround this vulnerability by ensuring that only integers are passed to the `limit` and `offset` functions, as well as the `skip` and `take` functions.
Are you affected?
Enter the version of the package you're using.
Affected packages
8.0.0Fixed in: 8.40.0composer require laravel/framework:^8.40.00Fixed in: 6.20.26composer require laravel/framework:^6.20.268.0.0Fixed in: 8.40.0composer require illuminate/database:^8.40.00Fixed in: 6.20.26composer require illuminate/database:^6.20.26