Skip to content
BENIBIX Learn

Permission Path Pattern

AI⌨️ Claude CodeConfiguration

Also known as Read(//abs/path), Edit(/src/**)

The path in a Read or Edit rule. How it starts sets where it points.

Think of it like

It is like an address. Street, town or country changes where it points.

Example

Jack wrote one slash in his user settings. It pointed inside his .claude folder. He adds a second slash.

Why it matters

A rule that points at the wrong folder protects nothing, and nothing tells you so.

Definition

A permission path pattern is the path inside a Read or Edit rule. It follows gitignore rules, and how it starts decides where it points. Two slashes start at the root of the disk. ~/ starts at your home folder. One slash starts where the settings file lives. No slash starts in the current folder.

Example code

json
{
  "permissions": {
    "deny": ["Read(//etc/**)", "Read(~/.ssh/**)", "Edit(/dist/**)", "Read(*.pem)"]
  }
}
One rule for each of the four starts.
The four starts, and where each points.

Common mistake

Writing /Users/alice/file as a full path. One slash starts at the settings file. Use two.

Key takeaways

  1. 1
    // is the disk root. Full path.
  2. 2
    ~/ is home. Your folder.
  3. 3
    / is the settings file. Not the root.