- Docker socket (
/var/run/docker.sock) β root-equivalent access on the host - Container secrets / environment variables
- Orbit user credentials
- Audit logs
- Unauthenticated external users
- Authenticated low-privilege users trying to escalate
- Compromised container attempting socket escape
| Control | Implementation | Status |
|---|---|---|
| Socket isolation | Socket only accessible to backend container | β |
| JWT authentication | HS256, 1h expiry, refresh tokens | β |
| RBAC | Admin / Operator / ReadOnly middleware | β skeleton |
| Rate limiting | 100 req/min per IP | β |
| Audit logging | Structured JSON to stdout | β |
| CORS | Explicit origin whitelist | β |
| Input validation | Zod schemas on all endpoints | β |
- Rotate JWT secret β expose
/api/auth/rotate-secret(admin only) - HTTPS enforcement β add Caddy or Traefik reverse proxy config
- Secret scanning β add
trufflehogto CI pipeline - Container image pinning β use SHA digests in
docker-compose.yml - Read-only rootfs β add
read_only: trueto backend compose service
- LDAP/OIDC integration β integrate
passport-ldapauth/openid-client - HMAC webhooks β sign outgoing webhook payloads with
X-Orbit-Signature - CSP headers β strict Content-Security-Policy via helmet.js
- Dependency audit β weekly
npm auditin CI - Session revocation β Redis-backed token blocklist for logout
- Prometheus auth β protect
/metricsbehind bearer token - 2FA / TOTP β optional TOTP for admin accounts
- Immutable audit log β forward to external syslog / SIEM
The Docker socket grants root-equivalent access. Mitigations:
- Network isolation β backend is on an internal Docker network; socket never exposed to frontend or internet
- Docker socket proxy (recommended for production) β replace direct socket mount with docker-socket-proxy to allow only specific API calls
- User namespacing β enable Docker user namespace remapping on the host
Example socket proxy integration (Phase 1):
socket-proxy:
image: tecnativa/docker-socket-proxy
volumes:
- /var/run/docker.sock:/var/run/docker.sock
environment:
CONTAINERS: 1
IMAGES: 1
NETWORKS: 1
VOLUMES: 1
POST: 1 # set to 0 for read-only mode
networks:
- internalBefore going to production:
# β
Check these are set and non-default
ORBIT_SECRET # Must be >= 32 chars, random
ORBIT_ADMIN_PASSWORD # Must be changed from default