LOCAL IDENTITY · TARGET PRODUCTION IAM, NETWORK, SECRETS & TESTABLE CONTROLS
Аутентификация и authority boundary
Local API уже использует bearer, сервером привязанный к tenant, principal, organization и roles. Ниже опубликованы связанные target production contracts для federated human/workload identity, authorization, TLS, private networking, CORS, KMS/Vault и testable security controls: API threat model, authorization/tenant matrices, resource/audit controls, incidents, restores, activation и independent review. Они не активируют внешние control planes или production access.
- Граница выполнения
- LOCAL RUNTIME · TARGET PRODUCTION DESIGN AND TEST PLAN · ALL ACTIVATION GATES OPEN
- Production IAM, network/secrets and testable security controls v1
- ТРЕБУЕТ АКТИВАЦИИ
Контракты и исходные файлыOpenAPI, схемы и примеры для скачивания.
OpenAPI, схемы и примеры для скачивания.
Выполнить первый запрос
| Surface | Credential | Boundary |
|---|---|---|
| Control Plane API | Authorization: Bearer … | Development credential bound to one tenant |
| Corporate v2 | Role-bearing bearer | Server resolves principal, organization and roles |
| Hosted/embedded checkout | Short-lived header token or HttpOnly cookie | Exact session scope; in-memory rotation |
| Production target | OIDC/FAPI human identity; mTLS or SPIFFE-bound service identity | Target design defined; implementation, activation and operational evidence remain open |
export CERTARAIL_API_KEY='<local-development-bearer>'
curl --fail-with-body --request POST \
http://localhost:8080/v1/eligibility/evaluations \
-H "Authorization: Bearer ${CERTARAIL_API_KEY}" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: bank-order-000001" \
--data-binary @request.json- Tenant и roles определяются доверенной server-side конфигурацией.
- Конфликтующее tenant_id assertion отклоняется, а не меняет scope.
- Opaque subject/reference не доказывает entitlement сам по себе.
- Production требует approved identity lifecycle, rotation, revocation, access review и audit.
Настроить идентификацию
A22.1 фиксирует target contract, но не включает Production identity runtime. Действующий API по-прежнему использует digest-only Local bearer и server-derived tenant/principal/organization/roles; production startup остаётся заблокированным.
| Контур | Текущий факт | Статус A22.1 |
|---|---|---|
| Local bearer resolver | Реализован: digest-only static/hosted credential resolution | Не является Production IdP |
| Tenant/role context | Реализован для отдельных HTTP/domain seams и FORCE RLS relations | Не доказывает полный operation-to-policy coverage |
| OIDC/FAPI/SCIM | Runtime adapter отсутствует | Target design defined · activation open |
| Workload identity/STS | Production SPIFFE/STS integration отсутствует | Target design defined · activation open |
| JIT/access reviews | Некоторые maker-checker guards существуют локально | Production lifecycle and evidence not activated |
CertaRail не становится IdP, password authority или universal token issuer. Customer-managed enterprise IdP/authorization server подтверждает tenant humans и partner clients; отдельный workforce authority — CertaRail operators; environment-scoped SPIFFE CA/STS — workloads; isolated emergency realm — только break-glass.
- Каждый issuer регистрируется exact HTTPS value и привязывается к одному tenant/environment boundary; request-time discovery и dynamic client registration запрещены.
- Каждый route plane принимает access token только от своего registered authority и только с exact CertaRail audience; ID token, assertion либо token другого plane не являются API credential.
- CertaRail verifier после cryptographic validation заново разрешает current membership, entitlement version и resource policy. Upstream groups/roles не становятся CertaRail authority напрямую.
- Metadata/JWKS rotation допускает reviewed current/next overlap, pinning разрешённых algorithms и bounded cache; неизвестный kid или stale metadata fail closed.
- Vendor выбирается на activation по этому conformance profile. Имя продукта не подменяет FAPI/OIDC, operational ownership, residency, HA, recovery и exit evidence.
| Profile | Authority | Subjects | Trust rule | Owner |
|---|---|---|---|---|
| tenant-workforce | TENANT_MANAGED_ENTERPRISE_IDP_AND_AUTHORIZATION_SERVER | Customer workforce humans | Each exact issuer registration is approved for one tenant boundary; discovery, authorization, token, JWKS and SCIM endpoints are pinned from reviewed metadata and never selected by a request. | Tenant IAM owner |
| certarail-workforce | CERTARAIL_WORKFORCE_ENTERPRISE_IDP_AND_AUTHORIZATION_SERVER | CertaRail workforce humans | A separate workforce issuer and realm cannot mint tenant-member authority; tenant support requires a distinct approved JIT grant. | CertaRail IAM owner |
| workload-authority | ENVIRONMENT_SCOPED_SPIFFE_COMPATIBLE_CA_AND_STS | Internal workloads and controlled automation | Every canonical environment has a separate trust domain. Workload attestation binds namespace, service account and immutable deployment identity before issuing short-lived material. | Platform Security |
| emergency-realm | DEDICATED_HARDWARE_BOUND_EMERGENCY_REALM | Named break-glass custodians only | The emergency realm is isolated from normal federation, has no daily-use membership, requires two custodians to activate a 15-minute session, and pages Security immediately. | CISO delegate plus independent custodian |
- Shared, generic, orphaned и non-expiring human accounts запрещены; email, display name и mutable group label не являются identity key.
- Phishing-resistant MFA обязателен для Production humans; SMS/voice/manual OTP не являются единственным доступным privileged method.
- Browser получает только Secure, HttpOnly, host-only BFF session cookie; access/refresh tokens не попадают в JavaScript, URL, localStorage, analytics или support evidence.
| Class | Authentication source | API token issuer | Authority key | Lifecycle | Authorization boundary |
|---|---|---|---|---|---|
| tenant-human | tenant-workforce | tenant-workforce | issuer + immutable sub | SCIM joiner-mover-leaver; disable and material role removal invalidate active entitlement within five minutes. | Tenant membership, roles and resource attributes come from the CertaRail entitlement directory, not mutable email, display name, groups in request payload, or a caller-supplied tenant_id. |
| certarail-operator | certarail-workforce | certarail-workforce | issuer + immutable sub | SCIM lifecycle with named manager and system owner; support access is absent until a tenant-scoped JIT grant is approved. | Platform roles never imply tenant business authority. Tenant data access is read-only by default, ticket-bound, time-limited and separately audited. |
| external-auditor | tenant-workforce | tenant-workforce | issuer + immutable sub + reviewed tenant membership | Time-bounded invitation with explicit sponsor, expiry and quarterly recertification while active. | Read-only evidence scopes and approved export boundaries; no command, approval, credential or role-management permissions. |
| break-glass-custodian | emergency-realm | emergency-realm | emergency issuer + immutable sub + hardware key identity | Two sealed named identities, quarterly exercise, immediate credential replacement after every use or suspected compromise. | A 15-minute incident-scoped grant with command allowlist, session recording and mandatory next-business-day review; no standing tenant membership. |
- One workload/client identity cannot be shared across services, tenants or canonical environments.
- Human bearer, browser cookie and static client_secret are prohibited for service execution.
- Ownership, contact, environment, audiences, scopes, key/certificate expiry and last use are mandatory inventory fields.
| Class | Attestation/registration authority | Token issuer | Identity | Authentication | Credential | Authorization boundary |
|---|---|---|---|---|---|---|
| internal-workload | workload-authority | workload-authority | spiffe://<environment-trust-domain>/ns/<namespace>/sa/<service-account> | Attested X.509-SVID over mTLS | Non-exported workload key and certificate valid for at most 60 minutes, streamed and rotated through the Workload API. | One service, deployment identity, environment and capability scope; no shared namespace credential or tenant wildcard. |
| partner-service | tenant-workforce | tenant-workforce | One confidential OAuth client per tenant, environment and system | private_key_jwt plus mTLS client authentication | Hardware- or KMS-backed asymmetric key; five-minute certificate-bound access token and no refresh token. | Registration ceiling intersected with requested scopes and resource policy; a client cannot impersonate a human or switch tenant. |
| release-automation | workload-authority | workload-authority | Attested CI/release workload for one repository and environment | SPIFFE identity or approved CI OIDC token exchange | Single-job token with exact audience and protected-environment binding; no stored cloud or cluster credential. | Promotion and activation scopes are separate, JIT and maker-checker controlled; application runtime identity cannot deploy itself. |
| scim-provisioner | tenant-workforce | tenant-workforce | One SCIM client per tenant issuer registration | mTLS-bound client credential | Five-minute access token; asymmetric client key rotated under tenant IAM policy. | SCIM Users/Groups for its own tenant only; no Control Plane API scopes and no cross-tenant bulk operation. |
- Prohibited at launch: implicit, hybrid, password, authorization_code_without_pkce, shared_client_secret, unrestricted_token_exchange, device_authorization_at_launch.
- Authorization response validates state, nonce and issuer; redirect URI uses exact match. Tokens are never accepted from query or fragment.
- Sender constraint is a selected deployment profile, never an opportunistic fallback: mTLS for confidential/service clients; a separately approved DPoP profile may be used only where mTLS is impractical and its nonce/replay storage is proven.
| Profile | Actors | Grant | Token issuer | Client authentication | Sender constraint | Required controls |
|---|---|---|---|---|---|---|
| tenant-human-web | Tenant human browser through the tenant-facing CertaRail BFF | authorization_code | tenant-workforce | private_key_jwt or MTLS at the BFF | MTLS | FAPI 2.0 Security Profile; PKCE S256; PAR; exact redirect URI; state + nonce + iss validation; BFF keeps access and refresh tokens out of browser JavaScript |
| operator-web | CertaRail operator browser through the operations BFF | authorization_code | certarail-workforce | private_key_jwt or MTLS at the BFF | MTLS | FAPI 2.0 Security Profile; PKCE S256; PAR; separate issuer, client, audience and route plane; no tenant business role from upstream groups; support access requires a current tenant-scoped JIT grant |
| partner-service | Tenant or partner backend | client_credentials | tenant-workforce | private_key_jwt plus MTLS | MTLS | exact issuer and audience; certificate-bound access token; no refresh token; one client per tenant and environment; asymmetric key in HSM or KMS |
| internal-workload | Attested CertaRail workload | token_exchange | workload-authority | MTLS workload channel | MTLS | RFC 8693 token exchange; exact requested audience; no unrestricted impersonation; actor chain retained in audit; environment trust domains never federate by default |
| delegated-background-job | Queued job acting for a previously authorized principal | token_exchange | workload-authority | Attested workload MTLS | MTLS | immutable actor and subject chain; scope can only narrow; resource and command binding; single purpose and expiry; revocation checked before execution |
- Validate exact issuer, audience, authorized party/client, signature algorithm and key ID, expiry, not-before, issued-at, sender constraint, token ID, entitlement version and environment. Unknown issuer/key/scope or stale authorization fails closed.
- Asymmetric keys are HSM/KMS backed, have named owners and rotate on an approved schedule with tested current/next overlap; private material never enters source, image, environment dump, URL, log or evidence payload.
- Human disable, service disable, key compromise and privileged-grant withdrawal reach the PDP immediately and every resource server within five minutes; privileged operations always consult live entitlement state.
| Artifact | Maximum | Rotation/revocation rule |
|---|---|---|
| Authorization code | 60s | Single use; PKCE and client bound |
| PAR request_uri | 60s | Single use; exact client and redirect binding |
| Human access token | 300s | Sender constrained; no browser JavaScript storage |
| Service access token | 300s | mTLS-bound; no refresh token |
| Privileged access token | 180s | Live PDP check and fresh step-up |
| BFF refresh/session | 8h absolute · 30m idle | One-time refresh rotation; family revoke on reuse |
| Privileged session | 15m | JIT operation allowlist; no standing elevation |
| X.509-SVID | <= 60m | Streamed rotation; private key remains workload-local |
Назначить и проверить полномочия
Scope является client/token ceiling, а не окончательным разрешением. Wildcard scope отсутствует; server authorizes только пересечение registration, token, current role и resource policy.
| Family | Exact scopes | Privileged scopes |
|---|---|---|
| identity | identity:profile:read | none |
| eligibility | eligibility:read, eligibility:evaluate, eligibility:review | eligibility:review |
| checkout | checkout:read, checkout:write | none |
| deal | deal:read, deal:write, deal:approve | deal:approve |
| onboarding | onboarding:read, onboarding:write, onboarding:review | onboarding:review |
| provider | provider:read, provider:operate, provider:approve | provider:operate, provider:approve |
| webhook | webhook:read, webhook:manage, webhook:replay | webhook:manage, webhook:replay |
| evidence | evidence:read | none |
| audit | audit:export | audit:export |
| reporting | reporting:read, reporting:prepare | reporting:prepare |
| iam | iam:read, iam:manage, iam:review | iam:read, iam:manage, iam:review |
| runtime | runtime:read, runtime:operate | runtime:read, runtime:operate |
| security | security:respond | security:respond |
| support | support:inspect | support:inspect |
| production | production:activate | production:activate |
RBAC задаёт стабильные job functions; ABAC/PDP сужает их по tenant, organization, environment, resource owner, mandate, amount, provider connection, data class и maker-checker history.
- Decision = intersection of registered client scope, token scope, current role grant and resource policy; any missing or unknown input is DENY.
- Maker and approver permissions are not combined in one business role. A principal cannot approve a command, role grant, replay or activation it prepared.
- Service identities receive direct exact scopes and resource bindings; importing human roles into a workload token is prohibited.
| Role | Principal type | Scope grants | Mandatory constraint |
|---|---|---|---|
| corporate:maker | HUMAN | identity:profile:read, eligibility:read, eligibility:evaluate, checkout:read, checkout:write, deal:read, deal:write, provider:read, provider:operate, evidence:read | Mandate, amount, connection and resource ownership; cannot approve own command. |
| corporate:approver | HUMAN | identity:profile:read, eligibility:read, checkout:read, deal:read, deal:approve, provider:read, provider:approve, evidence:read | Independent checker; cannot prepare the command being approved. |
| corporate:compliance | HUMAN | identity:profile:read, eligibility:read, eligibility:review, deal:read, onboarding:read, onboarding:review, evidence:read, reporting:read | Review authority only; no deal preparation or provider execution scope. |
| corporate:auditor | HUMAN | identity:profile:read, eligibility:read, checkout:read, deal:read, onboarding:read, provider:read, webhook:read, evidence:read, reporting:read, iam:read, audit:export | Read-only; export requires a separately approved bounded operation. |
| corporate:admin | HUMAN | identity:profile:read, iam:read, iam:manage | May propose tenant membership and roles; cannot approve own grant or perform business commands. |
| onboarding:owner | HUMAN | identity:profile:read, onboarding:read, onboarding:write | Own organization draft only; no review of own submission. |
| onboarding:editor | HUMAN | identity:profile:read, onboarding:read, onboarding:write | Assigned organization draft only; no review scope. |
| onboarding:reviewer | HUMAN | identity:profile:read, onboarding:read, onboarding:review | Independent reviewer; creator/updater cannot review the same version. |
| developer:admin | HUMAN | identity:profile:read, webhook:read, webhook:manage, webhook:replay, evidence:read | Exact tenant and environment; production secret/replay changes remain privileged operations. |
| submission:operator | HUMAN / SERVICE | identity:profile:read, reporting:read, reporting:prepare, evidence:read | Draft preparation only unless an independently activated official transport scope exists. |
| retail:buyer | HUMAN | identity:profile:read, checkout:read, checkout:write, deal:read, deal:write | Own subject and admission grant only; no privileged read or approval. |
| deal:reader | HUMAN / SERVICE | identity:profile:read, deal:read, evidence:read | Explicit resource assignment; no tenant-wide inference from the role name. |
| platform:operator | HUMAN | identity:profile:read, runtime:read, runtime:operate, evidence:read | No tenant data by default; maintenance is JIT and ticket-bound. |
| security:operator | HUMAN | identity:profile:read, iam:read, iam:review, security:respond, audit:export | Incident and IAM checker duties; cannot silently assume tenant business roles. |
| support:readonly | HUMAN | identity:profile:read, support:inspect, evidence:read | One tenant, one ticket and at most 60 minutes; safe projections only. |
| release:operator | HUMAN / SERVICE | identity:profile:read, runtime:read, production:activate | Protected environment and release digest binding; cannot approve own activation. |
| audit:reviewer | HUMAN | identity:profile:read, iam:read, iam:review, evidence:read, audit:export | Independent review and export approval; no mutable business scope. |
| Layer | Required control | Mandatory negative evidence |
|---|---|---|
| FEDERATION_REGISTRY | An exact issuer and client registration maps to one tenant and canonical environment. Dynamic issuer, JWKS URI, redirect URI and tenant selection are prohibited. | Unknown issuer, issuer reused for an unapproved tenant, metadata redirect, JWKS host change and cross-environment client are rejected. |
| TOKEN_VALIDATION | Resource servers validate issuer, audience, client/authorized party, time, signature algorithm, key, sender constraint and entitlement version before resolving membership. | Wrong audience, expired/future token, algorithm downgrade, unknown key, replayed proof and stale entitlement version are rejected. |
| HTTP_CONTEXT | Authentication middleware creates one immutable identity context. Tenant, organization, principal, environment and roles are server-derived; conflicting body/header/query assertions fail closed. | Caller-supplied tenant_id, duplicate Authorization, mixed checkout/operator credentials and conflicting organization are rejected without existence disclosure. |
| POLICY_DECISION_POINT | Authorization is the intersection of registered client ceiling, token scopes, current role grants and resource attributes including tenant, organization, environment, mandate, owner and maker-checker history. | Scope-only, role-only, stale-cache, self-approval, resource-owner mismatch and environment escalation are denied. |
| POSTGRESQL_RLS | Every tenant relation uses composite tenant keys, transaction-local tenant context and FORCE RLS. Runtime roles are not owners and have no superuser, BYPASSRLS, DDL or inherited elevated membership. | Cross-tenant read/write, unset tenant context, direct table mutation, owner/BYPASSRLS startup and connection-pool context leakage are denied. |
| ASYNC_AND_CACHE | Queue, inbox, outbox, cache, idempotency and object-storage identities include the authoritative tenant/environment boundary; workers re-authorize before external or privileged effects. | Cross-tenant cache keys, foreign queue records, reused idempotency keys, stale delegated grants and object references from another tenant are quarantined or denied. |
| SUPPORT_ACCESS | Internal support has no implicit tenant membership. Access names one tenant, case, purpose, safe data projection, approver and expiry and is visible to the tenant audit trail. | Standing global support, hidden impersonation, multi-tenant query, expired JIT grant and access without ticket/approval are denied and alerted. |
Privileged capability is absent by default and issued just in time for one ticket and operation family. Every operation requires a fresh phishing-resistant step-up and a different checker; role possession alone is insufficient.
- Self-approval, standing global admin, hidden impersonation, shared break-glass account and elevation without expiry are prohibited.
- The immutable receipt binds tenant/environment, subject, actor, maker, checker, scopes, resource, reason, ticket, before/after digest, issued/expiry time and outcome.
- Expiry removes authority automatically. Cleanup/revocation evidence is part of completion, not a separate optional task.
| Operation | Action | Required scopes | Max elevation | Evidence |
|---|---|---|---|---|
| IDP_TRUST_CHANGE | Add, change, disable or rotate issuer, metadata, redirect URI, JWKS or SCIM trust. | iam:manage + iam:review | 30m; step-up <= 5m | ticket; before/after digest; maker and checker; conformance plus rollback result |
| PRIVILEGED_ROLE_GRANT | Grant, extend or remove a privileged human role or JIT eligibility. | iam:manage + iam:review | 60m; step-up <= 5m | ticket and business reason; subject and role; maker and checker; expiry and revocation observation |
| SERVICE_IDENTITY_CHANGE | Create, rescope, rotate, disable or delete a service identity. | iam:manage + iam:review | 60m; step-up <= 5m | owner; client/workload identity; scope and audience diff; rotation or disable proof |
| PRODUCTION_ACTIVATION | Activate a capability or external-effect route in Production. | production:activate + iam:review | 30m; step-up <= 5m | release digest; closed activation gates; maker and checker; rollback and post-change observation |
| PROVIDER_CREDENTIAL_BINDING | Bind, rotate, revoke or reassign a production provider credential or account. | provider:approve + security:respond | 30m; step-up <= 5m | provider/account reference digest; vault version; maker and checker; negative old-key test |
| MANUAL_REPLAY_OR_REQUEUE | Replay a delivery/event or requeue a dead-lettered operation. | webhook:replay + runtime:operate | 30m; step-up <= 5m | incident/change ticket; immutable source digest/range; maker and checker; bounded outcome and reconciliation |
| TENANT_DATA_EXPORT | Export restricted tenant evidence or audit data. | audit:export + iam:review | 30m; step-up <= 5m | purpose and legal basis reference; tenant/data/time range; maker and checker; encrypted artifact expiry and access log |
| AUDIT_OR_RETENTION_POLICY_CHANGE | Change audit destination, retention, legal hold or evidence integrity policy. | iam:review + audit:export | 30m; step-up <= 5m | policy diff; owner approvals; maker and checker; validation and rollback result |
| BREAK_GLASS_SESSION | Open emergency access when the normal control plane is unavailable. | security:respond + runtime:operate | 15m; step-up <= 5m | declared incident; two hardware-bound custodians; complete command/session record; credential replacement and next-day review |
- Review population is generated from authoritative memberships, client registrations, JIT eligibility, keys/certificates and last-use data; spreadsheets without a signed snapshot digest are not authoritative.
- Every decision is CERTIFY, REVOKE or TIME_BOUND_EXCEPTION with owner and due date. Missing reviewer or overdue exception fails the affected privileged activation closed.
- Review completion means removals propagated to sessions/tokens/PDP and were observed, not merely that a ticket was closed.
| Review | Cadence | Scope | Independent reviewer | Evidence |
|---|---|---|---|---|
| event-driven-jml | CONTINUOUS; leaver and critical role removal SLA <= 5 minutes | Human memberships, group mappings, active sessions and JIT grants | Tenant or CertaRail IAM owner matching the identity authority | SCIM event ID; before/after entitlement digest; session revocation result; completion timestamp and SLA |
| monthly-privileged-and-service | MONTHLY | Privileged-role eligibility, service clients, workload identities, keys/certificates, owners and last use | Security owner plus independent system owner | immutable population snapshot; owner attestations; unused/orphaned findings; revocations, exceptions and due dates |
| quarterly-all-human-access | QUARTERLY | Every human tenant membership, role, scope ceiling, resource assignment and separation-of-duties conflict | Tenant access owner; privileged reviewers cannot certify themselves | snapshot digest and as-of time; reviewer identities; decision per principal; completed removals and tracked exceptions |
| semiannual-federation-trust | SEMIANNUAL AND BEFORE MATERIAL FEDERATION CHANGE | Issuers, metadata, redirect URIs, JWKS/certificates, SCIM clients, OAuth clients, audiences and trust domains | IAM architect plus Security checker | registered trust inventory; metadata/key fingerprints; conformance and negative-test report; approved changes and rollback evidence |
| post-incident-review | WITHIN 1 BUSINESS DAY AFTER BREAK-GLASS; WITHIN 5 BUSINESS DAYS AFTER OTHER IAM INCIDENTS | Incident grants, authentication events, token/client use, commands, exports and containment | Incident commander plus independent Security/Audit reviewer | incident timeline; principal/token/session correlation; commands and accessed scope; revocation, credential replacement and actions |
| Gate | Owner | Status | Required evidence |
|---|---|---|---|
| IAM_IDP_SELECTED_AND_CONFORMANT | IAM Architecture | OPEN | Named products/deployments, FAPI 2.0/OIDC conformance result, exact issuer metadata and ownership. |
| IAM_RUNTIME_ADAPTER_IMPLEMENTED | Application Security | OPEN | OIDC/JWKS, mTLS/DPoP, token exchange and SCIM adapters with negative tests; OpenAPI updated only after runtime acceptance. |
| IAM_PDP_POLICY_ENFORCED | Application Security | OPEN | Operation-to-scope registry, RBAC/ABAC decisions, live revocation and self-approval denial tests. |
| IAM_TENANT_ISOLATION_PROVEN | Security Engineering | OPEN | HTTP, cache/queue and PostgreSQL FORCE RLS cross-tenant suite using non-owner/non-BYPASSRLS runtime roles. |
| IAM_PRIVILEGED_ACCESS_EXERCISED | Security Operations | OPEN | JIT, step-up, maker-checker, expiry, emergency access and audit drill with denied bypass attempts. |
| IAM_ACCESS_REVIEW_COMPLETED | IAM Governance | OPEN | One complete monthly and quarterly review cycle with removals, exceptions, SLA and immutable evidence. |
| IAM_SECURITY_ACCEPTANCE_COMPLETE | CISO delegate | OPEN | Threat-model update, external penetration test, incident/revocation drill, residual-risk acceptance and production activation record. |
Защитить сетевой доступ
A22.2 фиксирует target Production contract. Текущий Compose остаётся loopback-only Local runtime: Nginx слушает HTTP, PostgreSQL/Kafka/Redis используют local-only development credentials and/or plaintext transports, а production KMS, Vault, private endpoints и emergency control plane не подключены.
| Контур | Текущий факт | Статус A22.2 |
|---|---|---|
| Local Compose network | Loopback host ports, internal Docker networks and hardening controls | Не является Production private-network proof |
| TLS/mTLS | Local Nginx-to-Go and stateful services do not implement this Production TLS profile | Target design defined · activation open |
| Secrets/KMS | Local environment configuration and application crypto seams exist without approved Production Vault/KMS/HSM custody | Target design defined · activation open |
| Rotation/revocation | Selected sandbox credentials have bounded or one-time semantics | No end-to-end Production drill or SLA evidence |
| Environment separation | Canonical five-class taxonomy is published | Production account/network/key/data isolation remains unproven |
TLS 1.3 является default minimum для всех Production planes. TLS 1.2 допускается только как отдельное time-bound compatibility exception для одного named interface; downgrade fallback отсутствует.
- Запрещены SSL_2_0, SSL_3_0, TLS_1_0, TLS_1_1, NULL/RC4/CBC/static-RSA suites, compression, insecure renegotiation и silent downgrade.
- TLS 1.2 exception разрешает только TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256, TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384, TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256, TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 и имеет owner, expiry, migration date и negative downgrade evidence.
- 0-RTT выключен по умолчанию и запрещён для create/approve/confirm/replay/rotate/revoke/delete/export и любых команд с side effect.
- Certificate inventory, automated renewal, expiry alerting, revocation and old/new validation являются частью acceptance evidence.
| Plane | Exposure | Minimum | Peer authentication | Identity check |
|---|---|---|---|---|
| public-browser-edge | PUBLIC_APPROVED_HTTPS_EDGE_ONLY | TLS_1_3 | SERVER_CERTIFICATE | Exact SNI, hostname and approved certificate chain |
| partner-service-api | APPROVED_INGRESS_GATEWAY | TLS_1_3 | MTLS | Exact registered client certificate plus certificate-bound OAuth audience |
| internal-service | PRIVATE_NETWORK_ONLY | TLS_1_3 | MTLS | Environment-scoped workload identity and exact destination service identity |
| administration-control-plane | DEDICATED_PRIVATE_MANAGEMENT_PLANE | TLS_1_3 | MTLS | Managed-device operator identity, JIT grant and exact administrative endpoint |
| managed-data-service | PRIVATE_ENDPOINT_ONLY | TLS_1_3 | MTLS | Workload identity, pinned service endpoint and database/broker authorization |
Public reachability заканчивается на approved HTTPS/mTLS gateways. Data, secret, cryptographic, administration и observability control planes не имеют public address; каждый flow задаётся source identity, destination identity, port и purpose.
- Ingress default: DENY; egress default: DENY. Unknown identity, destination, port, DNS answer or purpose is denied.
- Private connectivity does not authorize a principal: mTLS/workload identity, OAuth audience, current PDP policy and application tenant binding remain mandatory.
- IDENTITY_AWARE_EGRESS_PROXY_OR_CONTROLLED_NAT; EXACT_SCHEME_HOST_PORT_AND_PROVIDER_PROFILE_ALLOWLIST; redirects are denied and DNS/IP rebinding defences are required.
- Management and emergency planes are isolated from public ingress; peering, transitive routing and cross-environment trust are denied by default.
| Source identity | Destination identity | Port | Purpose |
|---|---|---|---|
| approved-edge-gateway | control-plane-api | TCP/8443 | Validated public and partner API ingress |
| control-plane-api | postgresql-runtime | TCP/5432 | Tenant-bound transactional state |
| outbox-publisher | kafka-broker | TCP/9093 | mTLS/SASL outbox publication |
| approved-runtime-workload | vault-or-secret-manager | TCP/443 | Identity-bound secret lease retrieval |
| approved-crypto-workload | kms-private-endpoint | TCP/443 | Purpose-bound encrypt, decrypt, sign or verify operation |
| webhook-delivery-worker | approved-partner-endpoint | TCP/443 | Allowlisted signed webhook delivery |
CORS отключён по умолчанию. Browser-enabled routes use an exact server-owned HTTPS origin allowlist per surface and environment; partner/internal service APIs do not emit CORS headers.
- Parse and canonicalize the Origin header, compare it to an exact environment-scoped allowlist and emit the matched canonical origin only.
- Emit Vary: Origin whenever a response can vary by Origin; preflight cache policy must vary by origin, method and requested headers.
- Reject malformed, multiple, opaque/null, HTTP or unregistered origins before handler execution.
- Allow-Credentials is emitted only for an approved cookie-based BFF/hosted profile and never with a wildcard origin.
- CORS does not replace session authentication, authorization, CSRF token plus Fetch Metadata validation, CSP frame-ancestors or postMessage origin checks.
| Profile | Allowed origins | Credentials | Methods | Headers |
|---|---|---|---|---|
| tenant-web-bff | Exact tenant web origins registered for one environment | Secure HttpOnly host-only SameSite session cookie | GET, POST, PUT, PATCH, DELETE, OPTIONS as required per route | Content-Type, Idempotency-Key, X-CSRF-Token and exact documented request headers |
| hosted-checkout | Same-origin hosted checkout only | Secure HttpOnly checkout session cookie | GET, POST, OPTIONS for exact checkout routes | Content-Type, Idempotency-Key and X-CSRF-Token |
| embedded-checkout | Exact origin registered in the server-issued embed session | No ambient cookie; origin-bound memory-only header token | GET, POST, OPTIONS for exact embedded routes | Content-Type, Idempotency-Key and checkout session header |
| partner-and-internal-apis | None | mTLS/OAuth service identity outside browser CORS | No CORS profile | No Access-Control-Allow-* headers |
Управлять ключами и секретами
Каждый canonical environment получает отдельную key hierarchy. Private keys and KEKs are non-exportable; workloads invoke only a purpose-bound cryptographic operation over a private endpoint.
- Envelope AAD binds tenant_id + environment + purpose + object_type + object_id + schema_version + key_version. Plaintext data keys are never persisted.
- Key-policy administrator, crypto user, custodian and auditor are distinct; no principal may create policy, use a key and approve destructive lifecycle changes alone.
- Disable/delete is maker-checker, impact-tested and delayed. Legal hold, backup/recovery and decrypt dependencies block destruction.
- KMS logs record metadata and result only; plaintext, private key, data key, bearer and restricted payload are prohibited.
| Key family | Purpose | Environment | Tenant binding |
|---|---|---|---|
| DATA_ENVELOPE_KEK | Wrap tenant- and object-scoped data encryption keys | Dedicated | AAD_AND_KEY_POLICY |
| SECRET_WRAPPING_KEK | Wrap persisted application secret material | Dedicated | NAMESPACE_AND_AAD_WHERE_TENANT_SCOPED |
| APPLICATION_SIGNING_KEY | Sign bounded application artifacts and assertions | Dedicated | SEPARATE_KEY_OR_EXACT_SIGNING_CONTEXT |
| WEBHOOK_ROOT_KEY | Derive or wrap tenant endpoint signing keys | Dedicated | TENANT_ENDPOINT_AND_KEY_GENERATION_CONTEXT |
| EVIDENCE_INTEGRITY_KEY | Sign evidence manifests and immutable export roots | Dedicated | MANIFEST_CONTEXT_AND_TENANT_SCOPE |
| BACKUP_RECOVERY_KEK | Wrap environment backup data keys | Dedicated | BACKUP_SET_AND_ENVIRONMENT_CONTEXT |
A bank-approved secret manager is the Production source of truth. Workloads authenticate with environment-scoped identity, receive the narrowest dynamic lease and never receive a reusable root credential.
- Forbidden locations: SOURCE_CONTROL, IMAGE_LAYER, BROWSER_STORAGE, URL, CI_LOG, APPLICATION_LOG, EVIDENCE_PAYLOAD, ANALYTICS, TICKET_OR_CHAT, UNENCRYPTED_ENV_FILE.
- One namespace or mount per canonical environment
- Separate application, platform, integration and emergency policy domains
- Tenant-specific path and policy where a secret grants tenant authority
- No wildcard read/list capability across tenants or environments
- Long-lived static secret is an approved exception with owner, expiry and migration plan; dynamic database/cloud credentials are the default.
| Fields | Delivery | Cache | Audit |
|---|---|---|---|
| owner, purpose, environment, tenant_scope, consumer_identities, version, created_at, expires_at, last_used_at, rotation_state, revocation_state, incident_reference | Agent, sidecar or native workload-identity integration writes a bounded memory/tmpfs lease; applications never receive a reusable Vault root token. | Memory only, least lifetime, zeroized on replacement or shutdown; no fallback to stale material after revocation or lease expiry. | Record identity, secret metadata reference, version, operation, policy result and time; never record secret value or derived credential. |
Rotation is an observable state machine, not an overwrite. Current/next material is prepared and verified before cutover; old material is negatively tested before the operation is complete.
- Suspected compromise starts containment/rotation within 15 minutes; the affected credential is revoked sooner where technically possible.
- Known or suspected disclosure, unauthorized use or unexplained authentication
- Owner, custodian, consumer identity, tenant or environment boundary change
- Algorithm, provider, trust anchor or policy change
- Failed integrity check, inventory mismatch, expired attestation or overdue scheduled rotation
- Break-glass use affecting the credential or its trust path
PREPARED
Persist the transition, actor, approvals, material metadata fingerprint, consumer acknowledgements and outcome before advancing.
DISTRIBUTED
Persist the transition, actor, approvals, material metadata fingerprint, consumer acknowledgements and outcome before advancing.
DUAL_READ_VERIFY
Persist the transition, actor, approvals, material metadata fingerprint, consumer acknowledgements and outcome before advancing.
PRIMARY
Persist the transition, actor, approvals, material metadata fingerprint, consumer acknowledgements and outcome before advancing.
RETIRED
Persist the transition, actor, approvals, material metadata fingerprint, consumer acknowledgements and outcome before advancing.
REVOKED
Old material is unusable, negative use is observed, dependants are reconciled and evidence is closed.
| Credential/key class | Max lifetime | Planned overlap | Rule |
|---|---|---|---|
| WORKLOAD_X509_SVID | 3600s | 600s | Stream and rotate automatically; workload-local private key is never exported. |
| ACCESS_TOKEN | 300s | 0s | Issue from current authority only; no token extension. |
| PRIVILEGED_ACCESS_TOKEN | 180s | 0s | Fresh step-up and live PDP check; no refresh token. |
| DATABASE_DYNAMIC_CREDENTIAL | 3600s | 300s | Issue a role-scoped lease and revoke it automatically on expiry. |
| PROVIDER_API_CREDENTIAL | 7776000s | 86400s | Rotate sooner when provider policy allows; current/next validation and negative old-key test are mandatory. |
| WEBHOOK_SIGNING_KEY | 7776000s | 604800s | Publish key ID, verify current/previous generations during the bounded overlap and reject unknown or retired key IDs. |
| KMS_WRAPPING_KEY | 31536000s | 2592000s | Rotate the key version; rewrap data keys asynchronously and retain the old version only for verified decrypt dependencies. |
| PUBLIC_EDGE_CERTIFICATE | 2592000s | 604800s | Automated renewal, external expiry monitoring and rollback-tested deployment. |
Ownership means accountability for policy and lifecycle; custody means control of private material. CertaRail does not become custodian of tenant asset private keys and does not receive KMS/Vault root or export authority.
| Key class | Owner | Custodian | Approver | Consumers | CertaRail access |
|---|---|---|---|---|---|
| TENANT_CUSTODY_PRIVATE_KEYS | EXTERNAL_REGULATED_CUSTODIAN | External custodian HSM and named key officers | Tenant custody/security authority under dual control | Custodian signing service only | PROHIBITED |
| TENANT_IDP_AND_PARTNER_CLIENT_KEYS | DEPLOYING_BANK_OR_TENANT_IAM_OWNER | Tenant-managed HSM/KMS | Tenant IAM owner plus Security checker | Registered IdP, confidential clients and verifier trust store | PUBLIC_METADATA_OR_EXACT_CRYPTO_OPERATION_ONLY |
| TLS_EDGE_AND_SERVICE_CERTIFICATE_KEYS | DEPLOYING_BANK_PLATFORM_SECURITY | Environment CA, managed certificate service or workload | Platform Security plus service owner | Exact edge or workload identity | NON_EXPORTABLE_OPERATION_ONLY |
| KMS_KEY_HIERARCHY | DEPLOYING_BANK_SECURITY | Bank-approved KMS/HSM and independent custodians | Key-policy maker and independent checker | Purpose-bound workload identities | NO_ROOT_OR_EXPORT_ACCESS |
| VAULT_ROOT_RECOVERY_AND_UNSEAL | DEPLOYING_BANK_SECURITY | Independent sealed recovery custodians or managed service | Incident commander plus Security checker | Break-glass recovery ceremony only | NO_STANDING_ACCESS |
| WEBHOOK_ENDPOINT_SIGNING_KEYS | TENANT_INTEGRATION_OWNER | CertaRail production secret manager; receiver stores one-time delivered copy | Tenant integration maker and independent checker | Named delivery worker and registered receiver endpoint | PURPOSE_BOUND_SIGN_OPERATION_ONLY |
| EVIDENCE_AND_BACKUP_KEYS | DEPLOYING_BANK_SECURITY_AND_RECORDS_OWNER | Separated KMS/HSM recovery domain | Security plus Records/Recovery checker | Evidence signer or recovery workflow only | PURPOSE_BOUND_OPERATION_ONLY |
Revocation is complete only when the authoritative disable decision has propagated and a denied use is observed. Ticket closure alone is not evidence of revocation.
- Compromise revocation bypasses planned overlap: block first, then distribute replacement and reconcile ambiguous operations.
- Short lifetime limits residual risk but does not replace disable, PDP policy update, session termination, provider-side revoke or key-ID rejection.
- Every revocation links replacement material by metadata reference only; no secret or recoverable private key appears in evidence.
| Class | Action | Max propagation | Evidence |
|---|---|---|---|
| HUMAN_SESSION_AND_REFRESH_FAMILY | Disable membership/JIT grant, revoke the refresh family and terminate active BFF sessions; reuse revokes the entire family. | 5m | Credential/key metadata reference and reason without secret material; Requester, maker/checker or incident authority and timestamps; Authoritative disable/revoke result plus propagation observations; Negative authentication/use test, affected-resource reconciliation and replacement link |
| ACCESS_TOKEN | Deny high-risk token IDs at the PDP and rely on short expiry; every privileged request performs a live entitlement/revocation check. | 5m | Credential/key metadata reference and reason without secret material; Requester, maker/checker or incident authority and timestamps; Authoritative disable/revoke result plus propagation observations; Negative authentication/use test, affected-resource reconciliation and replacement link |
| WORKLOAD_CERTIFICATE | Stop issuance for the attested identity, remove trust/authorization and replace the SVID; short validity bounds residual exposure. | 5m | Credential/key metadata reference and reason without secret material; Requester, maker/checker or incident authority and timestamps; Authoritative disable/revoke result plus propagation observations; Negative authentication/use test, affected-resource reconciliation and replacement link |
| SERVICE_CLIENT | Disable the exact tenant/environment client, revoke active grants and rotate its asymmetric key/certificate. | 5m | Credential/key metadata reference and reason without secret material; Requester, maker/checker or incident authority and timestamps; Authoritative disable/revoke result plus propagation observations; Negative authentication/use test, affected-resource reconciliation and replacement link |
| DATABASE_LEASE | Revoke the dynamic lease/role sessions, terminate affected connections and issue a replacement only after workload re-attestation. | 5m | Credential/key metadata reference and reason without secret material; Requester, maker/checker or incident authority and timestamps; Authoritative disable/revoke result plus propagation observations; Negative authentication/use test, affected-resource reconciliation and replacement link |
| PROVIDER_CREDENTIAL | Disable/detach at the provider, block local use, reconcile commands during the uncertainty window and activate a separately prepared version. | 5m | Credential/key metadata reference and reason without secret material; Requester, maker/checker or incident authority and timestamps; Authoritative disable/revoke result plus propagation observations; Negative authentication/use test, affected-resource reconciliation and replacement link |
| WEBHOOK_SIGNING_KEY | Mark the key ID revoked, stop signing, reject it at verification, issue a new generation and reconcile delivery attempts in the overlap. | 5m | Credential/key metadata reference and reason without secret material; Requester, maker/checker or incident authority and timestamps; Authoritative disable/revoke result plus propagation observations; Negative authentication/use test, affected-resource reconciliation and replacement link |
| KMS_KEY | Deny new cryptographic use, isolate affected consumers and rewrap/re-sign with a replacement version; destruction waits for governed evidence. | 5m | Credential/key metadata reference and reason without secret material; Requester, maker/checker or incident authority and timestamps; Authoritative disable/revoke result plus propagation observations; Negative authentication/use test, affected-resource reconciliation and replacement link |
Break-glass reuses the A22.1 BREAK_GLASS_SESSION contract: two distinct hardware-bound custodians activate one incident-scoped 15-minute session over an isolated private emergency path.
- Incident declaration, reason, impact and alternative-path failure
- Both custodian identities, hardware-auth events and issued/expiry time
- Complete approved command/session record and accessed resource metadata
- Automatic expiry, affected-credential rotation and next-business-day independent review
| Control | Fixed decision |
|---|---|
| IAM operation | BREAK_GLASS_SESSION |
| Approval | TWO_DISTINCT_PRINCIPALS; self-approval PROHIBITED |
| Session | 15m; standing access PROHIBITED |
| Network | Dedicated private emergency path, disabled in normal operation and unable to traverse public ingress. |
| Secret boundary | Exact sealed secret/key metadata and command allowlist for the declared incident; no list-all, export or root-token delivery. |
| Cannot bypass | Tenant custody/private-key boundary; Maker-checker for asset or money movement; Evidence integrity, retention or legal hold; Production activation gates; Bulk tenant data or secret export |
DEMO, LOCAL, HOSTED_SANDBOX, PROVIDER_SANDBOX and PRODUCTION share source artifacts, not trust or secret material. Production is isolated across account/project, network, PKI, KMS, Vault, identity clients, data planes, telemetry and recovery.
- Cross-environment trust: DENY_BY_DEFAULT; artifact promotion: IMMUTABLE_DIGEST_AND_PROVENANCE.
- Prohibited: each environment re-binds identity, endpoints, keys, secrets and policies from its own approved control plane.
- Only explicitly approved one-way metadata/aggregate export; no credential, restricted payload or control-plane trust is inherited.
- No shared IdP client, audience, PKI trust domain, KMS alias/root, Vault namespace, database, topic, cache prefix, log sink or backup set crosses into Production.
| Environment | Isolated dimensions | Data/secret rule |
|---|---|---|
| DEMO | CLOUD_ACCOUNT_OR_PROJECT, NETWORK_AND_PRIVATE_DNS, PKI_TRUST_DOMAIN, KMS_KEY_HIERARCHY, VAULT_NAMESPACE_OR_MOUNT, IDP_CLIENT_ISSUER_AND_AUDIENCE, DATA_STORES_QUEUES_CACHES_AND_TOPICS, LOGS_AUDIT_AND_BACKUPS | Synthetic or explicitly approved irreversibly sanitized fixtures only |
| LOCAL | CLOUD_ACCOUNT_OR_PROJECT, NETWORK_AND_PRIVATE_DNS, PKI_TRUST_DOMAIN, KMS_KEY_HIERARCHY, VAULT_NAMESPACE_OR_MOUNT, IDP_CLIENT_ISSUER_AND_AUDIENCE, DATA_STORES_QUEUES_CACHES_AND_TOPICS, LOGS_AUDIT_AND_BACKUPS | Synthetic or explicitly approved irreversibly sanitized fixtures only |
| HOSTED_SANDBOX | CLOUD_ACCOUNT_OR_PROJECT, NETWORK_AND_PRIVATE_DNS, PKI_TRUST_DOMAIN, KMS_KEY_HIERARCHY, VAULT_NAMESPACE_OR_MOUNT, IDP_CLIENT_ISSUER_AND_AUDIENCE, DATA_STORES_QUEUES_CACHES_AND_TOPICS, LOGS_AUDIT_AND_BACKUPS | Synthetic or explicitly approved irreversibly sanitized fixtures only |
| PROVIDER_SANDBOX | CLOUD_ACCOUNT_OR_PROJECT, NETWORK_AND_PRIVATE_DNS, PKI_TRUST_DOMAIN, KMS_KEY_HIERARCHY, VAULT_NAMESPACE_OR_MOUNT, IDP_CLIENT_ISSUER_AND_AUDIENCE, DATA_STORES_QUEUES_CACHES_AND_TOPICS, LOGS_AUDIT_AND_BACKUPS | Synthetic or explicitly approved irreversibly sanitized fixtures only |
| PRODUCTION | CLOUD_ACCOUNT_OR_PROJECT, NETWORK_AND_PRIVATE_DNS, PKI_TRUST_DOMAIN, KMS_KEY_HIERARCHY, VAULT_NAMESPACE_OR_MOUNT, IDP_CLIENT_ISSUER_AND_AUDIENCE, DATA_STORES_QUEUES_CACHES_AND_TOPICS, LOGS_AUDIT_AND_BACKUPS | No Production data or secrets may move to a lower environment |
| Gate | Owner | Status | Required evidence |
|---|---|---|---|
| NETWORK_TLS_PROFILE_ACCEPTED | Platform Security | OPEN | External and internal scans, certificate inventory/renewal drill, mTLS identity denial and TLS 1.0/1.1/unsafe cipher/0-RTT negative results. |
| NETWORK_PRIVATE_TOPOLOGY_ENFORCED | Cloud Security | OPEN | Approved topology, no-public-IP proof, identity-and-port flow matrix, egress/SSRF tests and denied lateral/transitive paths. |
| NETWORK_CORS_AND_CSRF_NEGATIVE_SUITE_PASSED | Application Security | OPEN | Exact-origin matrix with wildcard, reflection, null/malformed/multiple origin, preflight cache, CSRF and postMessage denial tests. |
| SECRETS_KMS_AND_VAULT_INTEGRATED | Platform Security | OPEN | Named bank-approved providers, key/secret inventory, non-exportability and role separation tests, envelope round trip and denied wildcard access. |
| SECRETS_ROTATION_AND_REVOCATION_DRILLED | Security Operations | OPEN | Planned and compromise rotations for every class, current/next cutover, rollback, five-minute revocation observations and negative old-key tests. |
| SECRETS_BREAK_GLASS_DRILLED | Incident Response | OPEN | Two-custodian 15-minute exercise, command/session record, denied prohibited bypass, automatic expiry, credential replacement and review. |
| NETWORK_ENVIRONMENT_ISOLATION_PROVEN | Security Engineering | OPEN | Cross-environment network, PKI, KMS, vault, audience, data, queue, log and backup denial suite plus immutable artifact promotion proof. |
| NETWORK_SECRETS_SECURITY_ACCEPTANCE_COMPLETE | CISO delegate | OPEN | Updated threat model, external penetration test, recovery exercise, residual-risk acceptance and signed production activation record. |
Проверить защитные меры
A22.3 публикует testable control contract и точные repository evidence locators. Он не превращает Local/sandbox tests, generated JSON или checklist в Production acceptance, restore drill либо independent review.
| Level | Что можно утверждать | Что остаётся OPEN |
|---|---|---|
| Repository test | Named source path and test function exercise a current Local/sandbox control. | Production IdP/network/KMS/Vault/topology/capacity. |
| Repository integration test | Named PostgreSQL test can exercise durable/RLS behavior when its test database is available. | Production role inventory, HA, backup, restore and operational ownership. |
| Production-like evidence | Exact immutable candidate is exercised in the approved isolated topology. | Independent assessment and signed activation until separately completed. |
| Independent evidence | Qualified non-author reviewer retests controls and findings against exact candidate digests. | Only the named activation authority can approve Production use. |
OWASP_API_SECURITY_TOP_10_2023_PLUS_CERTARAIL_ABUSE_CASES. Scope: Every public, partner, internal, administration, webhook, worker, export and recovery API in all canonical environments.
- Assets: Tenant identity, organization binding, scopes, roles and approval state; Authoritative policy, decision, idempotency, ledger, movement and provider state; Credentials, signing/encryption key references and revocation state; Audit, evidence, outbox/inbox, webhook and recovery artifacts; Availability, per-tenant fairness and production activation authority.
- Trust boundaries: Browser or partner client to approved edge/BFF/API gateway; Gateway to control-plane API and authorization decision point; Application runtime to PostgreSQL, cache, Kafka, Temporal and object storage; Webhook/provider ingress and controlled outbound delivery/adapter egress; Human administration to private JIT management and break-glass planes; Production to backup, DR, restore and independent-review environments.
- Adversaries: Unauthenticated internet client; Authenticated user or workload exceeding its tenant/resource authority; Compromised tenant administrator, support principal or service credential; Malicious or compromised provider/webhook endpoint; Insider with partial database, log, KMS, Vault or deployment access; Automated abuse causing cost, queue, parser, connection or storage exhaustion.
- Every reachable operation must inherit at least one risk row, control owner and positive/negative test before activation.
| Risk | CertaRail abuse case | Controls | Test cases |
|---|---|---|---|
| API1:2023 · Broken Object Level Authorization | A valid principal substitutes another tenant resource ID or causes a background/export job to load it. | AUTHZ-001, TENANT-001, AUDIT-001 | AUTHZ-POSITIVE-OWN-OBJECT, AUTHZ-NEGATIVE-CROSS-OBJECT, AUTHZ-NEGATIVE-TENANT-CONFLICT |
| API2:2023 · Broken Authentication | An attacker reuses expired, revoked, wrong-audience or confused principal-type credentials. | AUTHN-001, AUDIT-001 | AUTHN-NEGATIVE-MISSING, AUTHN-NEGATIVE-INVALID, AUTHZ-NEGATIVE-REVOKED, AUTHZ-NEGATIVE-IDENTITY-CONFUSION |
| API3:2023 · Broken Object Property Level Authorization | A caller over-posts tenant/owner/status/approval fields or receives properties outside its relationship. | AUTHZ-002, CONFIG-001 | AUTHZ-NEGATIVE-PROPERTY |
| API4:2023 · Unrestricted Resource Consumption | A client exhausts bytes, parsing, concurrency, database, export, queue, retry or paid-provider budgets. | RESOURCE-001, AUDIT-001 | RESOURCE-BODY-LIMIT, RESOURCE-CONCURRENCY-LIMIT, RESOURCE-DEADLINE, RESOURCE-PAGE-EXPORT-LIMIT, RESOURCE-TENANT-COST-BUDGET, RESOURCE-DATABASE-BUDGET, RESOURCE-RETRY-AMPLIFICATION |
| API5:2023 · Broken Function Level Authorization | A lower-privilege principal calls an administrative function or self-approves a privileged action. | AUTHZ-002, AUDIT-001 | AUTHZ-NEGATIVE-SCOPE, AUTHZ-NEGATIVE-SELF-APPROVAL |
| API6:2023 · Unrestricted Access to Sensitive Business Flows | Automation races or repeats a state-changing flow, bypasses ordering or consumes an unbounded business resource. | FLOW-001, RESOURCE-001, AUDIT-001 | FLOW-REPLAY-CONFLICT, RESOURCE-TENANT-COST-BUDGET |
| API7:2023 · Server Side Request Forgery | A configured URL reaches a private, link-local or redirected destination outside the approved provider profile. | SSRF-001, CONFIG-001 | SSRF-DESTINATION-ESCAPE |
| API8:2023 · Security Misconfiguration | A missing setting activates debug routes, permissive origins, plaintext transport, verbose errors or excess privileges. | CONFIG-001, INVENTORY-001, AUDIT-001 | CONFIG-FAIL-CLOSED, INVENTORY-ROUTE-DRIFT |
| API9:2023 · Improper Inventory Management | A stale, shadow, undocumented or lower-environment endpoint remains reachable without current controls. | INVENTORY-001, CONFIG-001 | INVENTORY-ROUTE-DRIFT |
| API10:2023 · Unsafe Consumption of APIs | Authenticated third-party data is trusted without schema, size, semantic, deadline, replay or provenance validation. | DEPENDENCY-001, RESOURCE-001, AUDIT-001 | DEPENDENCY-UNTRUSTED-RESPONSE, RESOURCE-DEADLINE, RESOURCE-RETRY-AMPLIFICATION |
Tests follow the public seam: identity validation, route/function policy, object/relationship predicate and response filtering. A mocked permit decision without the protected handler/resource assertion is insufficient.
- Generate the matrix from canonical operation security plus A22.1 scope/RBAC/resource policies; fail if a reachable protected operation has no positive and negative case.
- Assert the downstream/domain spy count is zero on deny and compare durable state/effects before and after each negative case.
- Use missing, malformed, expired, revoked, wrong-issuer/audience, wrong principal type, missing scope, wrong tenant/object and protected-property variants.
- Authorization evidence records exact candidate digest, IdP/PDP/policy versions, test fixture IDs, result and audit-event digest without credentials.
| ID | Stimulus | Expected | Assertion | Evidence level |
|---|---|---|---|---|
| AUTHZ-POSITIVE-OWN-OBJECT | Authorized principal uses the declared scope on its own tenant object. | 200 | The exact allowed projection is returned and the permit decision is audited. | PRODUCTION_LIKE |
| AUTHN-NEGATIVE-MISSING | Omit the required credential. | 401 | Fail before handler execution and emit no protected metadata. | REPOSITORY_AND_PRODUCTION_LIKE |
| AUTHN-NEGATIVE-INVALID | Use malformed, expired, wrong-issuer, wrong-audience or invalid-signature material. | 401 | Every credential class fails closed with a bounded public error and reason-coded audit record. | PRODUCTION_LIKE |
| AUTHZ-NEGATIVE-SCOPE | Use a valid identity without the required operation scope or role. | 403 | No domain method or downstream dependency is invoked. | REPOSITORY_AND_PRODUCTION_LIKE |
| AUTHZ-NEGATIVE-CROSS-OBJECT | Tenant A requests a valid resource identifier that belongs to tenant B. | 404 | Deny before side effects and preserve the endpoint existence-hiding policy. | REPOSITORY_AND_PRODUCTION_LIKE |
| AUTHZ-NEGATIVE-PROPERTY | Add tenant, owner, role, status, approval or internal routing fields to a request. | 400 | Reject unknown/protected properties; response filtering never discloses unauthorized fields. | REPOSITORY_AND_PRODUCTION_LIKE |
| AUTHZ-NEGATIVE-SELF-APPROVAL | The maker attempts to approve its own privileged operation. | 403 | Approval requires two distinct principals and cannot be satisfied by role aliasing or session replacement. | REPOSITORY_AND_PRODUCTION_LIKE |
| AUTHZ-NEGATIVE-IDENTITY-CONFUSION | A workload credential calls a human-only route or a human session calls a workload-only operation. | 403 | Principal type, client/workload identity and authentication context remain authorization inputs. | PRODUCTION_LIKE |
| AUTHZ-NEGATIVE-TENANT-CONFLICT | A valid identity supplies a conflicting tenant in path, query, body or forwarding header. | 403 | The trusted server binding wins; the conflicting assertion is rejected and never becomes scope. | REPOSITORY_AND_PRODUCTION_LIKE |
| AUTHZ-NEGATIVE-REVOKED | Reuse a revoked session, token family, client or workload certificate. | 401 | Use is denied within the A22.1/A22.2 propagation SLA and linked to revocation evidence. | PRODUCTION_LIKE |
Create tenant A and tenant B with distinct organizations, principals, resources, idempotency keys, cache entries, topic identities, jobs, audit records and backup samples.
- PostgreSQL runtime role owns tables: false; BYPASSRLS: false; FORCE RLS required: true.
- SET LOCAL certarail.tenant_id inside every transaction; missing or malformed context fails closed.
- Repeat the matrix for list, detail, create, mutate, delete/revoke, batch, search, export, retry/replay and recovery paths; success on one route cannot stand in for another.
- A 404 existence-hiding response must still prove zero tenant-B read/effect in service/database/audit evidence.
| Layer | Positive assertion | Negative assertion | Evidence |
|---|---|---|---|
| HTTP_TRANSPORT | Tenant A can use its own path/query/body/header combination only where the contract allows it. | Every caller-selected conflicting tenant/organization/subject value is rejected before service invocation. | HTTP transcript; service-spy assertion; audit decision |
| DOMAIN_SERVICE | Trusted scope is passed explicitly into repositories and dependent services. | A mismatched aggregate, relationship, approval or replay owner cannot transition state. | focused domain test; state diff; side-effect count |
| POSTGRES_RLS | A non-owner runtime role reads/writes rows only with matching SET LOCAL tenant context. | Missing context, tenant B access, WITH CHECK violation and attempted RLS bypass all fail. | role grants; FORCE RLS inventory; live two-tenant SQL transcript |
| CACHE | Cache namespace and signed envelope bind environment, tenant, resource, policy version and authority epoch. | Tenant B, stale epoch, wrong key ID and moved raw key/value cannot produce authority or a cache hit. | key-shape test; envelope verification; cold-cache result |
| KAFKA | Producer/consumer identity, topic ACL, partition key and envelope carry the same tenant/environment binding. | Cross-tenant topic access, envelope mismatch and unauthorized replay are denied or quarantined. | broker ACL export; negative publish/consume transcript; quarantine evidence |
| BACKGROUND_WORK | Outbox, workflow, retry, scan and export jobs rehydrate signed tenant scope from durable state. | A queue payload alone cannot select tenant/resource or redirect an effect. | job envelope; restart test; cross-tenant poison-message test |
| AUDIT_AND_EXPORT | Audit/search/export requires tenant-aware authorization and records exact selection criteria. | Batch, pagination, alias/correlation lookup and downloadable evidence never cross tenant boundaries. | export manifest; negative lookup tests; audit access event |
| PRIVILEGED_SUPPORT | JIT support access names one tenant, reason, ticket, command allowlist and expiry. | Standing, global, self-approved or expired support access is denied. | PAM grant; two-person approval; session recording metadata; post-review |
| BACKUP_AND_RESTORE | Restore preserves tenant keys/policies and validation can sample each tenant independently. | Restore tooling cannot copy production tenant data/secrets into a lower environment or expose a cross-tenant export. | restore manifest; environment attestations; two-tenant verification |
Limits are versioned policy with owner, measured source, metric, overload outcome and test. Edge, application and dependency budgets must compose; a high outer limit cannot silently bypass a lower inner guarantee.
- Run boundary and limit-plus-one tests, then slowloris/concurrency/storm and sustained soak tests against the exact candidate.
- Measure per-tenant fairness, memory/CPU/goroutines, connection pools, statement/lock time, queue age/bytes, retry amplification and provider cost units.
- Production limits require capacity evidence and rollback/override ownership; Local defaults are implementation facts, not Production sizing.
| Control | Metric | Current repository fact | Limit source | Overload outcome |
|---|---|---|---|---|
| REQUEST_BODY_BYTES | HTTP request bytes and parse allocations | Generic JSON 1 MiB; checkout JSON 64 KiB; strict single-object decoder with unknown fields rejected. | Versioned operation contract; edge limit must be equal to or stricter than the application limit. | Reject before service execution with a bounded 4xx response and no body echo. |
| UPLOAD_BYTES | Upload bytes, media type, scan bytes and storage reservation | Signed fixed Content-Length, allowlisted media type and 10 MiB maximum in the Local document workflow. | Approved document class policy plus capacity and malware-scanner envelope. | Reject before persistence; partial bytes never become an accepted document. |
| REQUEST_CONCURRENCY | In-flight requests and service operations by route class and tenant | Bounded eligibility and control-plane semaphores; saturation returns 429 with Retry-After. | Measured capacity test and per-tenant fairness policy. | Immediate 429; no unbounded queue or goroutine allocation. |
| OPERATION_DEADLINE | End-to-end and downstream operation duration | Eligibility defaults to 2 seconds; control-plane operations default to 10 seconds and propagate cancellation. | Operation SLO with a smaller downstream budget and explicit retry/idempotency semantics. | Cancel work, preserve ambiguous-outcome recovery and return a retry-safe bounded error. |
| PAGINATION_AND_EXPORT | Rows scanned, rows returned, encoded bytes and export duration | Selected current endpoints cap arrays/pages; no repository-wide production export budget is proven. | Per-operation OpenAPI limit plus approved asynchronous export profile. | Reject over-limit synchronous export; use authorized bounded async artifact creation where designed. |
| TENANT_RATE_AND_COST_BUDGET | Requests, sensitive actions, provider calls and cost units per tenant/credential/principal | Hosted sandbox credential has fixed request/reset budgets; this is not a production distributed limiter. | Approved product entitlement and abuse-risk policy. | 429 with durable reason and reset metadata; protected control capacity remains available. |
| DATABASE_BUDGET | Pool wait, active connections, statement time, lock time, rows and temporary bytes | Write admission and bounded SQL shapes exist; production pool/statement/lock budgets require measured configuration. | PostgreSQL HA/DR connection budget and per-workload capacity plan. | Backpressure before commit; reserved migrator, monitoring and emergency capacity is not consumed. |
| OUTBOX_AND_WEBHOOK_BUDGET | Backlog bytes/age, leases, attempts, retry horizon and per-destination concurrency | Bounded backoff, deadlines, attempt caps, quarantine and write admission are covered by repository tests. | Destination SLO, broker capacity and durable storage high-water policy. | Stop new affected writes where durability is at risk; quarantine terminal work without deleting evidence. |
| DECOMPRESSION_AND_PARSER_BUDGET | Expanded bytes, nesting, tokens, fields and parser CPU | Strict JSON and bounded payloads exist; no universal compressed-input policy is proven. | Media-type-specific parser profile with compressed input disabled unless explicitly required. | Reject unsupported encoding, excessive expansion/depth/fields or parser deadline before durable work. |
Schema certarail.security-audit-event.v1; production sink EXTERNAL_APPEND_ONLY_WORM_OR_EQUIVALENT; legally material command on audit failure: FAIL_CLOSED.
- Authentication success/failure and credential lifecycle
- Authorization permit/deny including policy/reason and protected operation
- Privileged request, approval, execution, expiry and break-glass review
- Tenant/security configuration and production activation changes
- Secret/key create, use metadata, rotate, revoke, disable and recovery
- Evidence/export access, deletion request, legal hold and retention action
- Rate/quota/backpressure decisions and security-control degradation
- Backup, restore, failover, incident and independent-review evidence changes
| Class | Requirements |
|---|---|
| Required fields | event_id, schema_version, occurred_at, recorded_at, tenant_id, environment, actor_id, actor_type, issuer, client_or_workload_id, authentication_context, action, resource_type, resource_id_digest, decision, reason_code, policy_version, request_id, trace_id, idempotency_key_digest, evidence_digest, previous_event_digest, event_digest |
| Conditional fields | organization_id, subject_ref_digest, maker_actor_id, checker_actor_id, change_or_incident_ticket, source_network_zone, credential_id_digest, before_digest, after_digest |
| Forbidden fields | bearer_token, cookie, private_key, secret_value, raw_document, request_body, url_query, plaintext_personal_data, recoverable_credential |
| Integrity | Canonical event digest plus predecessor/segment manifest; signed immutable export with sequence/gap verification and separately administered time source. |
| Access | Dedicated least-privilege writer, security reader and independent auditor; application administrators cannot alter retention or historical events. |
| SIEM | Metadata-only routed events with rule/version ownership, delivery acknowledgement, lag/gap alerting and dead-letter recovery. |
| Retention | Approved per event/data class with residency, legal hold and cryptographic-erasure dependencies; not fixed by this repository contract. |
Подготовить действия при сбое
Each scenario has an inject/detect/contain/recover sequence, executable assertions and immutable evidence. Tabletop validates decisions and ownership; a technical exercise validates the actual control path. Activation requires both where applicable.
- Record commander, observers, start/end, candidate digest, canary IDs, decision log, control timings, gaps, follow-up owners and retest links.
- No scenario authorizes real money/asset movement, provider/regulator effects, destructive Production testing or unapproved secret exposure.
- A detection-only exercise does not close containment/recovery assertions; a tabletop does not replace the named technical drill.
| Scenario | Safe injection | Detect | Contain / recover | Assertions |
|---|---|---|---|---|
| COMPROMISED_HUMAN_SESSION | Use a canary human session after refresh-family revoke. | revoked-use signal; impossible/risky session correlation | terminate session family; remove JIT grants; block affected principal / reauthenticate strongly; review protected actions; rotate affected credentials | revocation SLA met; no new protected action; complete timeline |
| COMPROMISED_SERVICE_IDENTITY | Use an old workload certificate/client after emergency revoke. | certificate/client anomaly; revoked-use attempt | revoke identity; deny workload policy; isolate workload/network path / issue new bound identity; redeploy clean artifact; reconcile commands | old identity denied; new identity least-privileged; ambiguous effects reconciled |
| CROSS_TENANT_ACCESS | Attempt API, RLS, cache, Kafka, worker and export access from tenant A to tenant B. | deny and anomaly signals; RLS/policy violations | block principal/client; freeze affected export/workers; preserve evidence / verify all isolation layers; notify per approved plan; retest fixed path | zero unauthorized disclosure/effect; scope of exposure determined; negative retest passes |
| RESOURCE_EXHAUSTION | Generate bounded body, concurrency, page, database, queue and retry pressure. | saturation and fairness SLO alerts; cost/quota anomaly | tenant/credential throttle; load shedding; destination circuit/open admission gate / drain bounded backlog; reconcile dropped/retried work; restore normal limits under approval | other tenants remain within SLO; no unbounded growth; idempotency preserved |
| WEBHOOK_OR_SSRF_COMPROMISE | Use invalid/rotated signatures and an endpoint resolving outside its approved profile. | signature failure; destination-policy denial; delivery anomaly | pause endpoint; revoke key; deny egress profile / verify endpoint again; rotate key; replay only exact approved events | no disallowed connection; old key denied; replay is exact and audited |
| KMS_OR_VAULT_OUTAGE_COMPROMISE | Deny KMS/Vault access or disable an environment key/secret lease. | lease/crypto failure; decrypt/sign error budget alert | fail closed; isolate affected identity/key; invoke two-person recovery / restore approved service; rotate exposed material; verify old/new negative use | no plaintext fallback; no cross-environment key use; custody separation preserved |
| POSTGRES_FAILOVER_OR_CORRUPTION | Fence a primary or restore to a selected pre-corruption point. | quorum/lag/archive/invariant alert; authority epoch change | close writes; fence old primary; block external publication / promote or PITR; rebuild cache; reconcile audit/ledger/idempotency/outbox | one writer; measured RPO/RTO; all invariants pass |
| KAFKA_BACKLOG_OR_POISON_EVENT | Publish a schema-invalid/tenant-mismatched canary and stop consumer progress. | schema/ACL rejection; lag and oldest-age alert; poison retry signal | quarantine event; pause affected partition/consumer; preserve outbox truth / fix consumer/config; resume from durable watermark; reconcile outbox/inbox | ordering preserved; no duplicate side effect; unaffected partitions continue |
| AUDIT_GAP_OR_TAMPER | Remove, reorder or mutate a canary event and delay sink delivery. | digest/sequence/gap failure; sink lag alert | freeze affected privileged actions; preserve source segments; restrict log access / re-export immutable segment; reconcile source-of-truth events; document any irrecoverable gap | tamper is detectable; gap is not silently accepted; secrets remain absent |
| SUPPLY_CHAIN_OR_CONFIG_TAMPER | Attempt to deploy an unsigned/unknown digest or drifted security configuration. | provenance/policy failure; runtime config drift alert | block rollout; revoke artifact/identity; isolate affected workload / redeploy approved digest; rotate exposed credentials; reconcile runtime state | unknown artifact never receives traffic; rollback is controlled; new digest attested |
| IDP_OR_PDP_OUTAGE | Make the production IdP/JWKS or authorization decision point unavailable/stale. | freshness/fetch/PDP availability alert; deny-rate change | fail closed for privileged/new sessions; bound any approved cached-read exception / restore trusted source; refresh keys/policies; terminate stale sessions where required | no permissive fallback; stale policy window bounded; recovery audited |
| BREAK_GLASS_USE | Run an approved simulated emergency operation through the isolated path. | immediate Security page; PAM session start/expiry | 15-minute scoped session; two distinct custodians; no policy/audit bypass / auto-expire access; rotate affected credentials; next-business-day review | self-approval impossible; allowlist enforced; session cannot be extended silently |
Backup is accepted only after an observed restore into an isolated production-like environment, verification of declared invariants and measured comparison to an approved BIA/service SLO.
- External egress, Kafka/webhook/provider publication and production credentials are prohibited in the restore environment.
- Sample tenant A and tenant B independently; validate that recovered exports, keys/policies, audit and evidence remain tenant-bound.
- Do not invent RPO/RTO in this contract: approved BIA/SLO owns objectives, while each exercise records actual measured values and variance.
- Destroy the isolated exercise environment only through the approved evidence-preserving cleanup process.
| Restore | Procedure | Assertions | Required evidence | Status |
|---|---|---|---|---|
| POSTGRES_PITR | Restore base backup and WAL to a sampled timestamp; keep egress and publishers disabled; fence any old writer. | pg_verifybackup/vendor verification passes; schema compatibility and migration digests pass; idempotency, audit heads, ledger balance, outbox heads and evidence digests reconcile; authority_epoch changes before traffic resumes; measured RPO/RTO meet the approved objectives | backup manifest; LSN/timeline; invariant report; timings; approval receipt | OPEN |
| AUDIT_AND_EVIDENCE_ARCHIVE | Restore selected immutable audit/evidence segments, manifests, legal-hold metadata and key-version references. | segment signatures/digests and predecessor chains verify; tenant and retention boundaries remain intact; missing/tampered objects fail verification; no raw secret or unapproved payload appears in restored metadata | object-lock policy; restore manifest; verification report; access audit | OPEN |
| KMS_AND_VAULT_RECOVERY | Exercise approved KMS/HSM and Vault recovery with environment-scoped canary keys/leases and two-person custody. | non-exportability and role separation remain intact; only required canary artifacts decrypt/verify; retired/revoked material remains denied; recovery creates no shared root or cross-environment trust | custody approvals; key/lease metadata; positive/negative crypto transcript; audit | OPEN |
| KAFKA_REBUILD_AND_CONSUMER_RESUME | Rebuild publication from committed outbox and resume consumers from durable inbox/watermarks in a blocked-egress destination. | per-key order and tenant envelope remain valid; duplicates create no duplicate side effect; poison events quarantine without blocking unrelated streams; outbox, broker and inbox counts reconcile | offset/watermark manifest; outbox/inbox reconciliation; ACL proof; timings | OPEN |
| REDIS_COLD_START | Start with empty cache/session/rate-limit namespaces according to their separate durability contracts. | authoritative correctness does not depend on cached values; stale authority epoch values are rejected; database load under 100 percent cache miss stays within the approved envelope; security budgets fail closed where durable counters are required | cold-cache load report; authority tests; database metrics; limit decision log | OPEN |
| CONFIG_IDENTITY_AND_POLICY_RESTORE | Reconstruct signed configuration, IdP/PDP clients, scopes/RBAC mappings and approved policy assignments from immutable source plus secrets by reference. | artifact digests/provenance match the approved release; no secret is present in configuration backup; revoked principals/clients remain revoked; unknown or stale policy/config keeps readiness closed | configuration manifest; identity/PDP export; negative auth tests; readiness evidence | OPEN |
Собрать подтверждения для активации
| Gate | Owner | Status | Required evidence |
|---|---|---|---|
| SOURCE_ACCEPTANCE_LEDGER_COMPLETE | Product Security | OPEN | Every applicable A15–A22 report acceptance criterion maps to a control, current test/evidence reference, owner and explicit gap. |
| API_THREAT_MODEL_APPROVED | CISO delegate | OPEN | Reviewed data-flow/abuse-case model covers every deployed API/version/environment and names residual risk owners. |
| A22_1_IAM_GATES_CLOSED | Identity Platform | OPEN | Every certarail.production-iam-design.v1 activation gate is closed with immutable evidence. |
| A22_2_NETWORK_SECRETS_GATES_CLOSED | Platform Security | OPEN | Every certarail.production-network-secrets-design.v1 activation gate is closed with immutable evidence. |
| AUTHORIZATION_MATRIX_PASSED | Application Security | OPEN | Positive and negative operation-to-scope/RBAC/resource/property tests pass against the immutable production candidate. |
| TENANT_ESCAPE_MATRIX_PASSED | Application Security | OPEN | Two-tenant HTTP/domain/RLS/cache/Kafka/job/export/support/restore matrix passes with a non-owner runtime role. |
| RESOURCE_ABUSE_CAPACITY_ACCEPTED | SRE | OPEN | Measured byte/parser/concurrency/rate/database/export/queue/retry limits preserve fairness and approved SLOs. |
| AUDIT_PIPELINE_ACCEPTED | Security Operations | OPEN | External append-only/WORM-equivalent sink, SIEM delivery/gap alerting, retention/access controls and secret-canary tests pass. |
| INCIDENT_EXERCISES_ACCEPTED | Incident Commander | OPEN | Tabletop and technical exercises cover identity, tenant escape, exhaustion, provider/webhook, KMS/Vault, data, audit, supply chain and break-glass. |
| RESTORE_OBJECTIVES_ACCEPTED | SRE | OPEN | Observed isolated restores satisfy approved BIA/SLO RPO/RTO and every declared invariant; backup creation alone does not close this gate. |
| OBSERVABILITY_AND_ON_CALL_READY | SRE | OPEN | Control health, saturation, authorization denies, audit gaps, revocation, recovery and dependency alerts page named owners and link runbooks. |
| INDEPENDENT_REVIEW_COMPLETE | CISO delegate | OPEN | Independent signed report and retest close all Critical/High findings; lower findings have explicit risk owner, decision and expiry. |
| ACTIVATION_AND_ROLLBACK_SIGNED | System Owner + CISO delegate | OPEN | Immutable candidate digest, go/no-go record, staged activation, rollback criteria, kill path and post-activation verification are approved. |
Status: NOT_PERFORMED; reviewer: NOT_SELECTED. Reviewer and final approver must not be the control author, production administrator, key custodian or finding owner; conflicts are disclosed.
- Authors may approve: false.
- Production testing default: PROHIBITED_UNLESS_EXPLICITLY_APPROVED_IN_RULES_OF_ENGAGEMENT; destructive: PROHIBITED; real effects: PROHIBITED.
- Finding severity combines technical exploitability with CertaRail tenant, regulatory, financial/evidence and availability impact; the report preserves reproducible safe evidence.
| Area | Fixed plan |
|---|---|
| Scope | API architecture, data flows, trust boundaries and threat model; Human/workload IAM, scopes/RBAC/resource policy and privileged access; Tenant isolation through HTTP, domain, PostgreSQL RLS, cache, Kafka, jobs, exports and restore; TLS/private network/CORS/egress, KMS/HSM, Vault, rotation and revocation; Resource-consumption, sensitive-flow abuse and provider/webhook security; Audit/SIEM/WORM, incident response, backup/restore and supply chain |
| Methods | THREAT_MODEL_AND_ARCHITECTURE_REVIEW, SOURCE_AND_CONFIGURATION_REVIEW, AUTHENTICATED_API_PENETRATION_TEST, TENANT_ESCAPE_TEST, CLOUD_IAM_NETWORK_KMS_VAULT_REVIEW, RESOURCE_ABUSE_AND_RESILIENCE_TEST, OBSERVED_INCIDENT_EXERCISE, OBSERVED_RESTORE_EXERCISE, SUPPLY_CHAIN_AND_PROVENANCE_REVIEW |
| Inputs | Immutable source commit, build/image digest, SBOM and provenance; A15–A22 source acceptance ledger and versioned machine contracts; Production-like topology/config exports with secrets redacted by construction; Test manifests, raw transcripts, metrics, audit manifests and drill receipts; Data classification, BIA/SLO, retention, incident and access-review decisions |
| Rules of engagement | Named systems, tenants, source addresses, time window, stop conditions and incident contacts; Synthetic/canary data and credentials; no real asset movement or provider/regulator effect; Production-safe validation only by explicit written scope; destructive tests run in an isolated production-like environment; Findings and evidence use approved encrypted channels and retention; secrets are never embedded in the report |
| Deliverables | Signed scope and independence/conflict declaration; Finding register with stable ID, severity, affected asset/control, evidence and reproducible safe steps; Remediation owner, due date and explicit risk acceptance authority; Independent retest evidence and residual-risk statement; Final activation recommendation bound to exact candidate digests |
| Cadence | Before first Production activation; At least annually after activation; After material identity, authorization, tenant, network, cryptographic, recovery or provider-boundary change; After a severe incident or evidence of control bypass |
| Exit criteria | All Critical and High findings are independently retested closed. Any remaining finding has named risk owner, signed decision, compensating controls and expiry; the final report is bound to the exact activation candidate. |
Repository checks below are exact locators, not stored pass claims. Run outputs must record command, timestamp, toolchain, immutable source digest, environment and result; production evidence stays separate.
- PRODUCTION_LIKE_AUTHORIZATION_AND_TENANT_MATRIX · OPEN · Immutable-candidate execution with production IdP/PDP, non-owner RLS role, cache, Kafka, workers, exports and support access.
- MEASURED_RESOURCE_ABUSE_AND_CAPACITY · OPEN · Signed load profile, limits, fairness/SLO results, cost budgets, edge and dependency saturation evidence.
- EXTERNAL_AUDIT_SINK_AND_INCIDENT_DRILLS · OPEN · WORM-equivalent/SIEM manifests, secret canaries, gap alerts and completed technical incident exercises.
- OBSERVED_RESTORE_AND_FAILOVER · OPEN · Isolated production-like restore/failover evidence meeting approved BIA/SLO objectives and invariants.
- INDEPENDENT_REVIEW_AND_RETEST · OPEN · Independent signed scope, findings, remediation/retest and residual-risk recommendation bound to candidate digests.
| Check | Level | Command | Files | Proves |
|---|---|---|---|---|
| HTTP_AUTHENTICATION_AND_TENANT_BINDING | REPOSITORY_TEST | go test ./internal/httpapi -run 'Test(AuthenticateRequiresOneCanonicalBearerHeader|AuthenticateRejectsUnknownMultiBuyerCredential|EvaluationRejectsTenantOutsideCredentialBinding)$' | internal/httpapi/handler_test.go, internal/httpapi/tenantauth_test.go | Current Local bearer grammar and server-derived tenant rejection paths only; not production OIDC/mTLS. |
| AUTHORIZATION_AND_MAKER_CHECKER | REPOSITORY_TEST | go test ./internal/httpapi -run 'Test(CorporateOnboardingDraftHTTPEnforcesRoleAndSessionBinding|SelfServiceSandboxHTTPRequiresDedicatedIssuerRole|CorporateDealScenarioRejectsApprovalEventMismatch)$' | internal/httpapi/corporate_onboarding_draft_test.go, internal/httpapi/self_service_sandbox_test.go, internal/httpapi/deal_scenarios_test.go | Selected current role/session and approval boundaries; not the complete production operation-to-policy matrix. |
| HTTP_AND_DOMAIN_TENANT_ISOLATION | REPOSITORY_TEST | go test ./internal/httpapi -run 'Test(ExtendedRoutesRejectTenantOutsideCredentialBinding|CorporateBoundaryScopesReadsAndMutationsToAuthenticatedOrganization|AssetLinkCreateRejectsClientSelectedSubjectAndCrossTenant)$' | internal/httpapi/extensions_test.go, internal/httpapi/corporate_test.go, internal/httpapi/assetlink_test.go | Selected public transport/domain isolation paths in the current repository. |
| POSTGRES_RLS_AND_DURABLE_ISOLATION | REPOSITORY_INTEGRATION_TEST | go test ./internal/persistence/postgresstore -run 'Test(DeveloperEvidenceDurableReplayRLSAndAppendOnlyPack|CorporateTreasuryIntegrationLifecycleReplayAndIsolation|WebhookSubscriptionDurableRestartRLSRetryAndConcurrentVerification)$' | internal/persistence/postgresstore/developer_evidence_integration_test.go, internal/persistence/postgresstore/corporate_integration_test.go, internal/persistence/postgresstore/checkout_webhook_subscription_integration_test.go | Selected PostgreSQL RLS/durable tenant paths when the integration database is available; not full production role inventory. |
| RESOURCE_ADMISSION_BACKPRESSURE_AND_DEADLINES | REPOSITORY_TEST | go test ./internal/httpapi -run 'Test(EvaluationRejectsOverloadWithoutQueueing|EvaluationDeadlineCancelsProcessor|ReadRoutesApplyControlBackpressureAndDeadline|TradingAdmissionPrecedesRequestBodyRead)$' | internal/httpapi/handler_test.go, internal/httpapi/extensions_test.go, internal/httpapi/trading_test.go | Application admission and deadlines for selected paths; not edge, distributed limiter or measured production capacity. |
| AUDIT_CHAIN_TAMPER_AND_FAILURE | REPOSITORY_TEST | go test ./internal/audit ./internal/httpapi -run 'Test(FileLogDetectsTampering|FileLogRejectsUnversionedDecision|EvaluationFailsClosedWhenAuditIsUnavailable)$' | internal/audit/filelog_test.go, internal/httpapi/handler_test.go | Local audit chaining and a selected fail-closed mutation; not external WORM/SIEM delivery or production retention. |
| WEBHOOK_SIGNATURE_REPLAY_AND_RETRY | REPOSITORY_TEST | go test ./internal/checkout -run 'Test(WebhookTamperAndReplayWindow|WebhookTestEventSignatureScenarios|WebhookRetryQuarantinesAtAttemptBudget)$' | internal/checkout/service_test.go, internal/checkout/webhook_test_event_scenarios_test.go, internal/checkout/webhook_retry_test.go | Sandbox signature/replay and retry state machines; not production endpoint egress, KMS key or worker SLO. |
| SCHEMA_AND_RECOVERY_GUARDS | REPOSITORY_TEST | go test ./internal/persistence/postgresstore -run 'Test(StoreControlScriptsFailThroughSQLRatherThanIgnoredQuitCodes|AssessSchemaCompatibilityRejectsUnverifiedContracts|StoreCheckSchemaCompatibilityFailsClosedWithoutOpenStore)$' | internal/persistence/postgresstore/store_test.go, internal/persistence/postgresstore/schema_compatibility_test.go | Control-script and schema-admission guards only; no backup, PITR, KMS/Vault or full restore exercise. |
| A15_A22_PUBLISHED_CONTRACTS | REPOSITORY_TEST | node --test tests/openapi-collections.test.mjs tests/asyncapi-event-catalog.test.mjs tests/production-kafka-design.test.mjs tests/self-service-sandbox.test.mjs tests/developer-console-routes.test.mjs tests/webhook-reference.test.mjs tests/production-iam-design.test.mjs tests/production-network-secrets-design.test.mjs tests/production-security-controls.test.mjs | website/tests/openapi-collections.test.mjs, website/tests/asyncapi-event-catalog.test.mjs, website/tests/production-kafka-design.test.mjs, website/tests/self-service-sandbox.test.mjs, website/tests/developer-console-routes.test.mjs, website/tests/webhook-reference.test.mjs, website/tests/production-iam-design.test.mjs, website/tests/production-network-secrets-design.test.mjs, website/tests/production-security-controls.test.mjs | Repository acceptance lineage and deterministic publication only; it does not close production-like or independent evidence gates. |
Нашли неточность?
Участники private repository могут предложить правку через reviewed pull request. Остальные пользователи — отправить техническое сообщение без credentials и чувствительных данных.