Skip to content

Beta 0.43.1b4 #3147

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
May 14, 2025
Merged

Beta 0.43.1b4 #3147

merged 4 commits into from
May 14, 2025

Conversation

MichaIng
Copy link
Member

No description provided.

MichaIng added 4 commits May 14, 2025 15:55
When using the camera_add/add motioneye web API, the camera device path for obtaining supported resolutions is passed via post request body. Adding single quotes to this input lifts the single-quotation in the final command string, allowing command substitution and hence remote command injection/execution. In this case, the final command is executed in shell context to allow piping and parsing the output with grep.

Use shlex.quote to safely single-quote the input, and have embedded single-quotes escaped, to prevent any possible shell expansion, including variables and command substitutions.

Thanks to @hyperlyz for reporting this security vulnerability: #3142

Signed-off-by: MichaIng <micha@dietpi.com>
Ubuntu Jammy and Noble are currently tested, Focal runners are not available anymore, Debian never was. I test Debian installs of motionEye in another project, but lets remove this info which just requires regular updates.

Signed-off-by: MichaIng <micha@dietpi.com>
Signed-off-by: MichaIng <micha@dietpi.com>
Signed-off-by: MichaIng <micha@dietpi.com>
@MichaIng MichaIng added the meta label May 14, 2025
@MichaIng MichaIng merged commit 6bcfa2e into main May 14, 2025
32 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

1 participant