Configuration
Learn how to configure Vypher to suit your specific needs and scanning requirements.
Quick Configuration
Create a basic configuration file to get started:
vypher initThis creates a vypher.yaml configuration file in your current directory with sensible defaults.
Configuration File
Vypher uses YAML configuration files. Here’s a basic example:
# vypher.yaml
version: "1.0"
# Scan targets
scan:
paths:
- "src/"
- "docs/"
exclude:
- "node_modules/"
- "*.log"
# Detectors to use
detectors:
- pii
- secrets
- custom
# Output configuration
output:
format: "json"
file: "vypher-results.json"
# Custom rules
rules:
- name: "custom-api-key"
pattern: "api[_-]?key[\"']?\\s*[:=]\\s*[\"']?([a-zA-Z0-9]{32})"
severity: "high"Configuration Options
Scan Configuration
| Option | Description | Default |
|---|---|---|
paths | Directories to scan | ["."] |
exclude | Patterns to exclude | [] |
include | File patterns to include | ["*"] |
max_file_size | Maximum file size to scan | 10MB |
Detector Configuration
| Option | Description | Default |
|---|---|---|
detectors | List of detectors to use | ["pii", "secrets"] |
sensitivity | Detection sensitivity level | medium |
custom_rules | Path to custom rules file | null |
Output Configuration
| Option | Description | Default |
|---|---|---|
format | Output format (json, csv, xml) | json |
file | Output file path | stdout |
template | Custom output template | null |
Advanced Configuration
Environment Variables
You can override configuration options using environment variables:
export VYPHER_OUTPUT_FORMAT=csv
export VYPHER_SCAN_PATHS="src/,tests/"
vypher scanMultiple Configuration Files
Use different configurations for different environments:
# Development scanning
vypher scan --config vypher.dev.yaml
# Production scanning
vypher scan --config vypher.prod.yamlNext Steps
- Quick Start - Run your first scan
- Basic Usage - Learn scanning commands
- Custom Detectors - Create custom detection rules
Last updated on