# yara-x: Unvalidated deserialization in safe \`Rules::deserialize\` allows memory corruption and UB

Advisory record · `GHSA-2jx3-ff3v-j7jj`

- **Identifiers:** `GHSA-2jx3-ff3v-j7jj`
- **State:** Confirmed
- **Severity:** CVSS 4.0, no score published
- **Critical:** No
- **Weakness (CWE):** [CWE-502](https://cwe.mitre.org/data/definitions/502.html)
- **Tags:** [Insecure deserialization](https://agentprime.io/advisories/tag/deserialization.md)
- **Published:** 24 Sept 2026
- **Updated:** 24 Sept 2026
- **Reviewed by a person:** No

Published by the GitHub Advisory Database at 24 Sept 2026, 19:09 UTC. agentprime has not analysed this yet, so whether it affects any app is not known.

## Affected packages

- `yara-x` (crates.io): affected `<1.19.0`; fixed in `1.19.0`

## Machine-written summary

Summary written by Claude Haiku from the source advisory. Not reviewed by a person.

> The yara-x crate, versions before 1.19.0, has a public safe function, Rules::deserialize, that accepts arbitrary bytes and does not validate the decoded structures. An attacker who can supply serialized rule data to this function can trigger out-of-bounds reads and invalid UTF-8 handling during later scanning, which is undefined behavior. Upgrade to yara-x 1.19.0 or later, which contains the fix. Do not pass untrusted bytes to Rules::deserialize in earlier versions.

Written 3 Nov 2026.

## Not analysed yet

We haven’t published our analysis of this Advisory yet. Once a person has reviewed it, this page will say what’s vulnerable, what has to be true for your app to be affected, and how to check.

## Severity and exploitation

- Score not published, CVSS 4.0: `CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N`, from GitHub Advisory Database

- **CISA KEV:** Not listed.
- **EPSS:** No score.

## Timeline

- 31 Oct 2026, 14:24 UTC: First seen by agentprime
- 31 Oct 2026, 14:24 UTC: [Confirmed by OSV](https://osv.dev/vulnerability/GHSA-2jx3-ff3v-j7jj)

## Sources

- [GitHub Advisory Database: GHSA-2jx3-ff3v-j7jj](https://github.com/advisories/GHSA-2jx3-ff3v-j7jj)
- [OSV: GHSA-2jx3-ff3v-j7jj](https://osv.dev/vulnerability/GHSA-2jx3-ff3v-j7jj)
- <https://github.com/VirusTotal/yara-x/security/advisories/GHSA-2jx3-ff3v-j7jj>
- <https://github.com/VirusTotal/yara-x/commit/25efa375572efcfbe880a263ee3b0932d4b61a24>
- <https://github.com/VirusTotal/yara-x>
- <https://github.com/VirusTotal/yara-x/releases/tag/v1.19.0>

Facts on this page come from the GitHub Advisory Database (CC-BY 4.0), OSV and the other sources listed, as published. We don’t reproduce full advisory descriptions, which can contain exploit code.

## Check whether this affects you

A Match means an installed version is in the affected range above. Most don’t affect the app; agentprime hasn’t analysed this one yet.

- With the agentprime MCP server (<https://api.agentprime.io/mcp>), ask your agent to check the project: `check_lockfile` sends a lockfile, `check_packages` a list of installed packages, and both return the Matches and the upgrades that clear them. `get_advisory` returns this record. Setup: <https://agentprime.io/mcp.md>
- In a browser: <https://agentprime.io/check/> reads your lockfile in the browser, never uploading it.
- Whether it touches your code, with file and line: the Claude Code plugin, <https://agentprime.io/plugin.md>
- As JSON: <https://api.agentprime.io/v1/advisories/GHSA-2jx3-ff3v-j7jj>, or `POST https://api.agentprime.io/v1/match` with your packages (<https://agentprime.io/api.md>)

---

The web page: <https://agentprime.io/advisories/GHSA-2jx3-ff3v-j7jj/>. Everything for agents: <https://agentprime.io/llms.txt>.
