Type: Incorrect Access Control
Product: SuperAGI
Affected versions: v0.0.14
Affected component: superagi/controllers/agent_template.py:save_agent_as_template superagi/controllers/agent_template.py:publish_template
Suggested CWE: CWE-284 (Incorrect Access Control)
Reference: http://superagi.com
Reference: http://transformeroptimus.com
TransformerOptimus SuperAGI v0.0.14 is vulnerable to Incorrect Access Control in the agent template controller. In affected source snapshots, save_agent_as_template and publish_template in superagi/controllers/agent_template.py accept caller-supplied agent_id or agent_execution_id values and do not verify that the referenced agent or execution belongs to the authenticated user's organization.
Condensed from the authorized local validation used for the original report; local filesystem paths are replaced with <local-path>.
Environment:
- Deploy an affected SuperAGI version from source.
- Use a browser and Burp Suite, or a browser with Developer Tools Network tab.
- Create two separate organizations or tenants:
- Organization A: victim organization.
- Organization B: attacker-controlled organization.
- Create one normal user account in each organization. Part A - Unauthorized save-agent-as-template from another organization's agent: 1. Log in as the Organization A user in Browser Session A.
- Create a normal agent in Organization A and run it at least once so it has an agent execution and configuration …
Ro1ME