CVE-2026-31819
Sylius has an Open Redirect via Referer Header
Sylius is an Open Source eCommerce Framework on Symfony. CurrencySwitchController::switchAction(), ImpersonateUserController::impersonateAction() and StorageBasedLocaleSwitcher::handle() use the HTTP Referer header directly when redirecting. The attack requires the victim to click a legitimate application link placed on an attacker-controlled page. The browser automatically sends the attacker's site as the Referer, and the application redirects back to it. This can be used for phishing or credential theft, as the redirect originates from a trusted domain. The severity varies by endpoint; public endpoints require no authentication and are trivially exploitable, while admin-only endpoints require an authenticated session but remain vulnerable if an admin follows a link from an external source such as email or chat. The issue is fixed in versions: 1.9.12, 1.10.16, 1.11.17, 1.12.23, 1.13.15, 1.14.18, 2.0.16, 2.1.12, 2.2.3 and above.
Attack profile
How easy it is to exploit
- Attack vector
- Network
- Complexity
- Low
- Privileges needed
- None
- User interaction
- None
What an attacker can affect
- Confidentiality
- None
- Integrity
- None
- Availability
- None
Exploit likelihood
What each source reports
CVE List Score used
6.9
Sylius has an Open Redirect via Referer Header
Sylius is an Open Source eCommerce Framework on Symfony. CurrencySwitchController::switchAction(), ImpersonateUserController::impersonateAction() and StorageBasedLocaleSwitcher::handle() use the HTTP Referer header directly when redirecting. The attack requires the victim to click a legitimate application link placed on an attacker-controlled page. The browser automatically sends the attacker's site as the Referer, and the application redirects back to it. This can be used for phishing or credential theft, as the redirect originates from a trusted domain. The severity varies by endpoint; public endpoints require no authentication and are trivially exploitable, while admin-only endpoints require an authenticated session but remain vulnerable if an admin follows a link from an external source such as email or chat. The issue is fixed in versions: 1.9.12, 1.10.16, 1.11.17, 1.12.23, 1.13.15, 1.14.18, 2.0.16, 2.1.12, 2.2.3 and above.
- Record
CVE-2026-31819- CVSS 4.0
- 6.9 Medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:L - Weakness
- CWE-601
- Updated
- 2026-11-02
EUVDEUVD-2026-10911
6.9
Sylius is an Open Source eCommerce Framework on Symfony. CurrencySwitchController::switchAction(), ImpersonateUserController::impersonateAction() and StorageBasedLocaleSwitcher::handle() use the HTTP Referer header directly when redirecting. The attack requires the victim to click a legitimate application link placed on an attacker-controlled page. The browser automatically sends the attacker's site as the Referer, and the application redirects back to it. This can be used for phishing or credential theft, as the redirect originates from a trusted domain. The severity varies by endpoint; public endpoints require no authentication and are trivially exploitable, while admin-only endpoints require an authenticated session but remain vulnerable if an admin follows a link from an external source such as email or chat. The issue is fixed in versions: 1.9.12, 1.10.16, 1.11.17, 1.12.23, 1.13.15, 1.14.18, 2.0.16, 2.1.12, 2.2.3 and above.
- Record
EUVD-2026-10911- CVSS 4.0
- 6.9 Medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:L - Updated
- 2026-11-02
GitHub AdvisoriesGHSA-9ffx-f77r-756w
6.9
Sylius has an Open Redirect via Referer Header
Impact
CurrencySwitchController::switchAction(), ImpersonateUserController::impersonateAction() and StorageBasedLocaleSwitcher::handle() use the HTTP Referer header directly when redirecting.
The attack requires the victim to click a legitimate application link placed on an attacker-controlled page. The browser automatically sends the attacker's site as the Referer, and the application redirects back to it. This can be used for phishing or credential theft, as the redirect originates from a trusted domain.
The severity varies by endpoint; public endpoints require no authentication and are trivially exploitable, while admin-only endpoints require an authenticated session but remain vulnerable if an admin follows a link from an external source such as email or chat.
Affected classes:
CurrencySwitchController::switchAction()- publicStorageBasedLocaleSwitcher::handle()- public, used in locale switching without having locale in theurlImpersonateUserController::impersonateAction()- admin-only
Patches
The issue is fixed in versions: 1.9.12, 1.10.16, 1.11.17, 1.12.23, 1.13.15, 1.14.18, 2.0.16, 2.1.12, 2.2.3 and above.
Workarounds
If you cannot update Sylius immediately, copy the affected classes from vendor to your project's src/ directory, apply the fix, and override the service definitions.
Step 1 - CurrencySwitchController
Copy from vendor/sylius/sylius/src/Sylius/Bundle/ShopBundle/Controller/CurrencySwitchController.php to src/Controller/CurrencySwitchController.php and apply the following changes:
-namespace Sylius\Bundle\ShopBundle\Controller;
+namespace App\Controller;
use Sylius\Component\Channel\Context\ChannelContextInterface;
use Sylius\Component\Core\Currency\CurrencyStorageInterface;
use Sylius\Component\Core\Model\ChannelInterface;
use Symfony\Component\HttpFoundation\RedirectResponse;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
+use Symfony\Component\Routing\RouterInterface;
final class CurrencySwitchController
{
public function __construct(
private Environment $templatingEngine, // for 1.x version
private CurrencyStorageInterface $currencyStorage,
private ChannelContextInterface $channelContext,
+ private RouterInterface $router,
) {
}
public function switchAction(Request $request, string $code): Response
{
/** @var ChannelInterface $channel */
$channel = $this->channelContext->getChannel();
$this->currencyStorage->set($channel, $code);
- return new RedirectResponse($request->headers->get('referer', $request->getSchemeAndHttpHost()));
+ return new RedirectResponse($this->router->generate('sylius_shop_homepage'));
}
}
Step 2 - ImpersonateUserController
Copy from vendor/sylius/sylius/src/Sylius/Bundle/AdminBundle/Controller/ImpersonateUserController.php to src/Controller/Admin/ImpersonateUserController.php and apply the following changes:
-namespace Sylius\Bundle\AdminBundle\Controller;
+namespace App\Controller\Admin;
// ... (keep all existing use statements)
public function impersonateAction(Request $request, string $username): Response
{
// ... (keep authorization check and impersonation logic)
$this->addFlash($request, $username);
- $redirectUrl = $request->headers->get(
- 'referer',
+ return new RedirectResponse(
$this->router->generate('sylius_admin_customer_show', ['id' => $user->getId()])
);
-
- return new RedirectResponse($redirectUrl);
}
Step 3 - StorageBasedLocaleSwitcher (only if you use locale_switcher: storage)
Note: Skip this step if you use the default
locale_switcher: urlmode.
Copy from vendor/sylius/sylius/src/Sylius/Bundle/ShopBundle/Locale/StorageBasedLocaleSwitcher.php to src/Locale/StorageBasedLocaleSwitcher.php and apply the…
- Record
GHSA-9ffx-f77r-756w- CVSS 4.0
- 6.9 Medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:L - Weakness
- CWE-601
- Updated
- 2026-11-02
NVD
6.9
Sylius is an Open Source eCommerce Framework on Symfony. CurrencySwitchController::switchAction(), ImpersonateUserController::impersonateAction() and StorageBasedLocaleSwitcher::handle() use the HTTP Referer header directly when redirecting. The attack requires the victim to click a legitimate application link placed on an attacker-controlled page. The browser automatically sends the attacker's site as the Referer, and the application redirects back to it. This can be used for phishing or credential theft, as the redirect originates from a trusted domain. The severity varies by endpoint; public endpoints require no authentication and are trivially exploitable, while admin-only endpoints require an authenticated session but remain vulnerable if an admin follows a link from an external source such as email or chat. The issue is fixed in versions: 1.9.12, 1.10.16, 1.11.17, 1.12.23, 1.13.15, 1.14.18, 2.0.16, 2.1.12, 2.2.3 and above.
- Record
CVE-2026-31819- CVSS 4.0
- 6.9 Medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:L/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X - CVSS 3.1
- 6.1 Medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N - Weakness
- CWE-601
- Updated
- 2026-11-02
OSV
6.9
Sylius has an Open Redirect via Referer Header
Sylius is an Open Source eCommerce Framework on Symfony. CurrencySwitchController::switchAction(), ImpersonateUserController::impersonateAction() and StorageBasedLocaleSwitcher::handle() use the HTTP Referer header directly when redirecting. The attack requires the victim to click a legitimate application link placed on an attacker-controlled page. The browser automatically sends the attacker's site as the Referer, and the application redirects back to it. This can be used for phishing or credential theft, as the redirect originates from a trusted domain. The severity varies by endpoint; public endpoints require no authentication and are trivially exploitable, while admin-only endpoints require an authenticated session but remain vulnerable if an admin follows a link from an external source such as email or chat. The issue is fixed in versions: 1.9.12, 1.10.16, 1.11.17, 1.12.23, 1.13.15, 1.14.18, 2.0.16, 2.1.12, 2.2.3 and above.
- Record
CVE-2026-31819- CVSS 4.0
- 6.9 Medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:L - Weakness
- CWE-601
- Updated
- 2026-11-02
OSVGHSA-9ffx-f77r-756w
6.9
Sylius has an Open Redirect via Referer Header
Impact
CurrencySwitchController::switchAction(), ImpersonateUserController::impersonateAction() and StorageBasedLocaleSwitcher::handle() use the HTTP Referer header directly when redirecting.
The attack requires the victim to click a legitimate application link placed on an attacker-controlled page. The browser automatically sends the attacker's site as the Referer, and the application redirects back to it. This can be used for phishing or credential theft, as the redirect originates from a trusted domain.
The severity varies by endpoint; public endpoints require no authentication and are trivially exploitable, while admin-only endpoints require an authenticated session but remain vulnerable if an admin follows a link from an external source such as email or chat.
Affected classes:
CurrencySwitchController::switchAction()- publicStorageBasedLocaleSwitcher::handle()- public, used in locale switching without having locale in theurlImpersonateUserController::impersonateAction()- admin-only
Patches
The issue is fixed in versions: 1.9.12, 1.10.16, 1.11.17, 1.12.23, 1.13.15, 1.14.18, 2.0.16, 2.1.12, 2.2.3 and above.
Workarounds
If you cannot update Sylius immediately, copy the affected classes from vendor to your project's src/ directory, apply the fix, and override the service definitions.
Step 1 - CurrencySwitchController
Copy from vendor/sylius/sylius/src/Sylius/Bundle/ShopBundle/Controller/CurrencySwitchController.php to src/Controller/CurrencySwitchController.php and apply the following changes:
-namespace Sylius\Bundle\ShopBundle\Controller;
+namespace App\Controller;
use Sylius\Component\Channel\Context\ChannelContextInterface;
use Sylius\Component\Core\Currency\CurrencyStorageInterface;
use Sylius\Component\Core\Model\ChannelInterface;
use Symfony\Component\HttpFoundation\RedirectResponse;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
+use Symfony\Component\Routing\RouterInterface;
final class CurrencySwitchController
{
public function __construct(
private Environment $templatingEngine, // for 1.x version
private CurrencyStorageInterface $currencyStorage,
private ChannelContextInterface $channelContext,
+ private RouterInterface $router,
) {
}
public function switchAction(Request $request, string $code): Response
{
/** @var ChannelInterface $channel */
$channel = $this->channelContext->getChannel();
$this->currencyStorage->set($channel, $code);
- return new RedirectResponse($request->headers->get('referer', $request->getSchemeAndHttpHost()));
+ return new RedirectResponse($this->router->generate('sylius_shop_homepage'));
}
}
Step 2 - ImpersonateUserController
Copy from vendor/sylius/sylius/src/Sylius/Bundle/AdminBundle/Controller/ImpersonateUserController.php to src/Controller/Admin/ImpersonateUserController.php and apply the following changes:
-namespace Sylius\Bundle\AdminBundle\Controller;
+namespace App\Controller\Admin;
// ... (keep all existing use statements)
public function impersonateAction(Request $request, string $username): Response
{
// ... (keep authorization check and impersonation logic)
$this->addFlash($request, $username);
- $redirectUrl = $request->headers->get(
- 'referer',
+ return new RedirectResponse(
$this->router->generate('sylius_admin_customer_show', ['id' => $user->getId()])
);
-
- return new RedirectResponse($redirectUrl);
}
Step 3 - StorageBasedLocaleSwitcher (only if you use locale_switcher: storage)
Note: Skip this step if you use the default
locale_switcher: urlmode.
Copy from vendor/sylius/sylius/src/Sylius/Bundle/ShopBundle/Locale/StorageBasedLocaleSwitcher.php to src/Locale/StorageBasedLocaleSwitcher.php and apply the…
- Record
GHSA-9ffx-f77r-756w- CVSS 4.0
- 6.9 Medium
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:L - Weakness
- CWE-601
- Updated
- 2026-11-02
Affected products
Affected packages
| Package | Affected | Fixed |
|---|---|---|
sylius/syliusPackagist |
through 1.9.11 | 1.9.12 |
sylius/syliusPackagist |
1.10.0 to 1.10.15 | 1.10.16 |
sylius/syliusPackagist |
1.11.0 to 1.11.16 | 1.11.17 |
sylius/syliusPackagist |
1.12.0 to 1.12.22 | 1.12.23 |
sylius/syliusPackagist |
1.13.0 to 1.13.14 | 1.13.15 |
sylius/syliusPackagist |
1.14.0 to 1.14.17 | 1.14.18 |
sylius/syliusPackagist |
2.0.0 to 2.0.15 | 2.0.16 |
sylius/syliusPackagist |
2.1.0 to 2.1.11 | 2.1.12 |
sylius/syliusPackagist |
2.2.0 to 2.2.2 | 2.2.3 |
sylius/syliusPackagist |
before 1.9.12, plus listed versions v0.1.0v0.10.0v0.11.0v0.12.0v0.13.0 Show 45 moreShow lessv0.14.0v0.15.0v0.16.0v0.17.0v0.18.0v0.19.0v0.2.0v0.3.0v0.5.0v0.6.0v0.7.0v0.8.0v0.9.0v1.0.0v1.0.0-alpha.1v1.0.0-alpha.2v1.0.0-beta.1v1.0.0-beta.2v1.0.0-beta.3v1.0.0-rc.1v1.0.0-rc.2v1.0.1v1.0.10v1.0.11v1.0.12v1.0.13v1.0.14v1.0.15v1.0.16v1.0.17v1.0.18v1.0.2v1.0.3v1.0.4v1.0.5v1.0.6v1.0.7v1.0.8v1.0.9v1.1.0v1.1.0-RCv1.1.1v1.1.10v1.1.11v1.1.12 |
1.9.12 |
Show 8 moreShow less
| Package | Affected | Fixed |
|---|---|---|
sylius/syliusPackagist |
1.10.0 up to 1.10.16, plus listed versions v1.10.0v1.10.1v1.10.10v1.10.11v1.10.12 Show 11 moreShow lessv1.10.13v1.10.14v1.10.15v1.10.2v1.10.3v1.10.4v1.10.5v1.10.6v1.10.7v1.10.8v1.10.9 |
1.10.16 |
sylius/syliusPackagist |
1.11.0 up to 1.11.17, plus listed versions v1.11.0v1.11.1v1.11.10v1.11.11v1.11.12 Show 12 moreShow lessv1.11.13v1.11.14v1.11.15v1.11.16v1.11.2v1.11.3v1.11.4v1.11.5v1.11.6v1.11.7v1.11.8v1.11.9 |
1.11.17 |
sylius/syliusPackagist |
1.12.0 up to 1.12.23, plus listed versions v1.12.0v1.12.1v1.12.10v1.12.11v1.12.12 Show 18 moreShow lessv1.12.13v1.12.14v1.12.15v1.12.16v1.12.17v1.12.18v1.12.19v1.12.2v1.12.20v1.12.21v1.12.22v1.12.3v1.12.4v1.12.5v1.12.6v1.12.7v1.12.8v1.12.9 |
1.12.23 |
sylius/syliusPackagist |
1.13.0 up to 1.13.15, plus listed versions v1.13.0v1.13.1v1.13.10v1.13.11v1.13.12 Show 10 moreShow lessv1.13.13v1.13.14v1.13.2v1.13.3v1.13.4v1.13.5v1.13.6v1.13.7v1.13.8v1.13.9 |
1.13.15 |
sylius/syliusPackagist |
1.14.0 up to 1.14.18, plus listed versions v1.14.0v1.14.1v1.14.10v1.14.11v1.14.12 Show 13 moreShow lessv1.14.13v1.14.14v1.14.15v1.14.16v1.14.17v1.14.2v1.14.3v1.14.4v1.14.5v1.14.6v1.14.7v1.14.8v1.14.9 |
1.14.18 |
sylius/syliusPackagist |
2.0.0 up to 2.0.16, plus listed versions v2.0.0v2.0.1v2.0.10v2.0.11v2.0.12 Show 11 moreShow lessv2.0.13v2.0.14v2.0.15v2.0.2v2.0.3v2.0.4v2.0.5v2.0.6v2.0.7v2.0.8v2.0.9 |
2.0.16 |
sylius/syliusPackagist |
2.1.0 up to 2.1.12, plus listed versions v2.1.0v2.1.1v2.1.10v2.1.11v2.1.2 Show 7 moreShow lessv2.1.3v2.1.4v2.1.5v2.1.6v2.1.7v2.1.8v2.1.9 |
2.1.12 |
sylius/syliusPackagist |
2.2.0 up to 2.2.3, plus listed versions v2.2.0v2.2.1v2.2.2 |
2.2.3 |
History
| Recorded | Changed | Sources |
|---|---|---|
| first indexed | CVE List, EUVD, GitHub Advisories, NVD, OSV |
Dates are when Every CVE recorded each change. Upstream dates may differ.
In short
CVE-2026-31819 is a medium vulnerability (CVSS 6.9) in Sylius, published March 10, 2026. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.21%, the 10th percentile. Fixed in sylius/sylius 1.9.12.
References
Left out here: 138 versions and the rest of 2 source descriptions. The JSON record has them.