Saltar al contenido principal
Version: Next 🚧

Cert-IX MVP1 — Compliance Baseline Matrix (38 Services)

Date: 2026-02-22
Scope: Minimum launchable compliance baseline on critical flows
Estimated remediation: 2–4 days (validated below)


Table of Contents

  1. Service Compliance Matrix (38 services)
  2. Critical Flows & Dependencies
  3. P0/P1/P2 Gap Summary
  4. Remediation Plan per Flow
  5. E2E Testing Strategy by Flow
  6. Kafka Event Contract Freeze
  7. Go/No-Go Criteria
  8. Timeline

1. Service Compliance Matrix

Legend

SymbolMeaning
Implemented and verified
⚠️Partially implemented / needs hardening
Missing / not implemented
N/ANot applicable for this service type

Compliance Dimensions

#DimensionCode
AAuthN/AuthZ & Access ControlAUTHN
BAudit Logging (who/what/when + traceId)AUDIT
CSecrets Management (no hardcoded secrets)SECRETS
DEncryption in Transit (TLS) + at RestENCRYPT
EInput Validation/Sanitization + Rate LimitingINPUT
FMonitoring/Alerting (health, logs, APM)MONITOR

1.1 Admin Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
1admin-backendP1✅ JWT+Passport, RBAC via rbac.service, token blacklist (Redis)authAuditLogger middleware, session.service.createAuditLog, DB-persisted⚠️ Env vars via Joi validation; DB_SSL defaults false⚠️ Helmet headers; DB_SSL=false default; session cookie secure only in prod✅ Joi validate middleware on all routes⚠️ Winston logger; no APM agent detectedNonePG (cert_ix_admin), Redis, auth DB, assets DB, messages DB
2admin-uiP1✅ JWT auth via admin-backend APIN/A (frontend)✅ No secrets in client code✅ HTTPS via Nginx/Kong✅ DOMPurify, client-side validation⚠️ Elastic APM RUMConsumer of admin-backend APIadmin-backend

1.2 Authentication & Identity Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
3qr-auth-serviceP0✅ JWT+session, CSRF (Redis-backed), WebAuthn, MFA, device fingerprint, token blacklist, bot detection, IP reputationAuditLogger class with tamper-resistant hashes (SHA-384 chain), DB+Kafka dual write, compliance tags (SOC2/GDPR/PCI)⚠️ Env vars; CSRF_ENCRYPTION_KEY falls back to crypto.randomBytes (ephemeral)⚠️ Kafka SSL configurable but ssl: process.env.KAFKA_SSL === 'true'; Redis TLS conditional✅ Joi validation, CAPTCHA integration, email validation, SQL injection patterns, rate limiting (DB-backed, 10 req/15min auth)⚠️ Structured logging; no APMProducer: 50+ topics (auth events, CSRF, sessions, security)PG (cert_ix_auth), Redis, Kafka, captcha-service
4qr-auth-uiP1✅ Login/register/2FA/WebAuthn UIN/A (frontend)✅ No secrets in client✅ HTTPS✅ Client-side validation, DOMPurify⚠️ Elastic APM RUMN/Aqr-auth-service
5otp-serviceP0✅ JWT auth, TOTP support✅ Kafka audit events⚠️ Env vars via config✅ Kafka TLS, Redis TLS configurable✅ Rate limiting (Redis-backed)⚠️ Logger onlyProducer: OTP eventsPG, Redis, Kafka
6captcha-serviceP1✅ API key auth for service-to-service✅ Kafka audit events⚠️ Env vars✅ Kafka TLS, TLS server✅ Challenge validation, rate limiting⚠️ Logger onlyProducer: CAPTCHA eventsRedis, Kafka

1.3 Client Frontend Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
7client-dashboardP0✅ AuthContext with JWT, session mgmt, CapabilityGate (tier-based), permission-based navN/A (frontend)✅ No secrets; encrypted token storage (CryptoJS)✅ HTTPS, security headers in layout.js✅ DOMPurify on all inputs, client-side Joi✅ Elastic APM RUMN/Aqr-auth-service, all backend APIs via Kong
8client-verifier-uiP1✅ Token-based email verificationN/A (frontend)✅ No secrets✅ HTTPS✅ Input validation⚠️ Elastic APM RUMN/Aqr-auth-service
9payment-uiP1✅ Session-based auth from checkout flowN/A (frontend)✅ No secrets; Stripe.js handles PCI✅ HTTPS, Stripe Elements (PCI DSS)✅ Zod validation⚠️ Elastic APM RUMN/Acheckout-orchestration, Stripe

1.4 Asset Management Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
10asset-management-serviceP0⚠️ Kafka-based permission validation (with fallback auth); no direct JWT middleware⚠️ Security events service; audit via Kafka events on CRUD⚠️ Env vars; encryption service uses env key⚠️ Kafka TLS configurable; encryption.service.js for data at rest⚠️ Rate limiting in config; validation in routes⚠️ Logger onlyProducer: asset CRUD events, quota sync; Consumer: permission responsesPG (cert_ix_assets), Redis, Kafka
11asset-verification-serviceP1✅ JWT auth middleware (Go)⚠️ DB logging of verification attempts⚠️ Env vars; HMAC key in env✅ TLS server (Go), HTTPS endpoints✅ Input validation on verification requests⚠️ Structured Go loggingProducer: verification eventsPG (cert_ix_asset_verification), Redis
12assets-sync-serviceP1⚠️ Kafka SCRAM auth for broker; no HTTP auth (internal)❌ No audit logging found⚠️ Env vars; Kafka SCRAM credentials✅ Kafka TLS via SCRAM config⚠️ Trust validator for data integrity❌ No monitoringConsumer: asset events; Producer: sync eventsPG, Kafka

1.5 Vulnerability & Scanning Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
13vulnerability-management-service (Go)P0✅ JWT auth middleware with tenant isolation⚠️ Audit in service layer; no dedicated audit table⚠️ Env vars; config validation✅ TLS server, DB TLS, Kafka TLS✅ Request validation, security middleware (CORS, headers)⚠️ Structured Go loggingProducer: vuln events; Consumer: scan events, capability responsesPG (cert_ix_vulnerabilities), Redis, Kafka, ES
14vulnerability-classifier-service (Go)P1✅ JWT auth middleware⚠️ Redis-based scan tracking⚠️ Env vars✅ TLS configurable⚠️ Basic validation⚠️ Go loggingConsumer: scan results; Producer: classified vulnsPG (cert_ix_vuln_classifier), Redis, Kafka
15vulnerability-policy-service (Go)P1✅ JWT auth middleware⚠️ Config-level audit⚠️ Env vars✅ TLS configurable⚠️ Model validation⚠️ Go loggingConsumer: vuln events; Producer: policy decisionsPG (cert_ix_vuln_policy), Redis, Kafka
16vulnerability-remediation-service (Go)P1✅ JWT auth middleware⚠️ Config-level audit⚠️ Env vars✅ TLS configurable✅ Model validation, auth middleware validation⚠️ Go loggingConsumer: vuln events; Producer: remediation tasksPG (cert_ix_vuln_remediation), Redis, Kafka
17go-tools (9 scanner engines)P0✅ JWT auth middleware (pkg/middleware/auth.go)pkg/scanner/audit.go — scan audit trail with retention⚠️ Env vars via config✅ TLS server, ES TLS✅ Rate limiting (Redis), input validation⚠️ Go loggingProducer: scan results; Consumer: scan requestsPG (cert_ix_tools_service), Redis, Kafka, ES
18scan-api-service (Go)P0✅ JWT auth + API key auth (api_key_service)✅ Call log repository for API audit⚠️ Env vars✅ TLS, Kafka TLS✅ Validation, rate limiting⚠️ Go loggingProducer: scan dispatch to enginesPG, Redis, Kafka
19scan-worker-service (Go)P1❌ Internal service, no HTTP auth (Kafka consumer only)❌ No audit logging⚠️ Env vars⚠️ Kafka TLS configurable❌ No HTTP input validation (Kafka only)❌ No monitoringConsumer: scan tasks; Producer: scan resultsKafka

1.6 Compliance & Audit Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
20compliance-guard-serviceP1❌ No auth middleware found❌ No audit logging❌ No secrets management❌ No TLS config❌ No validation❌ No monitoringN/Aasset-verification-service
21compliance-management-service (Go)P1⚠️ Auth references in service layer✅ Activity log in service, Kafka producer⚠️ Env vars✅ TLS configurable✅ Repository-level validation⚠️ Go loggingProducer: compliance eventsPG, Redis, Kafka
22compliance-management-service (Node, unused)P2❌ Not in use❌ Not in use❌ Not in use❌ Not in use❌ Not in use❌ Not in useN/AN/A
23audit-evidence-serviceP1⚠️ PQC decryption middleware only⚠️ Audit in middleware❌ No secrets management❌ No TLS config❌ No validation❌ No monitoringN/APG

1.7 Payment Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
24payment-processing-service (Go)P0✅ Auth middleware, user existence check❌ No audit logging found⚠️ Env vars; Vault AppRole configured but not integrated in code✅ TLS server, DB TLS, Redis TLS, Kafka TLS✅ Rate limiting middleware, OTP validation⚠️ Go loggingProducer: payment events; Consumer: OTP eventsPG, Redis, Kafka, Stripe
25checkout-orchestration-service (Go)P0⚠️ Config-level auth; no JWT middleware on routes⚠️ Kafka audit events⚠️ Env vars; Vault configured but not integrated✅ TLS, DB TLS, Kafka TLS, Redis TLS✅ Rate limiting (Redis), checkout validation⚠️ Go loggingProducer: checkout events; Consumer: plan dataPG, Redis, Kafka
26invoice-service (Go)P1❌ No auth middleware found❌ No audit logging⚠️ Env vars; Vault configured but not integrated✅ TLS server, DB TLS❌ No rate limiting, no input validation❌ No monitoringConsumer: payment events; Producer: invoice eventsPG, Kafka, R2 (Cloudflare)
27account-provisioning-service (Go)P1⚠️ Auth in provisioning service❌ No audit logging⚠️ Env vars; Vault configured but not integrated✅ TLS server, DB TLS❌ No rate limiting❌ No monitoringConsumer: subscription events; Producer: provisioning eventsPG (cert_ix_subscription), Kafka

1.8 Agent & Telemetry Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
28agent-gateway-service (Go)P1✅ Agent registration auth, JWT✅ Audit in agent service + repository⚠️ Env vars✅ TLS, Kafka TLS✅ Validation, rate limiting⚠️ Go loggingProducer: agent eventsPG, Redis, Kafka
29agent-ingestion-gateway (Go)P1⚠️ Config-level auth⚠️ Config-level audit⚠️ Env vars✅ TLS configurable⚠️ Config-level validation⚠️ Go loggingProducer: telemetry to KafkaKafka, Redis
30agent-stream-processor (Go)P2❌ No auth (internal Kafka consumer)⚠️ Audit in processors⚠️ Env vars✅ TLS configurable⚠️ Config-level validation⚠️ Go loggingConsumer: telemetry; Producer: processed dataPG, Kafka, Redis
31bits (bitcollector + sentinel)P2⚠️ mTLS for agent-to-gateway; sentinel has ES auth⚠️ Sentinel has ES-based audit⚠️ Env vars + config YAML⚠️ TLS configurable for ES connections⚠️ Basic validation❌ No monitoringAgent → Gateway (HTTP)agent-gateway, ES

1.9 Supporting Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
32email-serviceP0⚠️ Kafka auth for broker; no HTTP auth (internal)✅ Email audit logging, security config⚠️ Env vars; SendGrid API key in env✅ TLS server, Kafka TLS✅ Rate limiting, email security validation⚠️ LoggerConsumer: auth events, password reset, free plan, etc.Kafka, SendGrid, PG
33notification-serviceP1⚠️ PQC decryption middleware only⚠️ Audit in middleware❌ No secrets management❌ No TLS config found❌ No rate limiting❌ No monitoringConsumer: notification eventsKafka
34bobby-serviceP2❌ No auth found❌ No audit❌ No secrets management❌ No TLS❌ No validation❌ No monitoringN/AAI/LLM API
35nvd-serviceP2❌ No auth found❌ No audit❌ No secrets management❌ No TLS❌ No validation❌ No monitoringN/ANVD API
36subscription-service (Go)P0✅ JWT auth, tenant isolation✅ Usage tracking, audit in services⚠️ Env vars✅ TLS, DB TLS, Kafka TLS, Redis TLS✅ Validation, rate limiting⚠️ Go loggingProducer: capability responses, quota events; Consumer: capability requests, free plan, quota syncPG (cert_ix_subscription), Redis, Kafka
37teams-management-service (Go)P1✅ JWT auth⚠️ Model-level audit fields⚠️ Env vars✅ TLS configurable⚠️ Model validation⚠️ Go loggingProducer: team eventsPG, Redis, Kafka
38quota-sync-service (Go)P1❌ No auth (internal Kafka consumer)❌ No audit logging⚠️ Env vars⚠️ Kafka TLS configurable❌ No validation (internal)❌ No monitoringConsumer: quota sync events; Producer: subscription quota syncPG, Kafka

1.10 Static/Content Services

#ServiceCriticalityA:AUTHNB:AUDITC:SECRETSD:ENCRYPTE:INPUTF:MONITORKafka RoleDependencies
docs (Docusaurus)P2N/A (static)N/AN/A✅ HTTPS via NginxN/A⚠️ APM RUMN/ANginx
cert-ix-blogP2⚠️ Admin login for blog mgmt❌ No audit⚠️ Env vars✅ HTTPS⚠️ Basic validation⚠️ APM RUMN/AMongoDB
cert-ix-v1-landing-site-v1P2N/A (static + message API)❌ No audit⚠️ Env vars✅ HTTPS⚠️ Basic validation⚠️ APM RUMN/APG (message API)

2. Critical Flows & Dependencies

Flow 1: User Registration & Login (P0)

client-dashboard → qr-auth-ui → qr-auth-service → captcha-service

PG (cert_ix_auth) + Redis

Kafka → email-service (verification email)
Kafka → subscription-service (free plan activation)
Kafka → account-provisioning-service (tenant setup)

Services: qr-auth-service, qr-auth-ui, client-dashboard, captcha-service, email-service, subscription-service, account-provisioning-service
Kafka Topics: cert-ix.auth.user.registered.success, cert-ix.subscription.plan.free.request, cert-ix.subscription.plan.free.activated

Flow 2: Vulnerability Scanning (P0)

client-dashboard → Kong → scan-api-service → Kafka → go-tools (9 engines)

Kafka → vulnerability-management-service

Kafka → vulnerability-classifier-service
Kafka → vulnerability-remediation-service
Kafka → vulnerability-policy-service

Services: client-dashboard, scan-api-service, go-tools, vulnerability-management-service, vulnerability-classifier-service
Kafka Topics: cert-ix.scans.{engine}.{priority}, cert-ix.scan-results, cert-ix.scans.events

Flow 3: Asset Management (P0)

client-dashboard → Kong → asset-management-service → Kafka (permission check)

PG (cert_ix_assets) + Redis

Kafka → quota-sync-service → subscription-service
Kafka → assets-sync-service

Services: client-dashboard, asset-management-service, quota-sync-service, subscription-service, assets-sync-service
Kafka Topics: cert-ix.asset.created/updated/deleted, cert-ix.quota.sync.assets

Flow 4: Payment & Subscription (P0)

client-dashboard → payment-ui → checkout-orchestration-service → payment-processing-service → Stripe

Kafka → invoice-service
Kafka → account-provisioning-service
Kafka → subscription-service

Services: payment-ui, checkout-orchestration-service, payment-processing-service, invoice-service, account-provisioning-service, subscription-service
Kafka Topics: cert-ix.payment.*, cert-ix.checkout.*, cert-ix.subscription.*

Flow 5: Compliance & Audit (P1)

client-dashboard → Kong → admin-backend → compliance-management-service (Go)
→ audit-evidence-service
→ compliance-guard-service → asset-verification-service

Services: admin-backend, compliance-management-service, audit-evidence-service, compliance-guard-service, asset-verification-service

Flow 6: Agent Telemetry (P2)

bits (bitcollector) → agent-gateway-service → agent-ingestion-gateway → Kafka → agent-stream-processor → PG

Services: bits, agent-gateway-service, agent-ingestion-gateway, agent-stream-processor


3. P0/P1/P2 Gap Summary

P0 — BLOCKING (Must fix before launch)

IDServiceGap TypeDescriptionEffort
P0-01asset-management-serviceAUTHNNo direct JWT middleware — relies on Kafka permission check with fallback that grants access when Kafka is down4h
P0-02asset-management-serviceAUDITNo structured audit trail with traceId/correlationId4h
P0-03checkout-orchestration-serviceAUTHNNo JWT middleware on HTTP routes; config-level auth only3h
P0-04payment-processing-serviceAUDITNo audit logging for payment operations (PCI DSS requirement)4h
P0-05email-serviceAUTHNNo HTTP auth (internal service) — needs service-to-service auth or network isolation verification2h
P0-06admin-backendENCRYPTDB_SSL defaults to false — must default to true for production1h
P0-07All Go servicesSECRETSAll use env vars directly — need to verify no hardcoded secrets in docker-compose or .env committed to git2h
P0-08All servicesMONITORNo centralized health check dashboard; most services have health endpoints but no alerting4h
P0-09scan-worker-serviceAUDITNo audit logging at all — scan execution must be auditable3h
P0-10qr-auth-serviceSECRETSCSRF_ENCRYPTION_KEY falls back to ephemeral crypto.randomBytes — must be persistent env var1h

P1 — IMPORTANT (Should fix for launch, can be day-2 if blocked)

IDServiceGap TypeDescriptionEffort
P1-01compliance-guard-serviceAUTHNNo auth, no audit, no TLS, no validation — entire service needs security baseline6h
P1-02audit-evidence-serviceAUTHNOnly PQC middleware; no JWT auth, no validation, no TLS4h
P1-03notification-serviceAUTHNOnly PQC middleware; no auth, no TLS, no rate limiting4h
P1-04invoice-serviceAUTHNNo auth middleware, no audit, no rate limiting, no input validation4h
P1-05account-provisioning-serviceAUDITNo audit logging for tenant provisioning3h
P1-06assets-sync-serviceAUDITNo audit logging for sync operations2h
P1-07quota-sync-serviceAUDITNo audit logging, no monitoring2h
P1-08admin-backendINPUTNo rate limiting middleware (only session-level)3h
P1-09All Node.js servicesENCRYPTKafka SSL and Redis TLS defaults vary — need uniform true defaults3h
P1-10Vault integrationSECRETSVault AppRole configured for payment services but NOT integrated in Go code — still using env vars8h

P2 — POST-MVP

IDServiceGap TypeDescriptionEffort
P2-01bobby-serviceALLNo security baseline at all — AI assistant service8h
P2-02nvd-serviceALLNo security baseline — CVE data fetcher4h
P2-03agent-stream-processorAUTHNNo auth (internal Kafka consumer)2h
P2-04bitsMONITORNo monitoring/alerting for agent2h
P2-05cert-ix-blogAUDITNo audit logging for admin actions2h
P2-06compliance-management-service (Node)ALLUnused — should be removed or marked deprecated1h
P2-07All servicesMONITORAPM agent missing from most backend services8h

4. Remediation Plan per Flow

Flow 1: Registration & Login — Day 1 (8h)

TaskServiceGap IDEffortOwner
Fix CSRF_ENCRYPTION_KEY to require env varqr-auth-serviceP0-101h
Verify email-service is network-isolated or add service authemail-serviceP0-052h
Verify no hardcoded secrets in docker-compose/.env filesAll auth flowP0-072h
Add health check alerting for auth flow servicesqr-auth, captcha, emailP0-083h

Smoke test: Register → verify email → login → get JWT → access dashboard → logout

Flow 2: Vulnerability Scanning — Day 1-2 (10h)

TaskServiceGap IDEffortOwner
Add audit logging to scan-worker-servicescan-worker-serviceP0-093h
Verify scan-api-service audit trail completenessscan-api-service2h
Add health check alerting for scan flowgo-tools, scan-apiP0-082h
Verify Kafka TLS is enforced for scan topicsAll scan servicesP1-093h

Smoke test: Create scan → dispatch to engine → get results → view in dashboard

Flow 3: Asset Management — Day 2 (8h)

TaskServiceGap IDEffortOwner
Add JWT middleware to asset-management-serviceasset-management-serviceP0-014h
Add structured audit logging with traceIdasset-management-serviceP0-024h

Smoke test: CRUD asset → verify ownership → quota sync → subscription update

Flow 4: Payment & Subscription — Day 2-3 (11h)

TaskServiceGap IDEffortOwner
Add JWT middleware to checkout-orchestration routescheckout-orchestrationP0-033h
Add audit logging to payment-processing-servicepayment-processingP0-044h
Fix DB_SSL default to true in admin-backendadmin-backendP0-061h
Add auth + audit to invoice-serviceinvoice-serviceP1-043h

Smoke test: Select plan → checkout → Stripe payment → invoice generated → subscription active

Flow 5: Compliance & Audit — Day 3 (6h)

TaskServiceGap IDEffortOwner
Add security baseline to compliance-guard-servicecompliance-guardP1-016h

Smoke test: Run compliance check → view results → export evidence

Cross-Cutting — Day 3-4 (8h)

TaskScopeGap IDEffortOwner
Uniform Kafka SSL + Redis TLS defaultsAll servicesP1-093h
Add rate limiting to admin-backendadmin-backendP1-083h
Centralized health check dashboardAll P0 servicesP0-082h

5. E2E Testing Strategy by Flow

Principle: Test by flow, not by service

Each flow gets a smoke test script that validates the complete chain end-to-end.

Flow 1: Auth E2E Test

# scripts/e2e/test-auth-flow.sh
# 1. Get CSRF token
# 2. Get CAPTCHA challenge
# 3. Register user (POST /api/v1/register/individual)
# 4. Verify email (GET /api/v1/register/verify-email/:token)
# 5. Login (POST /api/v1/auth/login)
# 6. Verify JWT works (GET /api/v1/auth/check-session)
# 7. Verify subscription activated (GET /api/v1/subscriptions/current)
# 8. Logout (POST /api/v1/auth/logout)
# 9. Verify token blacklisted (GET /api/v1/auth/check-session → 401)
# PASS criteria: All steps return expected status codes

Flow 2: Scan E2E Test

# scripts/e2e/test-scan-flow.sh
# 1. Login → get JWT
# 2. Create asset (POST /api/v1/assets)
# 3. Verify ownership (POST /api/v1/verification/proofs)
# 4. Start scan (POST /api/v1/scans)
# 5. Poll scan status (GET /api/v1/scans/:id) until complete
# 6. Get scan results (GET /api/v1/scans/:id/results)
# 7. Verify vulnerability created in vuln-mgmt (GET /api/v1/vulnerabilities)
# PASS criteria: Scan completes, results available, vuln synced

Flow 3: Asset E2E Test

# scripts/e2e/test-asset-flow.sh
# 1. Login → get JWT
# 2. Create asset (POST /api/v1/assets)
# 3. Read asset (GET /api/v1/assets/:id)
# 4. Update asset (PATCH /api/v1/assets/:id)
# 5. Verify quota updated (GET /api/v1/subscriptions/current → usage)
# 6. Delete asset (DELETE /api/v1/assets/:id)
# 7. Verify quota decremented
# PASS criteria: CRUD works, quota syncs within 30s

Flow 4: Payment E2E Test

# scripts/e2e/test-payment-flow.sh
# 1. Login → get JWT
# 2. Get plans (GET /api/v1/plans)
# 3. Create checkout session (POST /api/v1/checkout/sessions)
# 4. Simulate Stripe webhook (POST /api/v1/webhooks/stripe)
# 5. Verify subscription updated (GET /api/v1/subscriptions/current)
# 6. Verify invoice created (GET /api/v1/invoices)
# PASS criteria: Subscription tier upgraded, invoice exists

6. Kafka Event Contract Freeze

Frozen Topics (v1.0 — backward compatible)

All topic schemas below are frozen for MVP1. Any change must be backward-compatible (additive fields only).

Topic PatternProducerConsumer(s)Schema Version
cert-ix.auth.user.registered.successqr-auth-serviceemail-service, subscription-servicev1.0
cert-ix.auth.user.login.successqr-auth-serviceemail-servicev1.0
cert-ix.subscription.plan.free.requestqr-auth-servicesubscription-servicev1.0
cert-ix.subscription.plan.free.activatedsubscription-serviceemail-servicev1.0
cert-ix.subscription.capability-requestvuln-mgmt-servicesubscription-servicev1.0
cert-ix.subscription.capability-responsesubscription-servicevuln-mgmt-servicev1.0
cert-ix.scans.{engine}.{priority}scan-api-servicego-tools workersv1.0
cert-ix.scan-resultsgo-toolsresults-processorv1.0
cert-ix.scans.eventsgo-toolsvuln-mgmt-servicev1.0
cert-ix.asset.created/updated/deletedasset-mgmt-serviceassets-sync, quota-syncv1.0
cert-ix.quota.sync.assetsasset-mgmt-servicequota-sync-servicev1.0
cert-ix.subscription.quota.syncquota-sync-servicesubscription-servicev1.0
cert-ix.payment.*payment-processinginvoice-service, account-provisioningv1.0
cert-ix.checkout.*checkout-orchestrationpayment-processingv1.0

Schema Versioning Rules

  1. Header: Every Kafka message MUST include schema-version: "1.0" header
  2. Additive only: New fields can be added; existing fields cannot be removed or renamed
  3. Consumer tolerance: All consumers MUST ignore unknown fields
  4. Breaking changes: Require new topic (e.g., cert-ix.auth.user.registered.success.v2)

7. Go/No-Go Criteria

Go Criteria (ALL must be met)

#CriterionVerification Method
1All P0 gaps remediatedCode review + deployment verification
2All 4 E2E flow smoke tests passAutomated test scripts on staging
3No hardcoded secrets in any deployed servicegrep audit of docker-compose, .env, source
4TLS enforced on all external endpointscurl -k test against Kong + all public ports
5Kafka SSL enabled for all producers/consumersConfig audit + connection test
6Redis TLS enabled for all servicesConfig audit + connection test
7Auth flow: register → login → access → logout works E2EFlow 1 smoke test
8Scan flow: create → scan → results works E2EFlow 2 smoke test
9Payment flow: checkout → pay → subscription active works E2EFlow 4 smoke test
10All P0 services have health endpoints respondingHealth check script
11Kafka event contracts frozen and documentedThis document
12Audit logs exist for auth events (login/logout/register)DB query verification

No-Go Triggers

  • Any P0 gap not remediated
  • Any E2E flow smoke test failing
  • Hardcoded secret found in production config
  • TLS not enforced on external-facing endpoint
  • Auth bypass possible on any P0 service
  • Payment flow broken (Stripe integration)

8. Timeline

Day 1 (8h) — Auth + Scan Flows

TimeTaskServices
0-1hFix CSRF_ENCRYPTION_KEY, verify secretsqr-auth-service
1-3hVerify email-service isolation, add health alertsemail-service, captcha
3-6hAdd audit logging to scan-worker-servicescan-worker-service
6-8hVerify scan flow Kafka TLS, write Flow 1+2 smoke testsAll scan services

Day 2 (8h) — Asset + Payment Flows

TimeTaskServices
0-4hAdd JWT middleware + audit to asset-management-serviceasset-management-service
4-7hAdd JWT to checkout-orchestration, audit to payment-processingpayment services
7-8hFix DB_SSL default, write Flow 3+4 smoke testsadmin-backend

Day 3 (8h) — Cross-Cutting + P1 Critical

TimeTaskServices
0-3hUniform Kafka SSL + Redis TLS defaultsAll services
3-6hAdd rate limiting to admin-backendadmin-backend
6-8hSecurity baseline for compliance-guard-servicecompliance-guard

Day 4 (4h) — Validation + Go/No-Go

TimeTaskServices
0-2hRun all 4 E2E smoke tests on stagingAll
2-3hFix any failures from smoke testsAs needed
3-4hFinal Go/No-Go review against criteriaAll

Total estimated effort: ~28h (3.5 working days)


Appendix: Service Dependency Graph

                    ┌─────────────────┐
│ client-dashboard│
│ (Next.js) │
└────────┬────────┘
│ HTTPS
┌────────▼────────┐
│ Kong Gateway │
│ (API Proxy) │
└────────┬────────┘

┌────────────────────┼────────────────────┐
│ │ │
┌─────▼─────┐ ┌───────▼───────┐ ┌──────▼──────┐
│qr-auth-svc│ │asset-mgmt-svc │ │scan-api-svc │
│ (Fastify) │ │ (Fastify) │ │ (Go) │
└─────┬─────┘ └───────┬───────┘ └──────┬──────┘
│ │ │
│ Kafka │ Kafka │ Kafka
▼ ▼ ▼
┌───────────┐ ┌───────────────┐ ┌──────────────┐
│email-svc │ │quota-sync-svc │ │go-tools (x9) │
│captcha-svc│ │assets-sync-svc│ │scan-worker │
└───────────┘ └───────┬───────┘ └──────┬───────┘
│ │
▼ ▼
┌───────────────┐ ┌──────────────┐
│subscription- │ │vuln-mgmt-svc │
│service (Go) │ │classifier-svc│
└───────┬───────┘ │policy-svc │
│ │remediation │
▼ └──────────────┘
┌───────────────┐
│payment-proc │
│checkout-orch │
│invoice-svc │
│acct-provision │
└───────────────┘

Appendix: Compliance Gap Type Distribution

Gap TypeP0 CountP1 CountP2 CountTotal
AUTHN/AUTHZ3418
AUDIT3418
SECRETS2103
ENCRYPT1102
INPUT0101
MONITOR1012
ALL (full baseline)0022
Total1011526