CVE-2020-8176 Cross-site scripting in @shopify/koa-shopify-auth
An attacker can inject JavaScript payloads via the shop parameter in the koa-shopify-auth library, potentially executing code in the victim's browser.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is CVE-2020-8176?
CVE-2020-8176 is a medium-severity cross-site scripting vulnerability in koa-shopify-auth, published on 2 Jul 2020. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Official description
A cross-site scripting vulnerability exists in koa-shopify-auth v3.1.61-v3.1.62 that allows an attacker to inject JS payloads into the `shop` parameter on the `/shopify/auth/enable_cookies` endpoint.
Weakness: CWE-79
Which versions are affected by CVE-2020-8176?
2 open source packages ship an affected version, including @shopify/koa-shopify-auth. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
@shopify/koa-shopify-auth npm | From 3.1.61 | 3.1.63 |
@shopify/koa-shopify-auth npm | From 3.1.61 | 3.1.63 |
Products include Shopify Koa-Shopify-Auth.
How do I fix CVE-2020-8176?
Upgrade @shopify/koa-shopify-auth to 3.1.63 or later.
Escape output for the context it lands in and set a strict Content Security Policy. Upgrading the affected component is the real fix. More about Cross-site scripting.
Is CVE-2020-8176 being exploited?
There is no known exploitation of CVE-2020-8176 in the wild and no public exploit code.
Sources
Also known as GHSA-jqh7-w5pr-cr56.