Claude Security Settings

🌐Community
by laurigates · vlatest · Repository

Configure Claude's safety settings (e.g., refusal rates, content filters) to align with your organization’s risk tolerance.

Install on your platform

We auto-selected Claude Code based on this skill’s supported platforms.

1

Run in terminal (recommended)

terminal
claude mcp add claude-security-settings npx -- -y @trustedskills/claude-security-settings
2

Or manually add to ~/.claude/settings.json

~/.claude/settings.json
{
  "mcpServers": {
    "claude-security-settings": {
      "command": "npx",
      "args": [
        "-y",
        "@trustedskills/claude-security-settings"
      ]
    }
  }
}

Requires Claude Code (claude CLI). Run claude --version to verify your install.

About This Skill

What it does

This skill allows you to configure Claude Code's security settings, including granular permissions for shell commands and protections against potentially dangerous shell operators. It enables organizations to align Claude Code’s access with their specific risk tolerance by controlling which commands can be executed and preventing the use of risky shell constructs. The configuration is managed through JSON files at different scopes (user, project, local project) with varying priority levels.

When to use it

  • You need to restrict what shell commands Claude Code can execute within a project.
  • Your organization requires specific controls over command execution for security compliance.
  • You want to prevent the use of potentially dangerous shell operators (like &&, ||, or redirection) during code execution.
  • You are managing multiple projects with different security requirements.

Key capabilities

  • Permission Wildcards: Define granular access control using wildcard patterns for Bash commands (e.g., Bash(git status *)).
  • Shell Operator Protections: Prevents the use of dangerous shell operators like &&, ||, ;, and redirection (>, >>) to mitigate command injection risks.
  • Permission Tiers: Control command execution with "allow," "ask" (prompt for confirmation), or "deny" permissions.
  • Scoped Configuration: Manage settings at the user, project (committed), and local project (gitignored) levels, with priority-based overrides.

Example prompts

  • “Set up Claude Code to allow git status but deny rm -rf *.”
  • "Configure permissions so that running npm run build requires confirmation."
  • "What is the highest priority settings file for controlling Bash commands?"

Tips & gotchas

  • Settings are applied based on a priority system: Local project > Project level > User level.
  • Be mindful of wildcard patterns; overly broad patterns can unintentionally grant excessive permissions.
  • Claude Code 2.1.7 and later versions include built-in protections against dangerous shell operators, which will trigger explicit approval prompts if encountered.

Tags

🛡️

TrustedSkills Verification

Unlike other registries that point to live repositories, TrustedSkills pins every skill to a verified commit hash. This protects you from malicious updates — what you install today is exactly what was reviewed and verified.

Security Audits

Gen Agent Trust HubPass
SocketPass
SnykPass

Details

Version
vlatest
License
Author
laurigates
Installs
37

🌐 Community

Passed automated security scans.