---
id: "CVE-2026-120455"
kind: "vulnerability"
aliases: ["CVE-2026-120455"]
title: "rapidyaml: crafted YAML with excess anchors corrupts memory and crashes"
severity: "medium"
cvss: 6.9
epss: null
exploited: false
status: "open"
category: "package"
products: []
ecosystems: []
tags: ["c++", "package", "rapidyaml", "yaml-parsing"]
not_affected_if: ["newer-version", "trusted-input-only"]
published_at: "2026-11-02T15:17:29+00:00"
first_seen_at: "2026-11-02T15:24:03+00:00"
updated_at: "2026-11-02T15:26:08+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-120455", "first_seen_at": "2026-11-02T15:24:03+00:00"}]
---

# rapidyaml: crafted YAML with excess anchors corrupts memory and crashes

rapidyaml, a C++ YAML parsing library, has an out-of-bounds write in its annotation handling that a crafted YAML document with consecutive anchors or tags can trigger. The sources say it corrupts stack memory and crashes the process.

_Summary, check and fix written by a model from the sources; labelled as such._

## How to check

- Check whether the project depends on rapidyaml and which version is pinned, for example in `CMakeLists.txt`, a `conanfile`, a `vcpkg.json`, or a vendored copy of the `ryml` sources.
- Confirm whether the application parses untrusted YAML with it.

## Fix

- Move to a release newer than `0.16.0` (the sources link release notes; the exact fixed version is unknown from the sources).

## Timeline

- 2026-11-02T15:24:03+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-120455

## Documents

- [advisory] Third-party advisory: www.vulncheck.com https://www.vulncheck.com/advisories/rapidyaml-through-0.16.0-out-of-bounds-write-via-parseengine-add-annotation
- [fix] Release notes: github.com https://github.com/biojppm/rapidyaml/releases/tag/v0.16.0

## From the sources

rapidyaml through 0.16.0 contains an out-of-bounds write vulnerability in ParseEngine::_add_annotation() that allows attackers to corrupt memory by supplying YAML with excess anchors or tags. Attackers can submit YAML with consecutive anchors or tags to overflow the fixed two-element annotation array in release builds, corrupting stack memory and crashing the process.

---

_Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai_
