CVE-2020-5220

CVE-2020-5220 is a medium-severity security vulnerability in sylius/resource-bundle (composer), affecting versions >= 1.4.0, < 1.4.6. It is fixed in 1.4.6, 1.5.1, 1.6.3, 1.3.12, 1.4.4, 1.3.13.

Summary

Workarounds

Service sylius.resource_controller.request_configuration_factory can be overridden with an implementation copied from \Sylius\Bundle\ResourceBundle\Controller\RequestConfigurationFactory where the part that handles custom serialisation groups is deleted.

Impact

ResourceBundle accepts and uses any serialisation groups to be passed via a HTTP header. This might lead to data exposure by using an unintended serialisation group - for example it could make Shop API use a more permissive group from Admin API.

Anyone exposing an API with ResourceBundle's controller is affected. The vulnerable versions are: <1.3 || >=1.3.0 <=1.3.12 || >=1.4.0 <=1.4.5 || >=1.5.0 <=1.5.0 || >=1.6.0 <=1.6.2.

CVE-2020-5220 has a CVSS score of 4.4 (Medium). The vector is network-reachable, low privileges required, and user interaction required. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (1.4.6, 1.5.1, 1.6.3, 1.3.12, 1.4.4, 1.3.13); upgrading removes the vulnerable code path.

Affected versions

sylius/resource-bundle (>= 1.4.0, < 1.4.6) sylius/resource-bundle (>= 1.5.0, < 1.5.1) sylius/resource-bundle (>= 1.6.0, < 1.6.3) sylius/sylius (< 1.3.12) sylius/sylius (>= 1.4.0, < 1.4.4) sylius/resource-bundle (>= 1.0.0, < 1.3.13)

Security releases

sylius/resource-bundle → 1.4.6 (composer) sylius/resource-bundle → 1.5.1 (composer) sylius/resource-bundle → 1.6.3 (composer) sylius/sylius → 1.3.12 (composer) sylius/sylius → 1.4.4 (composer) sylius/resource-bundle → 1.3.13 (composer)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

See it in your environment

Remediation advice

The patch is provided for ResourceBundle 1.3.13, 1.4.6, 1.5.1 and 1.6.3, but not for any versions below 1.3.

After it is applied, It allows to choose only the groups that are defined in serialization_groups or allowed_serialization_groups route definition. Any group not defined in those will not be used.

This behaviour might be a BC break for those using custom groups via the HTTP header, please adjust allowed_serialization_groups accordingly.

Frequently Asked Questions

  1. What is CVE-2020-5220? CVE-2020-5220 is a medium-severity security vulnerability in sylius/resource-bundle (composer), affecting versions >= 1.4.0, < 1.4.6. It is fixed in 1.4.6, 1.5.1, 1.6.3, 1.3.12, 1.4.4, 1.3.13.
  2. How severe is CVE-2020-5220? CVE-2020-5220 has a CVSS score of 4.4 (Medium). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
  3. Which packages are affected by CVE-2020-5220?
    • sylius/resource-bundle (composer) (versions >= 1.4.0, < 1.4.6)
    • sylius/sylius (composer) (versions < 1.3.12)
  4. Is there a fix for CVE-2020-5220? Yes. CVE-2020-5220 is fixed in 1.4.6, 1.5.1, 1.6.3, 1.3.12, 1.4.4, 1.3.13. Upgrade to this version or later.
  5. Is CVE-2020-5220 exploitable, and should I be worried? Whether CVE-2020-5220 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  6. What actually determines whether CVE-2020-5220 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  7. How do I fix CVE-2020-5220?
    • Upgrade sylius/resource-bundle to 1.4.6 or later
    • Upgrade sylius/resource-bundle to 1.5.1 or later
    • Upgrade sylius/resource-bundle to 1.6.3 or later
    • Upgrade sylius/sylius to 1.3.12 or later
    • Upgrade sylius/sylius to 1.4.4 or later
    • Upgrade sylius/resource-bundle to 1.3.13 or later

Other vulnerabilities in sylius/resource-bundle

Stop the waste.
Protect your environment with Kodem.