All vulnerabilities

Servers and applications

GHSA-5h38-6755-g83w

Path traversal in the Mail Service template engine allows arbitrary host file disclosure

Severity
Medium 6.8
Published
5 Aug 2026
Last changed
5 Aug 2026
Added to UpHeron
3 Nov 2026
Fixed in
12.1.0
Weakness
Path traversal (CWE-22)CWE-73
Attack
Over the network · Needs an administrator account · No user action needed
Attacker can
Read data
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:C/C:H/I:N/A:N
Sources
Project advisories (GitHub)

Description

The Directus Mail Service resolves email template names without confirming that the resolved path stays inside the configured templates directory. An authenticated user who can configure a Flow "Send Email" operation can supply a relative template name that traverses outside the templates root, causing the Liquid engine to load and render an arbitrary file from the host filesystem. Combined with the ability to place a file with an attacker-controlled name and location, this becomes a Local File Inclusion primitive that discloses sensitive host files.

This is most impactful in multi-tenant or managed-hosting deployments, where a tenant-level administrator is expected to operate only within the application boundary and has no legitimate access to the underlying host filesystem.

MailService.renderTemplate builds the template path by joining the caller-supplied template value onto the templates directory with path.resolve.

From directus/directus's security advisory. Shortened; the full text is there.

Affected software

SoftwareAffected versions
DirectusServers and applications · github:directus/directus
  • Every version before 12.1.0

About Directus

The flexible backend for all your projects 🐰 Turn your DB into a headless CMS, admin panels, or apps with a custom UI, instant APIs, auth & more.

From its GitHub repository.
Weekly downloads (npm)
30,924npm, 15 Nov 2026
Docker Hub pulls
50,954,770Docker Hub, 15 Nov 2026
GitHub stars
38,722GitHub, 15 Nov 2026
Forks
5,000GitHub, 15 Nov 2026
Latest release
v12.6.1GitHub, 15 Nov 2026
Released
4 Nov 2026GitHub
First published on GitHub
12 Dec 2012GitHub

References