Miggo Logo

CVE-2024-42354: Shopware vulnerable to Improper Access Control with ManyToMany associations in store-api

5.3

CVSS Score
3.1

Basic Information

EPSS Score
0.42871%
Published
8/8/2024
Updated
8/12/2024
KEV Status
No
Technology
TechnologyPHP

Technical Details

CVSS Vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N
Package NameEcosystemVulnerable VersionsFirst Patched Version
shopware/corecomposer<= 6.5.8.126.5.8.13
shopware/platformcomposer<= 6.5.8.126.5.8.13
shopware/corecomposer>= 6.6.0.0, <= 6.6.5.06.6.5.1
shopware/platformcomposer>= 6.6.0.0, <= 6.6.5.06.6.5.1

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability stems from incomplete association handling in criteria processing. The patched commit ad83d388 modifies SalesChannelRepository.php to add processing of ManyToManyAssociationField's toManyReferenceDefinition, indicating the original implementation lacked this crucial step. This omission allowed extensions with ManyToMany associations to bypass field-level access controls (ApiAware checks) when serializing responses, as the criteria protections weren't applied to both sides of the association.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

### Imp**t T** stor*-*PI works wit* r**ul*r *ntiti*s *n* not *xpos* *ll *i*l*s *or t** pu*li* *PI; *i*l*s n*** to ** m*rk** *s *pi*w*r* in t** *ntity***inition. So only *pi*w*r* *i*l*s o* t** *ntity***inition will ** *n*o*** to t** *in*l JSON. T**

Reasoning

T** vuln*r**ility st*ms *rom in*ompl*t* *sso*i*tion **n*lin* in *rit*ri* pro**ssin*. T** p*t**** *ommit ******** mo*i*i*s `S*l*s***nn*lR*pository.p*p` to *** pro**ssin* o* `M*nyToM*ny*sso*i*tion*i*l*`'s toM*nyR***r*n*****inition, in*i**tin* t** ori*i