Files
boc/BOC_STATUS.md
T
Bernt 78b57273e2 security: Add proper authentication, RBAC, and tenant isolation
- Add password hashing with bcrypt
- Add AuthService with proper login
- Add password strength validation
- Add RBAC middleware (AdminOnly, ManagerOrAdmin)
- Add tenant isolation middleware
- Update CRM handler with tenant filtering
- Add JWT fallback for development mode
- Add user context helpers
- Build successful
2026-08-10 12:52:48 +00:00

3.8 KiB

BOC — Business Operations Center

Status: PRODUKTIONSKLAR Uppdaterad: 2026-08-04 21:43 UTC


🏗️ Arkitektur

┌─────────────────────────────────────────┐
│           BOC Stack                     │
├─────────────────────────────────────────┤
│  boc-api        :9096  (Go)            │
│  boc-rust       :9093  (Rust)          │
│  boc-postgres   :5435  (PostgreSQL)     │
│  boc-redis      :6381  (Redis)          │
│  boc-c-runtime  (C)                    │
└─────────────────────────────────────────┘

Status

Komponent Status Port Docker
boc-api Running 9096
boc-rust Running 9093
boc-postgres Running 5435
boc-redis Running 6381
boc-c-runtime Running

🔐 Auth Integration

  • RS256 — AAMOS publik nyckel (jwt-public.pem)
  • ouroboros-identity — Port 3208 (RS256 token issuance)
  • aamos-ledger — Port 3250 (token validering)
  • aamos-admin-v2 — Port 443 (login + Google OAuth)

📊 Tester

Modul Coverage Tester
Auth (RS256 + HS256) 82.6% 27/27 PASS
Config 100% 3/3 PASS
Store 76.7% 6/6 PASS
Middleware 59.5% 5/5 PASS
Ledger 58.1% 2/2 PASS
PDF 34.5% 4/4 PASS
Automation 33.0% 8/8 PASS
CRM Handlers 2.2% 6/6 PASS

Totalt: 61/61 tester PASS


🔄 Backup

  • Databas: Dagligen 02:00 UTC
  • Plats: /home/bernt/backups/boc/
  • Retention: 14 dagar
  • Scheduler: AAMOS Scheduler (boc-backup jobb)

📡 Monitoring

  • Health checks: Var 5:e minut
  • Loggar: /opt/amos/scheduler/logs/boc-health-check.log
  • Scheduler: AAMOS Scheduler (boc-health-check jobb)

🚀 Drift

Starta

cd /home/bernt/.openclaw/workspace/boc
docker-compose up -d

Stoppa

cd /home/bernt/.openclaw/workspace/boc
docker-compose down

Loggar

docker logs -f boc-api
docker logs -f boc-rust

📁 Viktiga filer

Fil Beskrivning
docker-compose.yml Docker konfiguration
.env Miljövariabler
main.go BOC API entrypoint
BOC_V2_ARCHITECTURE.md Arkitekturdokumentation
BOC_FUNCTIONAL_AUDIT_2026-07-29.md Funktionell audit

🎯 Nästa steg (valfritt)

  • Frontend SPA med login-formulär
  • Cookie-baserad SSO
  • Google OAuth i BOC
  • Lösenordsåterställning
  • MFA (TOTP/SMS)

BOC är produktionsklart och monitorerat via AAMOS Scheduler.


🔐 Auth Status (Uppdaterad 2026-08-04)

Test Status Kommentar
Utan token 401 Korrekt avvisad
Med RS256 token 200 User data returnerad
Med HS256 token 401 Endast RS256 accepteras

🌐 Alla Endpoints (Testade)

Endpoint Status Data
/api/v1/auth/me User data
/api/v1/hr/employees 1763 bytes
/api/v1/crm/customers 1307 bytes
/api/v1/sales/deals 2203 bytes
/api/v1/legal/contracts 26 bytes
/api/v1/marketing/campaigns 26 bytes
/api/v1/support/tickets 24 bytes
/api/v1/analytics/dashboard 969 bytes
/api/v1/finance/balance 708 bytes
/api/v1/briefing/daily 1105 bytes

📚 Swagger