Skip to main content

Cyberstrike is now open source! AI-powered penetration testing for security professionals. Star on GitHub

Config Commands

The cyberstrike config commands manage configuration settings at global and project levels.

📸 SCREENSHOT: config-commands.png

Config command interface

Get Configuration

Get Single Value

Terminal window
cyberstrike config get model

Output:

anthropic/claude-sonnet-4-20250514

Get Nested Value

Terminal window
cyberstrike config get provider.anthropic.options.apiKey

Get All Settings

Terminal window
cyberstrike config get

JSON Output

Terminal window
cyberstrike config get --json

Set Configuration

Set Single Value

Terminal window
cyberstrike config set model anthropic/claude-opus-4-5-20251101

Set Nested Value

Terminal window
cyberstrike config set provider.anthropic.options.thinking.enabled true

Set Array Value

Terminal window
cyberstrike config set permissions.allow '["Bash(nmap *)", "Bash(nuclei *)"]'

Global vs Project

Terminal window
# Global (default)
cyberstrike config set model anthropic/claude-sonnet-4-20250514 --global
# Project only
cyberstrike config set model anthropic/claude-opus-4-5-20251101 --project

Unset Configuration

Remove Value

Terminal window
cyberstrike config unset model

Remove Nested Value

Terminal window
cyberstrike config unset provider.openai

List Configuration

Show All

Terminal window
cyberstrike config list

Output:

Configuration
━━━━━━━━━━━━━
Global (~/.cyberstrike/config.json):
model: anthropic/claude-sonnet-4-20250514
theme: cyberpunk
Project (./cyberstrike.json):
model: anthropic/claude-opus-4-5-20251101
agent: web-application
Effective:
model: anthropic/claude-opus-4-5-20251101 (project)
theme: cyberpunk (global)
agent: web-application (project)

Show Source

Terminal window
cyberstrike config list --show-source

Shows where each value comes from.

Edit Configuration

Open in Editor

Terminal window
cyberstrike config edit

Opens global config in default editor.

Edit Project Config

Terminal window
cyberstrike config edit --project

Specify Editor

Terminal window
EDITOR=vim cyberstrike config edit

Initialize Configuration

Create Global Config

Terminal window
cyberstrike config init --global

Create Project Config

Terminal window
cyberstrike config init

Creates cyberstrike.json in current directory.

With Template

Terminal window
cyberstrike config init --template security

Available templates:

  • default - Basic configuration
  • security - Security testing focused
  • minimal - Minimal configuration

Validate Configuration

Validate Current Config

Terminal window
cyberstrike config validate

Output:

Configuration Validation
━━━━━━━━━━━━━━━━━━━━━━━━
Global config: ✓ Valid
Project config: ✓ Valid
Warnings:
- API key should use environment variable reference

Validate Specific File

Terminal window
cyberstrike config validate path/to/config.json

Reset Configuration

Reset to Defaults

Terminal window
cyberstrike config reset

Reset Specific Setting

Terminal window
cyberstrike config reset model

Force Reset

Terminal window
cyberstrike config reset --force

Import/Export

Export Configuration

Terminal window
cyberstrike config export > my-config.json

Export Without Secrets

Terminal window
cyberstrike config export --no-secrets > shareable-config.json

Import Configuration

Terminal window
cyberstrike config import my-config.json

Merge Import

Terminal window
cyberstrike config import my-config.json --merge

Environment Variables

List Environment Variables

Terminal window
cyberstrike config env

Output:

Environment Variables
━━━━━━━━━━━━━━━━━━━━━
Variable Status Used By
──────────────────────────────────────────
ANTHROPIC_API_KEY ✓ Set provider.anthropic
OPENAI_API_KEY ✗ Not set provider.openai
GOOGLE_API_KEY ✗ Not set provider.google
CYBERSTRIKE_MODEL ✗ Not set model

Show Env Overrides

Terminal window
cyberstrike config env --overrides

Path Information

Show Config Paths

Terminal window
cyberstrike config paths

Output:

Configuration Paths
━━━━━━━━━━━━━━━━━━━
Global Config: ~/.cyberstrike/config.json
Project Config: ./cyberstrike.json (not found)
Auth File: ~/.cyberstrike/auth.json
Data Directory: ~/.cyberstrike/
Cache: ~/.cyberstrike/cache/
Logs: ~/.cyberstrike/logs/

Common Settings

Model

Terminal window
cyberstrike config set model anthropic/claude-sonnet-4-20250514

Theme

Terminal window
cyberstrike config set theme cyberpunk

Permission Mode

Terminal window
cyberstrike config set permissions.mode default

Auto-compact

Terminal window
cyberstrike config set autoCompact true

Keybindings

Terminal window
cyberstrike config set keybinds.leader "ctrl+a"

Examples

Set Up for Security Testing

Terminal window
# Set model
cyberstrike config set model anthropic/claude-opus-4-5-20251101
# Set default agent
cyberstrike config set agent web-application
# Allow common security tools
cyberstrike config set permissions.allow '["Bash(nmap *)", "Bash(nuclei *)", "Bash(ffuf *)"]'
# Set output directory
cyberstrike config set outputDir "./security-reports"

Team Configuration

Terminal window
# Export team config
cyberstrike config export --no-secrets > team-config.json
# Team member imports
cyberstrike config import team-config.json --merge

Debug Configuration Issues

Terminal window
# Validate
cyberstrike config validate
# Show effective config
cyberstrike config list --show-source
# Check env vars
cyberstrike config env

Troubleshooting

Invalid JSON

Error: Invalid JSON in config file

Solution:

Terminal window
cyberstrike config validate
# Shows specific error location

Permission Denied

Error: Cannot write to config file

Check permissions:

Terminal window
ls -la ~/.cyberstrike/config.json
chmod 644 ~/.cyberstrike/config.json

Config Not Loading

Warning: Project config not found

Initialize:

Terminal window
cyberstrike config init

Tip

Use cyberstrike config list to see which values come from global vs project configuration.