Executive brief
Network-AI is a tool used for managing environment backups. A vulnerability in its backup pruning process allows an attacker with access to the data directory to delete any file or folder on the system that the software has permission to access. This could lead to significant data loss or system instability by deleting critical project files or system data.
Technical details
A path traversal and external control of file path vulnerability exists in EnvironmentManager.pruneBackups(). The component reads backup metadata from '_manifest.json' files via listBackups() and trusts the 'path' field provided in the JSON. When pruneBackups() is invoked (manually via CLI or programmatically), it calls rmSync() on the provided path with recursive and force options enabled. An attacker with local write access to the backup directory can craft a manifest pointing to sensitive system or application directories, leading to arbitrary file deletion under the context of the Network-AI process user. This is fixed in version 5.12.2 by recomputing the deletion path from a validated backup ID and implementing containment checks.
Affected products
- Jovancoding network-ai <= 5.12.1
Timeline
- 2026-06-18: disclosed: Reported by sondt99
- 2026-06-18: patched: Fixed in v5.12.2 (commit a59c13a)
- 2026-06-19: advisory: GitHub Advisory GHSA-2fmp-9rvw-hc96 published