# CVE-2024-52810: Prototype Pollution in @intlify/shared >=9.7.0 <= 10.0.4


- **Severity:** Medium 6.9 (`CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N`)
- **Exploited in the wild:** Not known
- **Fix available:** Yes
- **Published:** 29 Nov 2024
- **Updated:** 3 Dec 2024
- **Also known as:** GHSA-hjwq-mjwj-4x6c

## What is CVE-2024-52810?

CVE-2024-52810 is a medium-severity vulnerability in intlify vue-i18n, published on 29 Nov 2024. 

### Official description

@intlify/shared is a shared library for the intlify project. The latest version of @intlify/shared (10.0.4) is vulnerable to Prototype Pollution through the entry function(s) lib.deepCopy. An attacker can supply a payload with Object.prototype setter to introduce or modify properties within the global prototype chain, causing denial of service (DoS) as the minimum consequence. Moreover, the consequences of this vulnerability can escalate to other injection-based attacks, depending on how the library integrates within the application. For instance, if the polluted property propagates to sensitive Node.js APIs (e.g., exec, eval), it could enable an attacker to execute arbitrary commands within the application's context. This issue has been addressed in versions 9.14.2, and 10.0.5. Users are advised to upgrade. There are no known workarounds for this vulnerability.

Weakness: CWE-1321 (Improperly Controlled Modification of Object Prototype Attributes)

## Which versions are affected by CVE-2024-52810?

14 open source packages ship an affected version, including @intlify/vue-i18n-core, @intlify/shared and petite-vue-i18n.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `@intlify/vue-i18n-core` | npm | From 10.0.0 | 10.0.5 |
| `@intlify/vue-i18n-core` | npm | From 10.0.0 | 10.0.5 |
| `@intlify/vue-i18n-core` | npm | From 9.7.0 | 9.14.2 |
| `@intlify/vue-i18n-core` | npm | From 9.7.0 | 9.14.2 |
| `@intlify/shared` | npm | From 10.0.0 | 10.0.5 |
| `@intlify/shared` | npm | From 10.0.0 | 10.0.5 |
| `@intlify/shared` | npm | From 9.7.0 | 9.14.2 |
| `@intlify/shared` | npm | From 9.7.0 | 9.14.2 |
| `petite-vue-i18n` | npm | From 10.0.0 | 10.0.5 |
| `petite-vue-i18n` | npm | From 10.0.0 | 10.0.5 |
| `vue-i18n` | npm | From 10.0.0 | 10.0.5 |
| `vue-i18n` | npm | From 10.0.0 | 10.0.5 |
| `vue-i18n` | npm | From 9.7.0 | 9.14.2 |
| `vue-i18n` | npm | From 9.7.0 | 9.14.2 |

## How do I fix CVE-2024-52810?

Upgrade @intlify/vue-i18n-core to a fixed version for your release line: 10.0.5 or 9.14.2.

## Is CVE-2024-52810 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-52810 exists.

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2024-52810 and fix it if it is affected.

What it is: CVE-2024-52810 is a medium-severity vulnerability in intlify vue-i18n, published on 29 Nov 2024. 
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-52810 exists.

Affected packages and fixed versions:
- @intlify/vue-i18n-core (npm): affected from 10.0.0; fixed in 10.0.5
- @intlify/vue-i18n-core (npm): affected from 10.0.0; fixed in 10.0.5
- @intlify/vue-i18n-core (npm): affected from 9.7.0; fixed in 9.14.2
- @intlify/vue-i18n-core (npm): affected from 9.7.0; fixed in 9.14.2
- @intlify/shared (npm): affected from 10.0.0; fixed in 10.0.5
- @intlify/shared (npm): affected from 10.0.0; fixed in 10.0.5
- @intlify/shared (npm): affected from 9.7.0; fixed in 9.14.2
- @intlify/shared (npm): affected from 9.7.0; fixed in 9.14.2
- petite-vue-i18n (npm): affected from 10.0.0; fixed in 10.0.5
- petite-vue-i18n (npm): affected from 10.0.0; fixed in 10.0.5
- vue-i18n (npm): affected from 10.0.0; fixed in 10.0.5
- vue-i18n (npm): affected from 10.0.0; fixed in 10.0.5

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2024-52810/ (Markdown: https://insights.sbomify.com/CVE-2024-52810/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2024-52810
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2024-52810
- OSV: https://osv.dev/vulnerability/CVE-2024-52810

---
From sbomify Insights: https://insights.sbomify.com/CVE-2024-52810/
Summaries are generated and may contain mistakes; the official description above is the record.
