diff options
Diffstat (limited to 'packages/core/src/tools/shell.test.ts')
| -rw-r--r-- | packages/core/src/tools/shell.test.ts | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/packages/core/src/tools/shell.test.ts b/packages/core/src/tools/shell.test.ts index f33d3f03..acc8c01f 100644 --- a/packages/core/src/tools/shell.test.ts +++ b/packages/core/src/tools/shell.test.ts @@ -350,17 +350,14 @@ describe('ShellTool', () => { expect(result.allowed).toBe(true); }); - it('should block a command with command substitution using backticks', async () => { + it('should allow a command with command substitution using backticks', async () => { const config = { getCoreTools: () => ['run_shell_command(echo)'], getExcludeTools: () => [], } as unknown as Config; const shellTool = new ShellTool(config); const result = shellTool.isCommandAllowed('echo `rm -rf /`'); - expect(result.allowed).toBe(false); - expect(result.reason).toBe( - 'Command substitution using backticks is not allowed for security reasons', - ); + expect(result.allowed).toBe(true); }); it('should block a command with command substitution using $()', async () => { |
