Skip to main content
Follow these best practices to ensure secure deployment and operation of ChameleonDB.

File Permissions

Set Permissions After Init

Critical: The auth/mode.key file contains your hashed mode password. It must only be readable by the owner.

Verify Permissions

Password Management

Set Strong Passwords

Password requirements:
  • Minimum 16 characters
  • Mix of uppercase and lowercase
  • Include numbers and symbols
  • Not used for other systems
  • Stored in password manager

Environment Variables for CI/CD

Don’t hardcode passwords:
Use environment variables:

Password Rotation

Rotate passwords regularly:
Rotate immediately after personnel changes (departures, role changes).

Mode Strategy

Environment-Based Modes

Production Mode Workflow

Never leave production in standard/privileged mode. Downgrade immediately after maintenance.

Secrets Management

Never Commit Secrets

.gitignore (required):

Configuration Files

Don’t put secrets in .chameleon.yml:
Use environment variables:

Environment Variables

.env (gitignored):
Load in application:

Git Strategy

What to Commit

DO commit:
DON’T commit:

Pre-commit Hook

Prevent accidental secret commits: .git/hooks/pre-commit:

Monitoring & Alerts

Monitor integrity.log

Set up log monitoring:
Alert on suspicious events:
Run periodically:

Key Events to Monitor

Alert immediately on:
  • Integrity violations
  • Emergency mode activation
  • Failed password attempts
  • Unexpected mode changes
  • Unusual migration activity
Review regularly:
  • Mode change history
  • Migration patterns
  • User activity in logs

Backup Strategy

What to Backup

Critical:
Optional:

Automated Backups

Daily vault backup:
Cron daily at 2 AM:

Verify Backups

Compliance & Audit

Audit Trail Requirements

ChameleonDB provides:
Who - User information in logs
What - Detailed operation records
When - Timestamp for all events
Why - Context in commit messages
How - Complete operation details

Regular Audit Review

Weekly:
Monthly:
Quarterly:
  • Review access controls
  • Rotate passwords
  • Update security procedures
  • Test incident response

Compliance Checklist

Incident Response

Integrity Violation

Response steps:

Unauthorized Mode Change

Password Compromise

Security Hardening

Operating System Level

Linux with SELinux:
AppArmor profile:

Network Security

Database connection:
Firewall rules:

Summary

File Permissions

  • 700 for .chameleon/
  • 600 for auth files

Password Management

  • 16+ character passwords
  • Rotate quarterly
  • Use environment variables

Mode Strategy

  • readonly for production
  • Time-limited upgrades
  • Immediate downgrades

Monitoring

  • Watch integrity.log
  • Alert on violations
  • Regular audits

Next Steps

Security Overview

Review the complete security model