Running all agents under same container (#12)
This commit is contained in:
@@ -30,12 +30,12 @@ class StrixAgent(BaseAgent):
|
||||
cloned_path = target.get("cloned_repo_path")
|
||||
|
||||
if cloned_path:
|
||||
shared_workspace_path = "/shared_workspace"
|
||||
workspace_path = "/workspace"
|
||||
task_parts.append(
|
||||
f"Perform a security assessment of the Git repository: {repo_url}. "
|
||||
f"The repository has been cloned from '{repo_url}' to '{cloned_path}' "
|
||||
f"(host path) and then copied to '{shared_workspace_path}' in your environment."
|
||||
f"Analyze the codebase at: {shared_workspace_path}"
|
||||
f"(host path) and then copied to '{workspace_path}' in your environment."
|
||||
f"Analyze the codebase at: {workspace_path}"
|
||||
)
|
||||
else:
|
||||
task_parts.append(
|
||||
@@ -49,12 +49,12 @@ class StrixAgent(BaseAgent):
|
||||
|
||||
elif scan_type == "local_code":
|
||||
original_path = target.get("target_path", "unknown")
|
||||
shared_workspace_path = "/shared_workspace"
|
||||
workspace_path = "/workspace"
|
||||
task_parts.append(
|
||||
f"Perform a security assessment of the local codebase. "
|
||||
f"The code from '{original_path}' (user host path) has been copied to "
|
||||
f"'{shared_workspace_path}' in your environment. "
|
||||
f"Analyze the codebase at: {shared_workspace_path}"
|
||||
f"'{workspace_path}' in your environment. "
|
||||
f"Analyze the codebase at: {workspace_path}"
|
||||
)
|
||||
|
||||
else:
|
||||
|
||||
@@ -145,11 +145,10 @@ Remember: A single high-impact vulnerability is worth more than dozens of low-se
|
||||
|
||||
<multi_agent_system>
|
||||
AGENT ISOLATION & SANDBOXING:
|
||||
- Each subagent runs in a completely isolated sandbox environment
|
||||
- Each agent has its own: browser sessions, terminal sessions, proxy (history and scope rules), /workspace directory, environment variables, running processes
|
||||
- Agents cannot share network ports or interfere with each other's processes
|
||||
- Only shared resource is /shared_workspace for collaboration and file exchange
|
||||
- Use /shared_workspace to pass files, reports, and coordination data between agents
|
||||
- All agents run in the same shared Docker container for efficiency
|
||||
- Each agent has its own: browser sessions, terminal sessions
|
||||
- All agents share the same /workspace directory and proxy history
|
||||
- Agents can see each other's files and proxy traffic for better collaboration
|
||||
|
||||
SIMPLE WORKFLOW RULES:
|
||||
|
||||
@@ -312,8 +311,7 @@ PROGRAMMING:
|
||||
- You can install any additional tools/packages needed based on the task/context using package managers (apt, pip, npm, go install, etc.)
|
||||
|
||||
Directories:
|
||||
- /workspace - Your private agent directory
|
||||
- /shared_workspace - Shared between agents
|
||||
- /workspace - where you should work.
|
||||
- /home/pentester/tools - Additional tool scripts
|
||||
- /home/pentester/tools/wordlists - Currently empty, but you should download wordlists here when you need.
|
||||
|
||||
|
||||
@@ -239,6 +239,9 @@ class BaseAgent(metaclass=AgentMeta):
|
||||
self.state.sandbox_token = sandbox_info["auth_token"]
|
||||
self.state.sandbox_info = sandbox_info
|
||||
|
||||
if "agent_id" in sandbox_info:
|
||||
self.state.sandbox_info["agent_id"] = sandbox_info["agent_id"]
|
||||
|
||||
if not self.state.task:
|
||||
self.state.task = task
|
||||
|
||||
|
||||
Reference in New Issue
Block a user