---
id: "CVE-2026-63120"
kind: "vulnerability"
aliases: ["CVE-2026-63120"]
title: "pghoard: incomplete path traversal fix lets restores write files outside pgdata"
severity: "high"
cvss: 8.4
epss: 0.00487
exploited: false
status: "open"
category: "package"
products: []
ecosystems: []
tags: ["azure-blob", "backup", "cloud-object-storage", "gcs", "package", "pghoard", "postgresql", "s3"]
not_affected_if: ["no-restore-from-shared-bucket", "pghoard-2.7.2-or-later"]
published_at: "2026-10-23T13:17:12+00:00"
first_seen_at: "2026-10-23T21:57:33+00:00"
updated_at: "2026-10-25T12:38:50+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-63120", "first_seen_at": "2026-10-23T21:57:33+00:00"}, {"source": "epss", "url": "https://api.first.org/data/v1/epss?cve=CVE-2026-63120", "first_seen_at": "2026-10-25T12:38:50+00:00"}]
---

# pghoard: incomplete path traversal fix lets restores write files outside pgdata

pghoard, a PostgreSQL backup daemon, fails to fully block path traversal in backup manifests before version 2.7.2. An attacker who can write to the backup object store can make a database administrator's restore write arbitrary files on the host, such as cron jobs.

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

## How to check

- Run `pghoard_restore --version` or `pip show pghoard` and compare against `2.7.2`.
- Check whether restores are run from a host where pghoard is installed at a version below `2.7.2`.
- Review who has write access to the backup bucket (S3, GCS, or Azure container) used by pghoard.

## Fix

- Upgrade pghoard to `2.7.2` or later.
- Restrict write access to the backup object storage to the pghoard backup role only.
- Until upgraded, avoid running `pghoard_restore get-basebackup` against backups from storage that untrusted parties could write to.

## Timeline

- 2026-10-23T21:57:33+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-63120
- 2026-10-25T12:38:50+00:00 epss https://api.first.org/data/v1/epss?cve=CVE-2026-63120

## From the sources

pghoard is a PostgreSQL backup daemon and restore tooling that stores backup data in cloud object stores. Prior to version 2.7.2, an incomplete path traversal fix in pghoard allows an attacker with write access to the backup object storage (such as S3, GCS, or Azure) to execute arbitrary file writes and directory creation outside the designated PostgreSQL data directory (pgdata). When a database administrator executes a restore operation (via pghoard_restore get-basebackup), a maliciously crafted delta backup manifest with path traversal sequences (e.g., ../../../../etc/cron.d/backdoor) will write arbitrary payloads to the host system. This issue has been patched in version 2.7.2.

---

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