nextlevelbuilder / nextlevelbuilder/goclaw
[Question] Subagent Spawn Permission Control
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 3.6k
- Forks
- 1.1k
- Avg merge
- 3d 5h
- Merged PRs (30d)
- 24
Description
Problem
There's no way to restrict which subagents an agent can spawn. This creates security issues in multi-tenant environments.
Current SubagentsConfig only has:
{
maxConcurrent?: number;
maxSpawnDepth?: number;
maxChildrenPerAgent?: number;
// No allowedAgents or deniedAgents fields
}
Use case:
sales-agentshould only spawninventory-specialistandreporting-specialistsales-agentshould NOT spawnhr-agentorfinance-agent(sensitive data)
Current workarounds don't work:
- ❌ AGENTS.md instructions = soft enforcement, LLM can be jailbroken
- ❌ Tool Policy deny spawn = too restrictive, blocks ALL spawning
- ❓ Agent Links = exists in code but no UI/docs
Proposed Solution
Add whitelist/blacklist to SubagentsConfig:
export interface SubagentsConfig {
// ... existing fields
allowedAgents?: string[]; // Whitelist
deniedAgents?: string[]; // Blacklist
}
With backend validation before spawn.
Questions
- Is
AgentLinkDatameant for this? If yes, where's the UI and how do we use it? - Would you accept a PR to add
allowedAgents/deniedAgents? - What's the recommended pattern for spawn access control?
Context
Critical for production deployments with sensitive data. Soft enforcement via prompts is insufficient for security.
Source: ui/web/src/types/agent.ts
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with ui/web/src/types/agent.ts and inspect the existing AgentLinkData references, then trace the backend spawn-validation path. Clarify how Agent Links, allowlists, and denylists should interact before changing the configuration. Done means the accepted access-control behavior is documented and enforced before a subagent is spawned, with coverage for permitted and denied agents.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, typescript
- Domain
- authorization, backend-api-design, security
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100