# CVE-2025-59689: Libraesva Email Security Gateway Command Injection

> Attackers can execute arbitrary commands via malicious compressed email attachments in Libraesva ESG, requiring an upgrade to patched versions.

- **Severity:** Medium 6.1 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N`)
- **Exploited in the wild:** Yes, since 29 Sep 2025 (CISA KEV)
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** A user has to click or open something
- **Fix available:** No
- **Published:** 19 Sep 2025
- **Updated:** 26 Feb 2026
- **Also known as:** GHSA-363h-22w6-hcrm

## What is CVE-2025-59689?

CVE-2025-59689 is a medium-severity command injection vulnerability in Libraesva Email Security Gateway, published on 19 Sep 2025. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

### Official description

Libraesva ESG 4.5 through 5.5.x before 5.5.7 allows command injection via a compressed e-mail attachment. For ESG 5.0 a fix has been released in 5.0.31. For ESG 5.1 a fix has been released in 5.1.20. For ESG 5.2 a fix has been released in 5.2.31. For ESG 5.4 a fix has been released in 5.4.8. For ESG 5.5. a fix has been released in 5.5.7.

Weakness: CWE-77 (Improper Neutralization of Special Elements used in a Command)

## Which versions are affected by CVE-2025-59689?

It affects 1 product.


Products: Libraesva Email Security Gateway.

## How do I fix CVE-2025-59689?

No fix has been published for CVE-2025-59689 yet. Limit exposure of the affected software until one is available. US federal agencies must fix it by 20 Oct 2025.

## Is CVE-2025-59689 being exploited?

Yes. Attackers have exploited CVE-2025-59689 in the wild since at least 29 Sep 2025.

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2025-59689 and fix it if it is affected.

What it is: CVE-2025-59689 is a medium-severity command injection vulnerability in Libraesva Email Security Gateway, published on 19 Sep 2025. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Exploitation: Yes. Attackers have exploited CVE-2025-59689 in the wild since at least 29 Sep 2025.

Affected product: Libraesva Email Security Gateway. No package-level version data is available, so check the vendor advisory linked from the reference page.

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2025-59689/ (Markdown: https://insights.sbomify.com/CVE-2025-59689/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2025-59689
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2025-59689
- OSV: https://osv.dev/vulnerability/CVE-2025-59689

---
From sbomify Insights: https://insights.sbomify.com/CVE-2025-59689/
Summaries are generated and may contain mistakes; the official description above is the record.
