Description
Spug through 3.4.0 contains a remote code execution vulnerability in the ping_check function that interpolates user-supplied monitor addresses directly into shell commands without validation. Authenticated users with monitor permissions can inject shell metacharacters via the /monitor/run_test/ endpoint to execute arbitrary commands as the Spug process user.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| openspug | spug | ≤ 3.4.0 | — |
References
- GitHub Issue #741 issue-tracking
- https://github.com/openspug/spug product
- https://github.com/openspug/spug/blob/v3.4.0/spug_api/apps/monitor/executors.py technical-description
- https://github.com/openspug/spug/blob/v3.4.0/spug_api/apps/monitor/views.py technical-description
- https://github.com/openspug/spug/commit/97aebf133e1f9cbb35ccebadab1faedfdfe93f42 patch
- VulnCheck Advisory: Spug through 3.4.0 Remote Code Execution via ping_check third-party-advisory