类 ToolDangerousPathConstants

java.lang.Object
io.agentscope.core.tool.ToolDangerousPathConstants

public final class ToolDangerousPathConstants extends Object
Defaults for the dangerous-path and dangerous-command lists consulted by tool self-checks.

These lists guard sensitive configuration files (shell rc files, SSH config, credentials) and disruptive shell commands. Tools that override the fields on ToolBase replace the defaults entirely rather than appending to them.

  • 字段详细资料

    • DEFAULT_DANGEROUS_FILES

      public static final List<String> DEFAULT_DANGEROUS_FILES
      Sensitive files that should never be auto-edited.

      Includes shell rc files, SSH config, credential stores, and .env variants that commonly hold secrets. Aligned with Python tool/_constants.py.

    • DEFAULT_DANGEROUS_DIRECTORIES

      public static final List<String> DEFAULT_DANGEROUS_DIRECTORIES
      Directory names whose presence anywhere in a path marks it sensitive.
    • DANGEROUS_COMMANDS

      public static final List<String> DANGEROUS_COMMANDS
      Shell command fragments that always require explicit user approval.