Security Digest · Vulnerability record

CVE-2025-49136: listmonk's Sprig template Injection vulnerability leads to reading of Environment Variable for low privilege user

listmonk is a standalone, self-hosted, newsletter and mailing list manager.

CVSS 9.1 Critical EPSS 1.6% · p75

Should you act?

Critical, preconditions apply

Severe if exploited, but exploitation needs conditions that may not apply to you. This signal is computed from CISA KEV, EPSS and CVSS data; it is not an editorial verdict.

  • Not in CISA KEV, but CISA’s SSVC assessment records a public proof-of-concept, so attack code exists.
  • EPSS 1.6%, percentile 75: FIRST’s model estimates a 1.6% chance of exploitation activity in the next 30 days, higher than 75% of all scored CVEs (moderate). EPSS is a probability, not a verdict.
  • Needs an account (low (any account)). Exposure depends on who can log in.
  • Only applies if your dependency tree includes github.com/knadh/listmonk (Go) >= 4.0.0, < 5.0.2, fixed in 5.0.2. Check your lockfile, including transitive dependencies.

What it is

listmonk is a standalone, self-hosted, newsletter and mailing list manager. Starting in version 4.0.0 and prior to version 5.0.2, the env and expandenv template functions which is enabled by default in Sprig enables capturing of env variables on host. While this may not be a problem on single-user (super admin) installations, on multi-user installations, this allows non-super-admin users with campaign or template permissions to use the {{ env }} template expression to capture sensitive environment variables. Users should upgrade to v5.0.2 to mitigate the issue.

From the GitHub advisory

Summary The env and expandenv template functions which is enabled by default in Sprig enables capturing of env variables on the host. While this may not be a problem on single-user (super admin) installations, on multi-user installations, this allows non-super-admin users with campaign or template permissions to use the {{ env }} template expression to capture sensitive environment variables.

Upgrade to v5.0.2 to mitigate.

---------

Demonstration

Description A critical template injection vulnerability exists in Listmonk's campaign preview functionality that allows authenticated users with minimal privileges (campaigns:get & campaigns:getall) to extract sensitive system data, including database credentials, SMTP passwords, and admin credentials due to some dangerous function being allowed.

Weakness type: CWE-1336.

Product: github.com/knadh/listmonk (Go) · Assigned by: GitHub_M · Published: 2025-06-09

Affected and fixed versions

EcosystemPackageVulnerableFirst fixed
Gogithub.com/knadh/listmonk>= 4.0.0, < 5.0.25.0.2
VendorProductAffected versions (per CVE record)
knadhlistmonk>= 4.0.0, < 5.0.2

Severity scores

Scored byCVSSScoreVector
GitHub_M3.19.1 CriticalCVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H
GitHub3.19.0 CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H
  • Attack vector: network (remotely reachable)
  • Attack complexity: low
  • Privileges required: low (any account)
  • User interaction: required (a user must click/open something)
  • Scope: changed (can affect other components)

CVSS measures how bad a flaw is if exploited, not how likely exploitation is. Read it next to the exploitation data below.

Exploitation and urgency

  • CISA KEV: not listed (no confirmed in-the-wild exploitation known to CISA).
  • CISA SSVC assessment: exploitation poc, automatable no, technical impact total.
  • FIRST EPSS (model of 2026-10-21): 1.58% probability of exploitation activity in the next 30 days; percentile 75.

Timeline

  • — CVE record published by GitHub_M
  • — GitHub-reviewed advisory GHSA-jc7g-x28f-3v3h published (critical)
  • — CVE record last updated

Sources and references

Original sources first. Version and fix details should always be confirmed against the vendor or project advisory.

Vulnerability records

  1. GitHub Advisory GHSA-jc7g-x28f-3v3h github.com
  2. CVE.org record CVE-2025-49136 cve.org
  3. NVD entry CVE-2025-49136 nvd.nist.gov

Other references from the CVE record and advisory

  1. github.com github.com
  2. github.com github.com
  3. github.com github.com

Critical Go advisories · Today’s Security Digest