vendor/shopware/storefront/Framework/Csrf/Exception/InvalidCsrfTokenException.php line 16

Open in your IDE?
  1. <?php declare(strict_types=1);
  2. namespace Shopware\Storefront\Framework\Csrf\Exception;
  3. use Shopware\Core\Framework\Feature;
  4. use Shopware\Core\Framework\Log\Package;
  5. use Symfony\Component\HttpFoundation\Response;
  6. use Symfony\Component\HttpKernel\Exception\HttpException;
  7. /**
  8. * @deprecated tag:v6.5.0 - InvalidCsrfTokenException will be removed as the csrf system will be removed in favor for the samesite approach
  9. */
  10. #[Package('storefront')]
  11. class InvalidCsrfTokenException extends HttpException
  12. {
  13. public function __construct()
  14. {
  15. Feature::triggerDeprecationOrThrow(
  16. 'v6.5.0.0',
  17. Feature::deprecatedClassMessage(__CLASS__, 'v6.5.0.0')
  18. );
  19. parent::__construct(Response::HTTP_FORBIDDEN, 'The provided CSRF token is not valid');
  20. }
  21. }