Files
AiSOC/apps/docs/sidebars.ts
T
Beenu Arora 73036c9b57 feat(lake): archive tier, rehydration, portability and scoped legal holds (WS2) (#2007)
## What

WS2 of the gap-closure program: the long-term security data lake. The
lake's 400-day TTL is a hard ceiling nothing exempts — everything older
exists only if it was exported first. This PR makes that export real,
verified, rehydratable and portable, and narrows legal holds to their
own rows.

## WS2.1 — Archive tier (migration 170)

Closed `(tenant, month)` partitions export to the tenant's **own
S3-compatible bucket** as Parquet with a **signed manifest** (row count,
event-time bounds, schema + OCSF version, per-file SHA-256; the
evidence-bundle signer). Design decisions that carry the honesty:

- **The database that owns the rows writes the files**: export, count
re-read and SHA-256 all run *inside ClickHouse* (`INSERT INTO FUNCTION
s3(...) Parquet`, `s3(...,'Parquet')`, `s3(...,'RawBLOB')`) — no second
data path whose row semantics could drift.
- **"Exported" is a claim; "verified" means the bucket was read back and
matched.** A corrupted object fails naming what differed — including the
sharp case a count check cannot see: a *valid* Parquet with the same
rows and different bytes, caught by the checksum leg alone (proven live,
and pinned by the negative control).
- An **open month is refused** (it is still receiving rows — the
connector-window lesson applied to archival). UUID/IP columns export as
strings (ClickHouse cannot write UUID to Parquet; found live, Code 50).
- Per-tenant policy, **default off**; bucket credentials
vault-encrypted, decrypted at export time; ClickHouse masks `s3()`
credential positions in its query log (documented reliance). **WORM** is
recorded as *declared by operator, not verified by this service* — never
implied verified.
- Hourly sweep worker (`lake_archive_sweep`) exports closed months for
opted-in tenants, verifies, and expires rehydrations; bounded per tick.

## WS2.2 — Rehydration (migration 171)

**Estimate first** (bytes/files/months from the manifests; retrieval
cost **null unless `AISOC_ARCHIVE_RETRIEVAL_PRICE_PER_GB` is
configured** — never an invented figure), then an audited load
(**requester + reason required**) into an expiring scratch table
`aisoc.rehydrated_<8hex>`. The lake explorer queries it through its own
rewriter: the allowlist gained a **regex-pinned arm** that cannot widen
(non-hex/overlong/foreign-schema names refused) and injects the same
tenant predicate `raw_events` gets — live-proven: owner reads 3 rows,
another tenant reads 0. The loader **evicts foreign-tenant rows after
landing** because a bucket is not a tenancy boundary. (ClickHouse 23.8's
Parquet pushdown cannot compare file-schema strings with UUID hints in
either direction — Code 169, found live — so tenancy is enforced
post-landing by mutation, not by pushdown.)

## WS2.3 — Portability (migration 171)

Range export to a bucket **the tenant names** (per-request credentials,
never persisted): one Parquet object per month + signed manifest +
schema document. The gate proves "no AiSOC code": **DuckDB** opens the
object over s3 and its count matches the signed manifest.

## WS2.4 — Scoped legal holds (migration 172)

Holds gain `covers_from`/`covers_until`. A `user`/`host`/`ip` hold now
**exempts exactly its own rows** from the retention purge — the Postgres
alert DELETE through the affected-* arrays, the ClickHouse mutation
through user/hostname/IP columns (addresses compared as addresses:
`toIPv6OrDefault`, because IPv6 columns render v4 mapped), each within
the hold's window, **every value a bind**. The rest of the tenant purges
on schedule. This deliberately supersedes the recorded whole-tenant
freeze — the superseded test now pins the narrowing — while a
tenant-wide hold still freezes everything, because that is what it
means. The lake TTL stays untouchable: a hold older than 400 days is
only satisfiable through the archive tier, and the new **retention
attestation** (`GET /lake/retention-attestation`) says so — each tier
from its own store, "not measured" where a store cannot answer.

## Testing

- **`tests/isolation/test_lake_archive_live.py` — 9 cases on real
ClickHouse 23.8 + MinIO + Postgres** (new `integration.yml` step
provisions all three; no-skip guard): export→manifest→verify green path;
open-month refusal; garbage corruption fails; **same-count content swap
caught by checksum alone**; rehydration lands tenant-scoped and
explorer-queryable; estimate honesty; DuckDB portability; **held rows
survive the live purge (5→3) while unheld rows delete**; attestation
from real stores.
- `services/api/tests/test_lake_archive.py` — 20 unit cases
(paths/windows, destination refusals, cost honesty both ways,
scratch-table namespace pinning, explorer-arm cannot widen,
hold-exemption composers never interpolate a value, IPv6-as-address,
`covers()` window semantics).
- Full API suite **5,577 passed**; lake_sql + retention suites green
with the superseded freeze test rewritten to pin the narrowing.

**Negative controls (applied, observed failing, restored):**
1. Disabling the SHA-256 comparison →
`test_a_same_count_content_swap_is_caught_by_the_checksum_alone` fails
(the count leg cannot see it).
2. Removing the exemption composition from the alerts purge → the live
hold test fails at 5 ≠ 3 (held rows purged).

## Gates

route_auth OK · route_tenant_scope OK · tenant_query_predicates OK
(ratchet 80 → **85**, five sweep statements recorded with the
approval_expiry/sessions enumeration shapes) · module_reachability OK ·
migration_numbering OK (170–172, allocated block) · ORM parity OK · mypy
baseline OK (which caught real API mismatches: `emit_audit` signature,
`CredentialVault` construction — fixed, not ignored) · ruff clean ·
claim matrix **+3 GATED rows, 410 — 401/9/0** recomputed by the script ·
readme_gates OK · OpenAPI regenerated (additive) · README's "not a SIEM
replacement" sentence updated to the proven scope · new ops doc
`operations/lake-archive` in the sidebar.

## Could not verify

- GCS/Azure arms: the client interface is S3-compatible-first; GCS
interop/Azure need their own arms (stated in docs, not claimed).
- WORM/Object-Lock: bucket properties this service does not manage;
recorded as a declaration and reported as such, never as verified.
- The sweep worker's scheduling is wired through the same guarded-lease
path as the other workers but was exercised via `run_once` in the live
suite, not through a multi-hour soak.
2026-11-23 02:39:38 -08:00

310 lines
9.0 KiB
TypeScript

import type { SidebarsConfig } from "@docusaurus/plugin-content-docs";
const sidebars: SidebarsConfig = {
docsSidebar: [
{
type: "category",
label: "Getting Started",
items: [
"intro",
"installation",
"quickstart",
"architecture",
"benchmark",
"benchmark-methodology",
"benchmark-scoreboard",
"evaluation/replay",
],
},
{
type: "category",
label: "Core Concepts",
items: [
"concepts/capabilities",
"concepts/multi-tenancy",
"concepts/cases",
"concepts/playbooks",
"concepts/detections",
"concepts/python-detections",
"concepts/windowed-detections",
"concepts/ai-estate",
"concepts/ai-estate-discovery",
"concepts/groundedness",
"concepts/real-vs-synthetic",
"concepts/live-actions",
"concepts/retro-hunts",
"concepts/hunting-agent",
"concepts/scheduled-hunts",
"concepts/automation-maturity",
"concepts/self-play",
"concepts/investigation-swarm",
"concepts/compounding-memory",
"concepts/model-router",
"concepts/llmops",
],
},
{
type: "category",
label: "Features",
items: [
"features/connector-health",
"features/data-pipeline",
"features/attack-path-agent",
],
},
{
type: "category",
label: "Console",
items: [
"console/getting-started",
"console/funnel-kpis",
"console/queue",
"console/rule-library",
"console/rule-tuning",
"console/investigation-rail",
"console/public-replay",
"console/tenant-skills",
"console/triage-context",
"console/users-administration",
],
},
{
type: "category",
label: "Architecture",
items: [
"architecture/overview",
"architecture/agents",
"architecture/graph-schema",
"architecture/itsm-as-source-of-truth",
],
},
{
type: "category",
label: "Connectors",
items: [
// BEGIN GENERATED CONNECTOR LIST
"connectors/index",
"connectors/hello-connector",
"connectors/endpoint-decision-matrix",
"connectors/api-coverage",
"connectors/universal-capture",
"connectors/syslog-listener",
"connectors/otlp-logs",
"connectors/kafka-input",
"connectors/osquery-extensions",
"connectors/agentmetry",
"connectors/abnormal_security",
"connectors/ai-gateway",
"connectors/auditd",
"connectors/auth0",
"connectors/aws-cloudtrail",
"connectors/aws-cloudtrail-s3",
"connectors/aws-guardduty",
"connectors/aws-security-hub",
"connectors/aws-vpc-flow",
"connectors/azure-activity",
"connectors/azure-defender",
"connectors/azure-entra",
"connectors/azure-event-hubs",
"connectors/bamboohr",
"connectors/box",
"connectors/carbon-black",
"connectors/chronicle",
"connectors/cisco-secure-endpoint",
"connectors/cisco-umbrella",
"connectors/cloudflare",
"connectors/cloudflare-zt",
"connectors/confluence-audit",
"connectors/cortex-xdr",
"connectors/cortex-xsiam",
"connectors/crowdstrike",
"connectors/darktrace",
"connectors/datadog",
"connectors/datadog-cloud-siem",
"connectors/devo",
"connectors/dropbox",
"connectors/duo-security",
"connectors/elastic",
"connectors/email-inbox",
"connectors/eset-protect",
"connectors/exabeam",
"connectors/extrahop",
"connectors/falco",
"connectors/fleetdm",
"connectors/gcp-cloud-audit",
"connectors/gcp-pubsub",
"connectors/gcp-scc",
"connectors/github",
"connectors/gitlab",
"connectors/google-workspace",
"connectors/greynoise",
"connectors/huntress",
"connectors/imperva",
"connectors/jira",
"connectors/jumpcloud",
"connectors/kubernetes-audit",
"connectors/lacework",
"connectors/llm_usage",
"connectors/m365-audit",
"connectors/microsoft-intune",
"connectors/microsoft-sentinel",
"connectors/mimecast",
"connectors/netskope",
"connectors/oci",
"connectors/okta",
"connectors/onepassword",
"connectors/opsgenie",
"connectors/orca",
"connectors/osctrl",
"connectors/pagerduty",
"connectors/prisma-cloud",
"connectors/proofpoint",
"connectors/qradar",
"connectors/qualys",
"connectors/rapid7-insightidr",
"connectors/rippling",
"connectors/salesforce",
"connectors/securonix",
"connectors/sentinelone",
"connectors/servicenow",
"connectors/slack-audit",
"connectors/snowflake",
"connectors/snyk",
"connectors/sophos-central",
"connectors/splunk",
"connectors/sublime_security",
"connectors/sumo-logic",
"connectors/sysdig",
"connectors/syslog_cef",
"connectors/tailscale",
"connectors/tenable-io",
"connectors/tines",
"connectors/torq",
"connectors/trellix-helix",
"connectors/trend-vision-one",
"connectors/vault",
"connectors/vectra-ai",
"connectors/wazuh",
"connectors/windows_event",
"connectors/withsecure-elements",
"connectors/wiz",
"connectors/zeek_suricata",
"connectors/zscaler",
// END GENERATED CONNECTOR LIST
// Outside the markers on purpose: generate_connector_docs.py rewrites
// everything between them from the connector registry, so an overview
// page that is not a connector is silently dropped if it sits inside.
"connectors/cloud-security-depth",
],
},
{
type: "category",
label: "Detections",
items: ["detections/coverage", "detections/hello-hunt"],
},
{
type: "category",
label: "Benchmarks",
items: ["benchmarks/alert-reduction", "benchmarks/retro-hunt-scale"],
},
{
type: "category",
label: "Operations",
items: [
"operations/security",
"operations/enterprise-sso",
"operations/console-mfa",
"operations/data-governance",
"operations/cold-tier-queries",
"compliance/evidence-pack",
"compliance/fips-posture",
"operations/credentials",
"operations/lake-archive",
"operations/where-the-model-runs",
"operations/secrets",
"operations/scim",
"operations/case-orchestration",
"operations/alert-prioritisation",
"operations/detection-lifecycle",
"operations/taxii-server",
"operations/white-label",
"operations/usage-metering",
"operations/ingest-authentication",
"operations/ip-classification",
"operations/airgap",
"operations/air-gapped",
"operations/sandbox-providers",
"operations/mailbox-remediation",
"operations/llm-gateway",
"operations/llm-cost",
"operations/mcp-client",
"operations/codespaces",
"operations/theming",
"operations/ha-deployment",
"operations/backup-and-restore",
"operations/performance",
"operations/release-policy",
"operations/upgrades",
"operations/notifications",
"operations/action-approvals",
"operations/agent-vendor-tools",
"operations/shadow-mode",
"operations/case-reports",
"operations/troubleshooting",
"operations/faq",
"operations/adoption-questions",
"operations/managed-instance",
],
},
{
type: "category",
label: "Migrating to AiSOC",
items: ["migration/from-splunk"],
},
{
type: "category",
label: "Plugin SDK",
items: [
"plugins/overview",
"plugins/python-sdk",
"plugins/hello-plugin",
"plugins/go-sdk",
"plugins/publishing",
"plugins/cli",
"plugins/lifecycle",
],
},
{
type: "category",
label: "Integrations",
items: ["integrations/mcp", "integrations/siem-writeback", "integrations/misp-push", "integrations/github-action"],
},
{
type: "category",
label: "API Reference",
items: ["api/rest", "api/graphql", "api/websocket"],
},
{
type: "category",
label: "Deployment",
items: [
"deployment/docker",
"deployment/walkthrough",
"deployment/single-host",
"deployment/kubernetes",
"deployment/gcp",
"deployment/azure",
"deployment/env-vars",
],
},
{
type: "category",
label: "Contributing",
items: ["contributing/dev-setup", "contributing/guidelines", "contributing/reproducible-builds"],
},
"glossary",
],
};
export default sidebars;