{"id":"CVE-2025-49136","published":"2025-06-09T16:21:48Z","modified":"2025-06-10T13:25:02Z","title":"listmonk's Sprig template Injection vulnerability leads to reading of Environment Variable for low privilege user","vendor":"knadh","product":"listmonk","tier":"tail","description":{"text":"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.","provenance":"source","from":"CVE.org"},"cvss":{"score":9.1,"severity":"CRITICAL","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.01648,"percentile":0.77079,"provenance":"source"},"cwes":[{"id":"CWE-1336","name":"Improper Neutralization of Special Elements Used in a Template Engine"}],"references":[{"url":"https://github.com/knadh/listmonk/security/advisories/GHSA-jc7g-x28f-3v3h","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/knadh/listmonk/commit/d27d2c32cf3af2d0b24e29ea5a686ba149b49b3e","tags":["x_refsource_MISC"]},{"url":"https://github.com/knadh/listmonk/releases/tag/v5.0.2","tags":["x_refsource_MISC"]}],"priority":{"score":26.8,"factors":[{"name":"EPSS percentile","points":15.42},{"name":"Public exploit code","points":5.0},{"name":"CVSS severity","points":6.37}]},"exploitSources":{"metasploit":[{"name":"Listmonk Insecure Sprig Template Functions Environment Disclosure","module":"auxiliary/gather/listmonk_env_disclosure","type":"auxiliary","disclosureDate":"2025-06-08","url":"https://github.com/rapid7/metasploit-framework/blob/master/modules/auxiliary/gather/listmonk_env_disclosure.rb"}],"first":{"date":"2025-06-08","source":"Metasploit","url":"https://github.com/rapid7/metasploit-framework/blob/master/modules/auxiliary/gather/listmonk_env_disclosure.rb"},"provenance":"source"},"vendorSlug":"knadh","affectedVersions":[{"vendor":"knadh","product":"listmonk","versions":[">= 4.0.0, < 5.0.2"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total","timestamp":"2025-06-10T13:24:43.793880Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Go","package":"github.com/knadh/listmonk","vulnerableRanges":[">=4.0.0, <5.0.2","all versions"],"patched":["5.0.2"],"from":["GHSA-jc7g-x28f-3v3h","GO-2025-3745"],"provenance":"source"}],"summary":{"text":"A template injection flaw in listmonk, the self-hosted newsletter and mailing list manager, lets the Sprig template functions env and expandenv (enabled by default) expose host environment variables. An attacker with low privileges, specifically campaign or template permissions on a multi-user installation, and with user interaction required, can use a {{ env }} template expression to read sensitive environment variables; the attack is reachable over the network and affects versions from 4.0.0 up to but not including 5.0.2.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T06:52:22Z"},"euvd":{"id":"EUVD-2025-17462","exploited":false,"provenance":"source"}}