Skip to content
Heist/ feed
Back to feed
HighFix available

Excelize ANCHORARRAY: mutually-referencing array formulas recurse unboundedly via re-entrant CalcCellValue, causing a fatal stack overflow

Type: advisorySources: OSV2 source records

### Summary `ANCHORARRAY` (calc.go:15137 on current master) evaluates each cell of the referenced spill range by calling the **exported** `CalcCellValue`, which unconditionally constructs a fresh `calcContext` — fresh entry marker, fresh iterations map, full `MaxCalcIterations` budget (calc.go:896-900). The circular-reference control only exists **within one context**: the entry-exclusion marker and per-ref iteration budget are fields of that single context, and completion-based caching (`formulaArgCache`/`calcRawCache`) only ever stores results of evaluations that *finish*. During a pure cycle no nested evaluation ever finishes, so nothing is ever cached to break the recursion, and each hop re-arms the entire budget. Two ordinary, Excel-legal constructs in an attacker-supplied workbook are enough: - `A1` (dynamic array formula, ref `A1:A1`): `_xlfn.ANCHORARRAY($B$1)` - `B1` (dynamic array formula, ref `B1:B1`): `_xlfn.ANCHORARRAY($A$1)` → `CalcCellValue → calcCellValue → evalInfixExp → parseReference → cellResolver → … → ANCHORARRAY → CalcCellValue → …` forever, ending in a **fatal, unrecoverable** Go runtime error: `runtime: goroutine stack exceeds …-byte limit / fatal error: stack overflow`. Go stack overflows cannot be recovered — the whole process aborts. ### Details - The terminating edge the iterations gate is supposed to provide does not exist across contexts: there is no in-flight tracking shared between nested `CalcCellValue` calls. - Both formulas are ordinary Exce

Products
github.com/xuri/excelize/v2
Affected versions
Not specified
Fixed versions
2.11.1-0.20260911060113-ea12859e43c6
CVEs
CVE-2026-107216
Confirmed fixed CVEs
Not specified
Updated in this feed
31 Oct 2026, 08:45 UTC · Revision 1

Source evidence

Excelize ANCHORARRAY: mutually-referencing array formulas recurse unboundedly via re-entrant CalcCellValue, causing a fatal stack overflow

core-osv · Original source

Published 8 Oct 2026, 16:31 UTC

### Summary `ANCHORARRAY` (calc.go:15137 on current master) evaluates each cell of the referenced spill range by calling the **exported** `CalcCellValue`, which unconditionally constructs a fresh `calcContext` — fresh entry marker, fresh iterations map, full `MaxCalcIterations` budget (calc.go:896-900). The circular-reference control only exists **within one context**: the entry-exclusion marker and per-ref iteration budget are fields of that single context, and completion-based caching (`formulaArgCache`/`calcRawCache`) only ever stores results of evaluations that *finish*. During a pure cycle no nested evaluation ever finishes, so nothing is ever cached to break the recursion, and each hop re-arms the entire budget. Two ordinary, Excel-legal constructs in an attacker-supplied workbook are enough: - `A1` (dynamic array formula, ref `A1:A1`): `_xlfn.ANCHORARRAY($B$1)` - `B1` (dynamic array formula, ref `B1:B1`): `_xlfn.ANCHORARRAY($A$1)` → `CalcCellValue → calcCellValue → evalInfixExp → parseReference → cellResolver → … → ANCHORARRAY → CalcCellValue → …` forever, ending in a **fatal, unrecoverable** Go runtime error: `runtime: goroutine stack exceeds …-byte limit / fatal error: stack overflow`. Go stack overflows cannot be recovered — the whole process aborts. ### Details - The terminating edge the iterations gate is supposed to provide does not exist across contexts: there is no in-flight tracking shared between nested `CalcCellValue` calls. - Both formulas are ordinary Exce

osv:GHSA-wp2g-vpjj-g53r

github.com/xuri/excelize/v2

Fixed versions: 2.11.1-0.20260911060113-ea12859e43c6

Complete source record
{
  "id": "f3a99e9bd59702bfc99634f5cbdb4e59e28fd5ba90115a42897286e7a62d9e10",
  "url": "https://osv.dev/vulnerability/GHSA-wp2g-vpjj-g53r",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Excelize ANCHORARRAY: mutually-referencing array formulas recurse unboundedly via re-entrant CalcCellValue, causing a fatal stack overflow",
    "summary": "### Summary `ANCHORARRAY` (calc.go:15137 on current master) evaluates each cell of the referenced spill range by calling the **exported** `CalcCellValue`, which unconditionally constructs a fresh `calcContext` — fresh entry marker, fresh iterations map, full `MaxCalcIterations` budget (calc.go:896-900). The circular-reference control only exists **within one context**: the entry-exclusion marker and per-ref iteration budget are fields of that single context, and completion-based caching (`formulaArgCache`/`calcRawCache`) only ever stores results of evaluations that *finish*. During a pure cycle no nested evaluation ever finishes, so nothing is ever cached to break the recursion, and each hop re-arms the entire budget. Two ordinary, Excel-legal constructs in an attacker-supplied workbook are enough: - `A1` (dynamic array formula, ref `A1:A1`): `_xlfn.ANCHORARRAY($B$1)` - `B1` (dynamic array formula, ref `B1:B1`): `_xlfn.ANCHORARRAY($A$1)` → `CalcCellValue → calcCellValue → evalInfixExp → parseReference → cellResolver → … → ANCHORARRAY → CalcCellValue → …` forever, ending in a **fatal, unrecoverable** Go runtime error: `runtime: goroutine stack exceeds …-byte limit / fatal error: stack overflow`. Go stack overflows cannot be recovered — the whole process aborts. ### Details - The terminating edge the iterations gate is supposed to provide does not exist across contexts: there is no in-flight tracking shared between nested `CalcCellValue` calls. - Both formulas are ordinary Exce",
    "evidence": "osv:GHSA-wp2g-vpjj-g53r",
    "products": [
      {
        "name": {
          "value": "github.com/xuri/excelize/v2",
          "evidence": "/affected/0/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.11.1-0.20260911060113-ea12859e43c6",
            "evidence": "/affected/0/ranges"
          }
        ],
        "affected_versions": []
      }
    ],
    "severity": "high",
    "structured": {
      "id": "GHSA-wp2g-vpjj-g53r",
      "aliases": [
        "CVE-2026-107216",
        "GHSA-wp2g-vpjj-g53r",
        "GO-2026-6688"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "type": "SEMVER",
              "events": [
                {
                  "introduced": "2.8.1"
                },
                {
                  "fixed": "2.11.1-0.20260911060113-ea12859e43c6"
                }
              ]
            }
          ],
          "package": {
            "name": "github.com/xuri/excelize/v2",
            "purl": "pkg:golang/github.com/xuri/excelize/v2",
            "ecosystem": "Go"
          },
          "database_specific": {
            "source": "https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/10/GHSA-wp2g-vpjj-g53r/GHSA-wp2g-vpjj-g53r.json"
          }
        }
      ],
      "modified": "2026-10-19T21:41:18.715896320Z",
      "provider": "osv",
      "references": [
        "https://github.com/qax-os/excelize/security/advisories/GHSA-wp2g-vpjj-g53r",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-107216",
        "https://github.com/qax-os/excelize/commit/ea12859e43c64d498ecf839263c5f917391f3316",
        "https://github.com/qax-os/excelize"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-674"
        ],
        "severity": "HIGH",
        "github_reviewed": true,
        "nvd_published_at": "2026-10-07T18:17:19Z",
        "github_reviewed_at": "2026-10-08T16:31:21Z"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-107216",
        "evidence": "/aliases"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/database_specific/severity"
  },
  "source_id": "core-osv",
  "document_id": 376798,
  "published_at": "2026-10-08T16:31:21+00:00"
}

Mutually-referencing array formulas recurse unboundedly, causing a fatal stack overflow in github.com/xuri/excelize

core-osv · Original source

Published 19 Oct 2026, 21:08 UTC

Mutually-referencing array formulas recurse unboundedly, causing a fatal stack overflow in github.com/xuri/excelize

osv:GO-2026-6688

github.com/xuri/excelize/v2

Fixed versions: 2.11.1-0.20260911060113-ea12859e43c6

Complete source record
{
  "id": "c864e64cd4b0a676fcef0aa913d37ba39ebbc4345ee87a0d03bad147a49d4367",
  "url": "https://osv.dev/vulnerability/GO-2026-6688",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Mutually-referencing array formulas recurse unboundedly, causing a fatal stack overflow in github.com/xuri/excelize",
    "summary": "Mutually-referencing array formulas recurse unboundedly, causing a fatal stack overflow in github.com/xuri/excelize",
    "evidence": "osv:GO-2026-6688",
    "products": [
      {
        "name": {
          "value": "github.com/xuri/excelize/v2",
          "evidence": "/affected/0/package/name"
        },
        "prerequisites": [],
        "fixed_versions": [
          {
            "value": "2.11.1-0.20260911060113-ea12859e43c6",
            "evidence": "/affected/0/ranges"
          }
        ],
        "affected_versions": []
      }
    ],
    "severity": "unknown",
    "structured": {
      "id": "GO-2026-6688",
      "aliases": [
        "CVE-2026-107216",
        "GHSA-wp2g-vpjj-g53r",
        "GO-2026-6688"
      ],
      "affected": [
        {
          "ranges": [
            {
              "type": "SEMVER",
              "events": [
                {
                  "introduced": "2.8.1"
                },
                {
                  "fixed": "2.11.1-0.20260911060113-ea12859e43c6"
                }
              ]
            }
          ],
          "package": {
            "name": "github.com/xuri/excelize/v2",
            "purl": "pkg:golang/github.com/xuri/excelize/v2",
            "ecosystem": "Go"
          },
          "database_specific": {
            "source": "https://vuln.go.dev/ID/GO-2026-6688.json"
          },
          "ecosystem_specific": {}
        }
      ],
      "modified": "2026-10-19T21:31:49.924461633Z",
      "provider": "osv",
      "references": [
        "https://github.com/qax-os/excelize/security/advisories/GHSA-wp2g-vpjj-g53r",
        "https://github.com/qax-os/excelize/commit/ea12859e43c64d498ecf839263c5f917391f3316"
      ],
      "provider_metadata": {
        "url": "https://pkg.go.dev/vuln/GO-2026-6688",
        "review_status": "REVIEWED"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-107216",
        "evidence": "/aliases"
      }
    ],
    "security_relevant": true,
    "severity_evidence": null
  },
  "source_id": "core-osv",
  "document_id": 376691,
  "published_at": "2026-10-19T21:08:21+00:00"
}