CVE-2024-48050
📋 TL;DR
This vulnerability allows unauthenticated remote code execution in agentscope workflow utilities. Attackers can execute arbitrary commands through the eval() function in is_callable_expression. All users of agentscope v0.0.4 and earlier are affected.
💻 Affected Systems
- agentscope
📦 What is this software?
Agentscope by Modelscope
⚠️ Risk & Real-World Impact
Worst Case
Complete system compromise with attacker gaining full control over the server, data exfiltration, and lateral movement within the network.
Likely Case
Remote code execution leading to data theft, service disruption, or deployment of malware/ransomware.
If Mitigated
Limited impact if proper network segmentation and least privilege access controls are implemented.
🎯 Exploit Status
Public proof-of-concept exists showing direct command injection via the vulnerable eval() call. Simple exploitation requires minimal technical skill.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: v0.0.5 or later
Vendor Advisory: https://github.com/modelscope/agentscope
Restart Required: Yes
Instructions:
1. Check current version: pip show agentscope
2. Upgrade: pip install --upgrade agentscope
3. Restart all agentscope services
4. Verify version is > v0.0.4
🔧 Temporary Workarounds
Disable vulnerable endpoints
allTemporarily disable or block access to workflow-related endpoints
# Configure firewall to block workflow endpoints
# Disable web interface if not required
Input validation wrapper
allAdd input sanitization before eval() call
# Modify is_callable_expression to validate input
# Replace eval() with safer alternatives like ast.literal_eval()
🧯 If You Can't Patch
- Network segmentation: Isolate agentscope instances from critical systems
- Implement strict input validation and WAF rules to block malicious payloads
🔍 How to Verify
Check if Vulnerable:
Check agentscope version and inspect agentscope/web/workstation/workflow_utils.py for eval() usage in is_callable_expression function
Check Version:
pip show agentscope | grep Version
Verify Fix Applied:
Verify agentscope version > v0.0.4 and confirm eval() has been removed or secured in workflow_utils.py
📡 Detection & Monitoring
Log Indicators:
- Unusual process execution from agentscope
- Suspicious Python eval() calls
- Error logs containing malicious payloads
Network Indicators:
- Unexpected outbound connections from agentscope servers
- Traffic to workflow endpoints with command-like strings
SIEM Query:
source="agentscope" AND (eval OR exec OR system OR subprocess)