laravel-at/laravel-image-sanitize
Laravel middleware that re-encodes uploaded images to strip hidden malicious payloads, reducing the risk of code execution. Requires PHP 8.3+, Laravel 12/13, and Intervention Image 4.
<?= to your patterns array.ImageSanitize::sanitize() to return Intervention\Image\Interfaces\EncodedImageInterface instead of the concrete Intervention\Image\EncodedImage class.Symfony\Component\HttpFoundation\Response return type to ImageSanitizeMiddleware::handle().image-sanitize configuration file.Intervention\Image\ImageManager through Laravel's container and respect an existing application binding.mime_content_type() directly.bootstrap/app.php.actions/checkout@v4.illuminate/http dependency explicitly.Intervention\Image\ImageManager when only detecting payload patterns.composer.json.parent::setUp() call in the test case.How can I help you explore Laravel packages today?