Forgejo Remote Code Execution via Crafted Template Repository

Release Date: 15th September 2026 (Added 16 September 2026)

Impact : CRITICAL

TLP Rating: Clear

The Department of Communications and Digital Transformation (DCDT) through CERT Vanuatu (CERTVU), provides the following advisory.

This alert is relevant to Organizations and System/Network administrators that self-host a Forgejo instance for source code management and CI/CD. This alert is intended to be understood by technical users and systems administrators.

What is it?

CVE-2026-89094 is a critical remote code execution vulnerability in Forgejo, a widely-used open-source, self-hosted Git service and lightweight alternative to platforms such as GitLab - already judged relevant to Vanuatu in Advisory 302 and Advisory 309. When a repository is created from a "template repository," Forgejo performs variable expansion on files placed under .forgejo/template inside that template. The expansion process could be abused to recreate a .git folder with attacker-controlled content; Git then adopts this malicious folder during initialization of the new repository, which can lead to remote code execution and arbitrary data access on the host running Forgejo.

Reference

  1. https://www.cve.org/CVERecord?id=CVE-2026-89094
  2. https://codeberg.org/forgejo/forgejo/milestone/139655