exec() call detected
High
- Category
- Dangerous Code Execution
- Content
def task(): try: with contextlib.redirect_stdout(output_buffer): exec(code, globals()) FreeCAD.Console.PrintMessage("Python code executed successfully.\n") return True except Exception as e:- Confidence
- 99% confidence
- Finding
- The RPC method `execute_code` accepts arbitrary caller-supplied Python and runs it with `exec(code, globals())` inside the FreeCAD process. This is direct remote code execution: an attacker who can reach the XML-RPC server can execute OS commands, read or modify files, exfiltrate project data, or alter the FreeCAD environment with the privileges of the user running FreeCAD.
