Skip to main content

Overview

Mission Control supports three authentication methods:
  1. Session Cookie - For browser-based access after login
  2. API Key - For headless automation and CLI tools
  3. Google OAuth - For team SSO with admin approval workflow
All authenticated users are assigned one of three roles: viewer, operator, or admin.

Authentication Methods

Role-Based Access Control (RBAC)

Mission Control enforces three permission levels:

Role Hierarchy

Roles are hierarchical: viewer < operator < admin
Endpoints specify minimum required role. For example, POST /api/agents requires operator or higher.

Security Considerations

Follow these security best practices before deploying to production:

Password Requirements

  • Minimum 12 characters
  • Hashed with scrypt (CPU-intensive key derivation)
  • Constant-time comparison to prevent timing attacks

Session Security

  • Duration: 7 days (604800 seconds)
  • Storage: SQLite user_sessions table
  • Token: 32-byte random hex (64 characters)
  • Cleanup: Expired sessions purged on each login

API Key Security

  • Constant-time comparison prevents timing attacks
  • Never log API keys in application logs
  • Rotate keys regularly
  • Use different keys for dev/staging/production

CSRF Protection

Mutating requests validate the Origin header:
API key authentication bypasses CSRF checks since keys are header-based.

User Management

Get Current User

Response:

List Users (Admin)

Response:

Create User (Admin)

Response: 201 Created

Update User (Admin)

Delete User (Admin)

Deleting a user destroys all their sessions immediately.

Error Responses

401 Unauthorized

Authentication required but not provided:
Causes:
  • No session cookie or API key provided
  • Session expired (7 days)
  • Invalid API key

403 Forbidden

Authenticated but insufficient permissions:
Causes:
  • Viewer trying to create resources
  • Operator trying to manage users
  • OAuth user not yet approved

409 Conflict

Resource already exists:

Initial Setup

On first run, Mission Control seeds an admin user from environment variables:
If AUTH_PASS contains # or other shell metacharacters, use quotes or switch to AUTH_PASS_B64.

Generating a Secure Password

Best Practices

1

Use Strong Credentials

  • Passwords: Minimum 12 characters, mix of letters/numbers/symbols
  • API keys: At least 32 random characters
  • Rotate API keys quarterly
2

Deploy Behind Reverse Proxy

Use Caddy, nginx, or Traefik with automatic TLS:
3

Configure Host Allowlist

Restrict network access in production:
4

Enable Audit Logging

Track administrative actions:

Next Steps

Agents API

Manage agent lifecycle and status

Tasks API

Create and assign tasks to agents

Webhooks

Configure outbound event notifications

Token Tracking

Monitor LLM token usage and costs