5.1medium
SFTPGo allows administrators to restrict command execution from the EventManager
- Severity
- 5.1medium CVSS:4.0 by GitHub_M
- Exploit likelihood
- 0.88% (higher than 57% of CVEs)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-49cc-xrjf-9qf7GO-2024-3283
Description
SFTPGo is a full-featured and highly configurable SFTP, HTTP/S, FTP/S and WebDAV server - S3, Google Cloud Storage, Azure Blob. One powerful feature of SFTPGo is the ability to have the EventManager execute scripts or run applications in response to certain events. This feature is very common in all software similar to SFTPGo and is generally unrestricted. However, any SFTPGo administrator with permission to run a script has access to the underlying OS/container with the same permissions as the user running SFTPGo. This is unexpected for some SFTPGo administrators who think that there is a clear distinction between accessing the system shell and accessing the SFTPGo WebAdmin UI. To avoid this confusion, running system commands is disabled by default in 2.6.3, and an allow list has been added so that system administrators configuring SFTPGo must explicitly define which commands are allowed to be configured from the WebAdmin UI.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| drakkan sftpgo | >= 2.4.0, < 2.6.3 | CVE List |
| github.com/drakkan/sftpgo/v2 (Go) | from 2.4.0 before 2.6.3 | GitHub Advisory Database, Go Vulnerability Database |
| sftpgo (Go) | from 2.4.0 before 2.6.3 | GitHub Advisory Database |
| github.com/drakkan/sftpgo (Go) | all versions | Go Vulnerability Database |
All scores
| GitHub_M | 5.1medium CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N |
| GitHub | medium CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N |
Classification
SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.
What each source says
CVE List
SFTPGo is a full-featured and highly configurable SFTP, HTTP/S, FTP/S and WebDAV server - S3, Google Cloud Storage, Azure Blob. One powerful feature of SFTPGo is the ability to have the EventManager execute scripts or run applications in response to certain events. This feature is very common in all software similar to SFTPGo and is generally unrestricted. However, any SFTPGo administrator with permission to run a script has access to the underlying OS/container with the same permissions as the user running SFTPGo. This is unexpected for some SFTPGo administrators who think that there is a clear distinction between accessing the system shell and accessing the SFTPGo WebAdmin UI. To avoid this confusion, running system commands is disabled by default in 2.6.3, and an allow list has been added so that system administrators configuring SFTPGo must explicitly define which commands are allowed to be configured from the WebAdmin UI.
GitHub Advisory Database
Impact
One powerful feature of SFTPGo is the ability to have the EventManager execute scripts or run applications in response to certain events. This feature is very common in all software similar to SFTPGo and is generally unrestricted.
However, any SFTPGo administrator with permission to run a script has access to the underlying OS/container with the same permissions as the user running SFTPGo, so they can access the database and server configurations.
This is unexpected for some SFTPGo administrators who think that there is a clear distinction between accessing the system shell and accessing the SFTPGo WebAdmin UI.
Patches
To avoid this confusion, running system commands is now disabled by default, and an allow list has been added so that system administrators configuring SFTPGo must explicitly define which commands are allowed to be configured from the WebAdmin UI.
https://github.com/drakkan/sftpgo/commit/88b1850b5806eee81150873d4e565144b21021fb https://github.com/drakkan/sftpgo/commit/b524da11e9466d05fe03304713ee1c61bb276ec4
Workarounds
Allow EventManager to be used only by SFTPGo administrators who also have shell access.
Go Vulnerability Database
SFTPGo allows administrators to restrict command execution from the EventManager in github.com/drakkan/sftpgo
NVD (es)
SFTPGo es un servidor SFTP, HTTP/S, FTP/S y WebDAV con todas las funciones y altamente configurable: S3, Google Cloud Storage, Azure Blob. Una característica poderosa de SFTPGo es la capacidad de hacer que EventManager ejecute scripts o ejecute aplicaciones en respuesta a ciertos eventos. Esta característica es muy común en todo el software similar a SFTPGo y generalmente no tiene restricciones. Sin embargo, cualquier administrador de SFTPGo con permiso para ejecutar un script tiene acceso al sistema operativo/contenedor subyacente con los mismos permisos que el usuario que ejecuta SFTPGo. Esto es inesperado para algunos administradores de SFTPGo que piensan que existe una distinción clara entre acceder al shell del sistema y acceder a la interfaz de usuario de WebAdmin de SFTPGo. Para evitar esta confusión, la ejecución de comandos del sistema está deshabilitada de forma predeterminada en 2.6.3 y se agregó una lista de permitidos para que los administradores del sistema que configuren SFTPGo deban definir explícitamente qué comandos se pueden configurar desde la interfaz de usuario de WebAdmin.
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2024-52309 changed 2024-11-21 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-49cc-xrjf-9qf7 changed 2024-12-02 | CC-BY-4.0 |
| Go Vulnerability Database | GO-2024-3283 changed 2026-03-03 | CC-BY-4.0 |
| NVD | CVE-2024-52309 changed 2026-06-17 | Public domain |