CVE-2024-27763
Python vulnerability analysis and mitigation

Overview

XPixelGroup BasicSR through version 1.4.2 contains a local code execution vulnerability in the initdistslurm function. The vulnerability exists when the 'scontrol show hostname' command is executed in the presence of a crafted SLURM_NODELIST environment variable (NVD).

Technical details

The vulnerability is present in the basicsr/utils/distutil.py file where the application executes the 'scontrol show hostname' command using an unvalidated SLURMNODELIST environment variable. The code retrieves the hostname from the SLURM controller without proper input validation, potentially allowing for command injection. The current CVSS v3.1 score is 5.3 (Medium) with vector string CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L (GitHub Gist, NVD).

Impact

If successfully exploited, this vulnerability could allow local attackers to execute arbitrary code within the context of the application. This could potentially lead to unauthorized access, privilege escalation, or denial of service (GitHub Gist).

Mitigation and workarounds

To mitigate this vulnerability, it is recommended to implement strict input validation and sanitization of environment variables, especially those derived from external commands. Additionally, avoid using unvalidated inputs directly in command execution functions like subprocess.getoutput. Users should upgrade to the latest version of BasicSR where this vulnerability has been patched (GitHub Gist).

Additional resources


SourceThis report was generated using AI

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

“Best User Experience I have ever seen, provides full visibility to cloud workloads.”
David EstlickCISO
“Wiz provides a single pane of glass to see what is going on in our cloud environments.”
Adam FletcherChief Security Officer
“We know that if Wiz identifies something as critical, it actually is.”
Greg PoniatowskiHead of Threat and Vulnerability Management