# CVE-2022-23535: LiteDB contains Deserialization of Untrusted Data

- Severity: High 7.3 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.70%, higher than 54% of CVEs (2026-12-01)
- Published: 2023-02-24T16:22:50.000Z
- Modified: 2026-06-17T04:30:18.633Z
- Also known as: GHSA-3x49-g6rc-c284
- Weaknesses: CWE-502
- SSVC (CISA-ADP): exploitation none, automatable yes, technical impact partial
- Assigned by: GitHub_M

## Description

LiteDB is a small, fast and lightweight .NET NoSQL embedded database. Versions prior to 5.0.13 are subject to Deserialization of Untrusted Data. LiteDB uses a special field in JSON documents to cast different types from `BsonDocument` to POCO classes. When instances of an object are not the same of class, `BsonMapper` use a special field `_type` string info with full class name with assembly to be loaded and fit into your model. If your end-user can send to your app a plain JSON string, deserialization can load an unsafe  object to fit into your model. This issue is patched in version 5.0.13 with some basic fixes to avoid this, but is not 100% guaranteed when using `Object` type. The next major version will contain an allow-list to select what kind of Assembly can be loaded. Workarounds are detailed in the vendor advisory.

(As written by CVE List.)

## Affected

- mbdavid LiteDB: < 5.0.13
- LiteDB (NuGet): before 5.0.13
- litedb litedb: before 5.0.13

## Every score

- GitHub_M: CVSS:3.1 7.3 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L`
- GitHub: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 9.8 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://github.com/mbdavid/LiteDB/security/advisories/GHSA-3x49-g6rc-c284> (mitigation, patch, vendor-advisory, web)
- <https://github.com/mbdavid/LiteDB/commit/4382ff4dd0dd8b8b16a4e37dfd29727c5f70f93f> (patch, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2022-23535> (advisory)
- <https://github.com/mbdavid/LiteDB/commit/d72c6774e6a13de2cfcd7d477d3575efeb75c8f2> (web)
- <https://github.com/mbdavid/LiteDB> (package)
- <https://github.com/mbdavid/LiteDB/releases/tag/v5.0.13> (web)

## Sources

- CVE List: [CVE-2022-23535](https://www.cve.org/CVERecord?id=CVE-2022-23535), CVE Terms of Use, modified 2025-03-10
- GitHub Advisory Database: [GHSA-3x49-g6rc-c284](https://github.com/advisories/GHSA-3x49-g6rc-c284), CC-BY-4.0, modified 2023-11-08
- NVD: [CVE-2022-23535](https://nvd.nist.gov/vuln/detail/CVE-2022-23535), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2022-23535 · Whole record: https://cve.day/CVE-2022-23535.json · Rebuilt by cve.day 2026-11-25T22:58:18.743Z
