( toolName: string, _ruleContent: string | undefined, )
| 238 | * can evaluate the sub-agent's prompt, defeating delegation attack prevention. |
| 239 | */ |
| 240 | export function isDangerousTaskPermission( |
| 241 | toolName: string, |
| 242 | _ruleContent: string | undefined, |
| 243 | ): boolean { |
| 244 | return normalizeLegacyToolName(toolName) === AGENT_TOOL_NAME |
| 245 | } |
| 246 | |
| 247 | function formatPermissionSource(source: PermissionRuleSource): string { |
| 248 | if ((SETTING_SOURCES as readonly string[]).includes(source)) { |
no test coverage detected