Open-source AI Security Operations Center: alert fusion, LLM-agent triage, MITRE ATT&CK investigation, and a replayable decision ledger for every agent step. Self-hostable, runs with no API keys, MIT licensed. Ships an MCP server for Claude, Cursor and Continue.
Python agentic-aiai-securityalert-triageblue-teamcybersecuritydetection-engineeringincident-responselanggraphllm-agentsmcpmitre-attackmodel-context-protocolpurple-teamsecurity-operationsself-hostedsiemsoarsocthreat-detectionthreat-intelligence
Phase 2 continuation: signed/attested images + SHA-pinned actions (#424)
Beenu Arora678539bdb0ef
diff --git a/.github/workflows/build-extensions.yml b/.github/workflows/build-extensions.ymlindex c771925bc..f4a6d21c3 100644--- a/.github/workflows/build-extensions.yml+++ b/.github/workflows/build-extensions.yml@@ -26,10 +26,10 @@ jobs:working-directory: services/osquery-extensionssteps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up Go- uses: actions/setup-go@v6+ uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6with:go-version: "1.26"cache: true@@ -42,7 +42,7 @@ jobs:run: go test -race -count=1 -coverprofile=coverage.out ./...- name: Upload coverage- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: coveragepath: services/osquery-extensions/coverage.out@@ -84,10 +84,10 @@ jobs:CGO_ENABLED: "0"steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up Go- uses: actions/setup-go@v6+ uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6with:go-version: "1.26"cache: true@@ -107,7 +107,7 @@ jobs:# Sign the binary with cosign (keyless / OIDC)- name: Install cosign- uses: sigstore/cosign-installer@v3+ uses: sigstore/cosign-installer@398d4b0eeef1380460a10c8013a76f728fb906ac # v3- name: Sign artifactrun: |@@ -118,7 +118,7 @@ jobs:"${ARTIFACT}"- name: Upload to release- uses: softprops/action-gh-release@v3+ uses: softprops/action-gh-release@718ea10b132b3b2eba29c1007bb80653f286566b # v3with:files: |services/osquery-extensions/${{ env.ARTIFACT }}diff --git a/.github/workflows/check-openapi.yml b/.github/workflows/check-openapi.ymlindex 55989ed38..b3e733318 100644--- a/.github/workflows/check-openapi.yml+++ b/.github/workflows/check-openapi.yml@@ -35,10 +35,10 @@ jobs:runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up Python- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.12"cache: pip@@ -65,12 +65,12 @@ jobs:contents: writesteps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:token: ${{ secrets.GITHUB_TOKEN }}- name: Set up Python- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.12"cache: pipdiff --git a/.github/workflows/ci.yml b/.github/workflows/ci.ymlindex addab0394..b63cc58c4 100644--- a/.github/workflows/ci.yml+++ b/.github/workflows/ci.yml@@ -21,9 +21,9 @@ jobs:run:working-directory: apps/websteps:- - uses: actions/checkout@v7- - uses: pnpm/action-setup@v4- - uses: actions/setup-node@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6with:node-version: '22'cache: pnpm@@ -49,9 +49,9 @@ jobs:run:working-directory: apps/websteps:- - uses: actions/checkout@v7- - uses: pnpm/action-setup@v4- - uses: actions/setup-node@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6with:node-version: '22'cache: pnpm@@ -66,7 +66,7 @@ jobs:- run: pnpm test:cov# Upload the coverage report so the marketing site's eval-page# widget (Phase 4.3) can grab a fresh value on every main push.- - uses: actions/upload-artifact@v7+ - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7if: always()with:name: web-vitest-coverage@@ -84,9 +84,9 @@ jobs:run:working-directory: apps/websteps:- - uses: actions/checkout@v7- - uses: pnpm/action-setup@v4- - uses: actions/setup-node@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6with:node-version: '22'cache: pnpm@@ -112,16 +112,16 @@ jobs:run:working-directory: apps/websteps:- - uses: actions/checkout@v7- - uses: pnpm/action-setup@v4- - uses: actions/setup-node@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6with:node-version: '22'cache: pnpmcache-dependency-path: pnpm-lock.yaml- run: pnpm install --frozen-lockfile- run: pnpm build-storybook- - uses: actions/upload-artifact@v7+ - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: storybook-staticpath: apps/web/storybook-static@@ -139,9 +139,9 @@ jobs:name: MCP — Type-check, Test & Buildruns-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: pnpm/action-setup@v4- - uses: actions/setup-node@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6with:node-version: '22'cache: pnpm@@ -162,8 +162,8 @@ jobs:name: Python — Lint & Type-checkruns-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'- name: Install Ruff & Mypy@@ -271,8 +271,8 @@ jobs:"croniter>=2.0,<7.0"pytest pytest-asynciosteps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'cache: pip@@ -345,8 +345,8 @@ jobs:runs-on: ubuntu-latestneeds: python-lintsteps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'cache: pip@@ -442,8 +442,8 @@ jobs:- threatintel- uebasteps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'cache: pip@@ -509,8 +509,8 @@ jobs:name: SDK — Python (pytest)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'cache: pip@@ -541,9 +541,9 @@ jobs:name: SDK — TypeScript (vitest)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: pnpm/action-setup@v4- - uses: actions/setup-node@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4+ - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6with:node-version: '22'cache: pnpm@@ -567,8 +567,8 @@ jobs:matrix:service: [enrichment, ingest, demo-producer]steps:- - uses: actions/checkout@v7- - uses: actions/setup-go@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6with:go-version: '1.25'cache-dependency-path: services/${{ matrix.service }}/go.sum@@ -595,8 +595,8 @@ jobs:name: SDK — Go (build, vet, test)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: actions/setup-go@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6with:go-version: '1.25'cache-dependency-path: packages/plugin-sdk-go/go.sum@@ -643,8 +643,8 @@ jobs:permissions:contents: writesteps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'- name: Pull last published baseline from eval-results branch@@ -708,7 +708,7 @@ jobs:PY- name: Upload eval reportif: always()- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: aisoc-eval-reportpath: eval_report.json@@ -758,8 +758,8 @@ jobs:name: P2 — Playbook Schema Lintruns-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'- name: Install jsonschema@@ -774,6 +774,6 @@ jobs:name: Docker Compose — Validateruns-on: ubuntu-lateststeps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Validate compose filerun: docker compose config --quietdiff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.ymlindex 34f283b0d..3669c4b0f 100644--- a/.github/workflows/codeql.yml+++ b/.github/workflows/codeql.yml@@ -23,10 +23,10 @@ jobs:language: [javascript-typescript, python, go]steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Initialize CodeQL- uses: github/codeql-action/init@v4+ uses: github/codeql-action/init@99df26d4f13ea111d4ec1a7dddef6063f76b97e9 # v4with:languages: ${{ matrix.language }}queries: security-and-quality@@ -41,9 +41,9 @@ jobs:- 'plans/cyble-aisoc/**'- name: Autobuild- uses: github/codeql-action/autobuild@v4+ uses: github/codeql-action/autobuild@99df26d4f13ea111d4ec1a7dddef6063f76b97e9 # v4- name: Perform CodeQL Analysis- uses: github/codeql-action/analyze@v4+ uses: github/codeql-action/analyze@99df26d4f13ea111d4ec1a7dddef6063f76b97e9 # v4with:category: '/language:${{ matrix.language }}'diff --git a/.github/workflows/compose-smoke-nightly.yml b/.github/workflows/compose-smoke-nightly.ymlindex 554f621b1..826fd909a 100644--- a/.github/workflows/compose-smoke-nightly.yml+++ b/.github/workflows/compose-smoke-nightly.yml@@ -50,7 +50,7 @@ jobs:steps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Show runner capacityrun: |@@ -183,7 +183,7 @@ jobs:- name: Upload forensics artifactif: failure()- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: nightly-smoke-forensics-${{ github.run_id }}path: forensics.mddiff --git a/.github/workflows/compose-smoke.yml b/.github/workflows/compose-smoke.ymlindex b991f7c70..f7366e089 100644--- a/.github/workflows/compose-smoke.yml+++ b/.github/workflows/compose-smoke.yml@@ -87,7 +87,7 @@ jobs:steps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:# Full history so the rebuild-detection step below can resolve a# merge base against `origin/${base_ref}`. With the defaultdiff --git a/.github/workflows/cross-tenant-rbac.yml b/.github/workflows/cross-tenant-rbac.ymlindex c906888b5..1151c4198 100644--- a/.github/workflows/cross-tenant-rbac.yml+++ b/.github/workflows/cross-tenant-rbac.yml@@ -91,9 +91,9 @@ jobs:steps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- - uses: actions/setup-python@v6+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'cache: pip@@ -122,7 +122,7 @@ jobs:- name: Upload junit reportif: always()- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: tenant-isolation-junit-${{ github.run_id }}path: services/api/tenant-isolation.junit.xmldiff --git a/.github/workflows/deploy-api.yml b/.github/workflows/deploy-api.ymlindex e692102ca..2f709b2f1 100644--- a/.github/workflows/deploy-api.yml+++ b/.github/workflows/deploy-api.yml@@ -27,15 +27,15 @@ jobs:env:FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:fetch-depth: 0- name: Install flyctl- uses: superfly/flyctl-actions/setup-flyctl@master+ uses: superfly/flyctl-actions/setup-flyctl@ed8efb33836e8b2096c7fd3ba1c8afe303ebbff1 # master- name: Set up Python- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.11"diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.ymlindex 173e29db5..e3b7ddb84 100644--- a/.github/workflows/deploy-docs.yml+++ b/.github/workflows/deploy-docs.yml@@ -22,15 +22,15 @@ jobs:name: Build Docusaurusruns-on: ubuntu-lateststeps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:fetch-depth: 0- - uses: pnpm/action-setup@v3+ - uses: pnpm/action-setup@a3252b78c470c02df07e9d59298aecedc3ccdd6d # v3with:version: 9- - uses: actions/setup-node@v4+ - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4with:node-version: 20cache: pnpm@@ -42,7 +42,7 @@ jobs:run: pnpm --filter @aisoc/docs build- name: Upload artifact- uses: actions/upload-pages-artifact@v5+ uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v5with:path: apps/docs/build@@ -56,4 +56,4 @@ jobs:steps:- name: Deploy to GitHub Pagesid: deployment- uses: actions/deploy-pages@v5+ uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5diff --git a/.github/workflows/deploy-web.yml b/.github/workflows/deploy-web.ymlindex dcf53dafd..a5923a950 100644--- a/.github/workflows/deploy-web.yml+++ b/.github/workflows/deploy-web.yml@@ -26,12 +26,12 @@ jobs:env:FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:fetch-depth: 0- name: Install flyctl- uses: superfly/flyctl-actions/setup-flyctl@master+ uses: superfly/flyctl-actions/setup-flyctl@ed8efb33836e8b2096c7fd3ba1c8afe303ebbff1 # master- name: Deploy to Flyrun: |diff --git a/.github/workflows/devcontainer-build.yml b/.github/workflows/devcontainer-build.ymlindex cc05ec2bd..2a9ebbb59 100644--- a/.github/workflows/devcontainer-build.yml+++ b/.github/workflows/devcontainer-build.yml@@ -57,16 +57,16 @@ jobs:timeout-minutes: 45steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up QEMU- uses: docker/setup-qemu-action@v4+ uses: docker/setup-qemu-action@96fe6ef7f33517b61c61be40b68a1882f3264fb8 # v4- name: Set up Docker Buildx- uses: docker/setup-buildx-action@v4+ uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4- name: Log in to GHCR- uses: docker/login-action@v4+ uses: docker/login-action@af1e73f918a031802d376d3c8bbc3fe56130a9b0 # v4with:registry: ghcr.iousername: ${{ github.actor }}@@ -74,7 +74,7 @@ jobs:- name: Resolve metadataid: meta- uses: docker/metadata-action@v6+ uses: docker/metadata-action@dc802804100637a589fabce1cb79ff13a1411302 # v6with:images: ghcr.io/beenuar/aisoc-devcontainertags: |@@ -83,7 +83,7 @@ jobs:type=raw,value=weekly,enable=${{ github.event_name == 'schedule' }}- name: Build & push- uses: docker/build-push-action@v7+ uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7with:context: .devcontainerfile: .devcontainer/Dockerfilediff --git a/.github/workflows/devcontainer-coldstart.yml b/.github/workflows/devcontainer-coldstart.ymlindex 8aa25638e..1b0504b1e 100644--- a/.github/workflows/devcontainer-coldstart.yml+++ b/.github/workflows/devcontainer-coldstart.yml@@ -69,10 +69,10 @@ jobs:PHASE_TOOLCHAIN_BUDGET: '30'steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Log in to GHCR- uses: docker/login-action@v4+ uses: docker/login-action@af1e73f918a031802d376d3c8bbc3fe56130a9b0 # v4with:registry: ghcr.iousername: ${{ github.actor }}diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.ymlindex c17f54de2..bf2b4dd05 100644--- a/.github/workflows/e2e.yml+++ b/.github/workflows/e2e.yml@@ -52,7 +52,7 @@ jobs:steps:- name: Checkout repo- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Setup pnpm# Intentionally omit `version:` — the root `package.json`@@ -60,10 +60,10 @@ jobs:# picks that up automatically. Pinning `version: 9` here# would clash with the packageManager field and abort the# job with ERR_PNPM_BAD_PM_VERSION.- uses: pnpm/action-setup@v4+ uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4- name: Setup Node 22- uses: actions/setup-node@v4+ uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4with:node-version: "22"cache: "pnpm"@@ -94,7 +94,7 @@ jobs:- name: Upload Playwright reportif: always()- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: e2e-playwright-reportpath: apps/web/playwright-report@@ -102,7 +102,7 @@ jobs:- name: Upload Playwright traces / screenshotsif: failure()- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: e2e-test-resultspath: apps/web/test-resultsdiff --git a/.github/workflows/graph-schema-check.yml b/.github/workflows/graph-schema-check.ymlindex 9906835ca..b40c684c8 100644--- a/.github/workflows/graph-schema-check.yml+++ b/.github/workflows/graph-schema-check.yml@@ -36,8 +36,8 @@ jobs:name: Graph schema — Drift checkruns-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.12"cache: pipdiff --git a/.github/workflows/installer-smoke.yml b/.github/workflows/installer-smoke.ymlindex 24678c2ea..224334cb2 100644--- a/.github/workflows/installer-smoke.yml+++ b/.github/workflows/installer-smoke.yml@@ -68,7 +68,7 @@ jobs:runs-on: ubuntu-latesttimeout-minutes: 5steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: shellcheckrun: |@@ -106,7 +106,7 @@ jobs:runs-on: windows-latesttimeout-minutes: 10steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: PSScriptAnalyzershell: pwsh@@ -236,7 +236,7 @@ jobs:bootstrap: 'zypper --non-interactive install bash curl ca-certificates procps lsof iproute2 file'steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Run --diagnose in ${{ matrix.image }}run: |@@ -299,7 +299,7 @@ jobs:timeout-minutes: 10needs: lint-powershellsteps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Run -Diagnose -NonInteractiveshell: pwsh@@ -332,7 +332,7 @@ jobs:timeout-minutes: 5needs: lint-bashsteps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Refuse to nuke a non-AiSOC directoryrun: |diff --git a/.github/workflows/isolation.yml b/.github/workflows/isolation.ymlindex 187bb5a4a..c274f3c99 100644--- a/.github/workflows/isolation.yml+++ b/.github/workflows/isolation.yml@@ -23,9 +23,9 @@ jobs:runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- - uses: actions/setup-python@v6+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.12"diff --git a/.github/workflows/managed-auto-provision.yml b/.github/workflows/managed-auto-provision.ymlindex 4ca3646ce..d192ea4e7 100644--- a/.github/workflows/managed-auto-provision.yml+++ b/.github/workflows/managed-auto-provision.yml@@ -61,7 +61,7 @@ jobs:dispatch_manifest: ${{ steps.dispatch.outputs.manifest }}dispatch_action: ${{ steps.dispatch.outputs.action }}steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:fetch-depth: 2@@ -103,10 +103,10 @@ jobs:FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}FLY_ORG: ${{ vars.FLY_MANAGED_ORG || 'aisoc-managed' }}steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Install flyctl- uses: superfly/flyctl-actions/setup-flyctl@master+ uses: superfly/flyctl-actions/setup-flyctl@ed8efb33836e8b2096c7fd3ba1c8afe303ebbff1 # master- name: Install yq + envsubstrun: |@@ -138,7 +138,7 @@ jobs:FLY_ORG: ${{ vars.FLY_MANAGED_ORG || 'aisoc-managed' }}AISOC_ALLOW_DEPROVISION: ${{ vars.AISOC_ALLOW_DEPROVISION || '0' }}steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Guard rail — must opt in to destructive auto-deprovisionif: ${{ env.AISOC_ALLOW_DEPROVISION != '1' }}@@ -150,7 +150,7 @@ jobs:- name: Install flyctlif: ${{ env.AISOC_ALLOW_DEPROVISION == '1' }}- uses: superfly/flyctl-actions/setup-flyctl@master+ uses: superfly/flyctl-actions/setup-flyctl@ed8efb33836e8b2096c7fd3ba1c8afe303ebbff1 # master- name: Deprovision each removed manifestif: ${{ env.AISOC_ALLOW_DEPROVISION == '1' }}@@ -174,10 +174,10 @@ jobs:FLY_API_TOKEN: ${{ secrets.FLY_API_TOKEN }}FLY_ORG: ${{ vars.FLY_MANAGED_ORG || 'aisoc-managed' }}steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Install flyctl- uses: superfly/flyctl-actions/setup-flyctl@master+ uses: superfly/flyctl-actions/setup-flyctl@ed8efb33836e8b2096c7fd3ba1c8afe303ebbff1 # master- name: Install yq + envsubstrun: |diff --git a/.github/workflows/papers.yml b/.github/workflows/papers.ymlindex a39b25a87..db0ae7f5d 100644--- a/.github/workflows/papers.yml+++ b/.github/workflows/papers.yml@@ -45,7 +45,7 @@ jobs:name: Render every paper to PDFruns-on: ubuntu-lateststeps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:# We need full history so the auto-commit step's `git push`# has a sane base to diff against.@@ -56,7 +56,7 @@ jobs:persist-credentials: true- name: Set up Python 3.12- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.12"@@ -94,7 +94,7 @@ jobs:fi- name: Upload rendered PDFs as artifact (always)- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: papers-pdf-${{ github.sha }}path: apps/web/public/papers/*.pdfdiff --git a/.github/workflows/publish-images.yml b/.github/workflows/publish-images.ymlindex d087f2445..8d9de1bff 100644--- a/.github/workflows/publish-images.yml+++ b/.github/workflows/publish-images.yml@@ -27,6 +27,8 @@ concurrency:permissions:contents: readpackages: write+ # Keyless cosign signing + SLSA provenance attestation need an OIDC token.+ id-token: writejobs:build:@@ -90,18 +92,18 @@ jobs:dockerfile: Dockerfileimage: ghcr.io/beenuar/aisoc-slack-botsteps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- - uses: docker/setup-buildx-action@v4+ - uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4- - uses: docker/login-action@v4+ - uses: docker/login-action@af1e73f918a031802d376d3c8bbc3fe56130a9b0 # v4with:registry: ghcr.iousername: ${{ github.actor }}password: ${{ secrets.GITHUB_TOKEN }}- id: meta- uses: docker/metadata-action@v6+ uses: docker/metadata-action@dc802804100637a589fabce1cb79ff13a1411302 # v6with:images: ${{ matrix.image }}tags: |@@ -130,7 +132,8 @@ jobs:echo 'EOF'} >> "$GITHUB_OUTPUT"- - uses: docker/build-push-action@v7+ - id: build+ uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7with:context: ${{ matrix.context }}file: ${{ matrix.context }}/${{ matrix.dockerfile }}@@ -141,3 +144,36 @@ jobs:cache-from: type=gha,scope=${{ matrix.service }}cache-to: type=gha,mode=max,scope=${{ matrix.service }}platforms: linux/amd64+ # SLSA provenance + SPDX SBOM attached to the image by BuildKit.+ provenance: mode=max+ sbom: true++ # ── Supply-chain attestation (Phase 2 continuation) ──────────────────+ # 1. cosign keyless (OIDC) signature over the pushed digest.+ # 2. CycloneDX SBOM generated by syft and attached as a cosign+ # attestation, so users can `cosign verify-attestation --type+ # cyclonedx` without pulling the image.+ # Verification commands: docs/operations/verifying-releases.md.+ - uses: sigstore/cosign-installer@398d4b0eeef1380460a10c8013a76f728fb906ac # v3++ - name: Install syft+ run: |+ set -euo pipefail+ curl -sSfL https://raw.githubusercontent.com/anchore/syft/main/install.sh \+ | sh -s -- -b /usr/local/bin v1.18.1++ - name: Sign image (cosign keyless)+ env:+ DIGEST: ${{ steps.build.outputs.digest }}+ run: cosign sign --yes "${{ matrix.image }}@${DIGEST}"++ - name: Attach CycloneDX SBOM attestation+ env:+ DIGEST: ${{ steps.build.outputs.digest }}+ run: |+ set -euo pipefail+ syft "${{ matrix.image }}@${DIGEST}" -o cyclonedx-json > /tmp/sbom.cdx.json+ cosign attest --yes \+ --type cyclonedx \+ --predicate /tmp/sbom.cdx.json \+ "${{ matrix.image }}@${DIGEST}"diff --git a/.github/workflows/quarantine-tracker.yml b/.github/workflows/quarantine-tracker.ymlindex 958737a7a..76963ecac 100644--- a/.github/workflows/quarantine-tracker.yml+++ b/.github/workflows/quarantine-tracker.yml@@ -32,10 +32,10 @@ jobs:steps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up Python- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.11"diff --git a/.github/workflows/readme-gates.yml b/.github/workflows/readme-gates.ymlindex 258b98c9f..4d41c1d9d 100644--- a/.github/workflows/readme-gates.yml+++ b/.github/workflows/readme-gates.yml@@ -51,9 +51,9 @@ jobs:timeout-minutes: 10steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- - uses: actions/setup-python@v6+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.11'@@ -71,9 +71,9 @@ jobs:os: [ubuntu-latest, macos-latest]steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- - uses: actions/setup-python@v6+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.11'diff --git a/.github/workflows/release.yml b/.github/workflows/release.ymlindex b73ee6381..8fab716ac 100644--- a/.github/workflows/release.yml+++ b/.github/workflows/release.yml@@ -8,13 +8,15 @@ on:permissions:contents: writepackages: write+ # Keyless cosign signing + SLSA provenance attestation need an OIDC token.+ id-token: writejobs:release:name: Create GitHub Releaseruns-on: ubuntu-lateststeps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:fetch-depth: 0@@ -47,7 +49,7 @@ jobs:# SBOM (SPDX 2.3 JSON) so downstream users can vet what's in the# release without re-running their own scanners.- name: Generate SBOM (SPDX JSON)- uses: anchore/sbom-action@v0+ uses: anchore/sbom-action@e22c389904149dbc22b58101806040fa8d37a610 # v0with:path: .format: spdx-json@@ -69,7 +71,7 @@ jobs:cat checksums.txt- name: Create Release- uses: softprops/action-gh-release@v3+ uses: softprops/action-gh-release@718ea10b132b3b2eba29c1007bb80653f286566b # v3with:name: "AiSOC ${{ steps.version.outputs.VERSION }}"body: ${{ steps.changelog.outputs.BODY }}@@ -152,9 +154,9 @@ jobs:dockerfile: Dockerfileimage: ghcr.io/beenuar/aisoc-slack-botsteps:- - uses: actions/checkout@v7- - uses: docker/setup-buildx-action@v4- - uses: docker/login-action@v4+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4+ - uses: docker/login-action@af1e73f918a031802d376d3c8bbc3fe56130a9b0 # v4with:registry: ghcr.iousername: ${{ github.actor }}@@ -178,7 +180,8 @@ jobs:echo 'EOF'} >> "$GITHUB_OUTPUT"- - uses: docker/build-push-action@v7+ - id: build+ uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7with:context: ${{ matrix.context }}file: ${{ matrix.context }}/${{ matrix.dockerfile }}@@ -190,3 +193,33 @@ jobs:cache-from: type=gha,scope=${{ matrix.service }}cache-to: type=gha,mode=max,scope=${{ matrix.service }}platforms: linux/amd64+ # SLSA provenance + SPDX SBOM attached to the image by BuildKit.+ provenance: mode=max+ sbom: true++ # ── Supply-chain attestation (mirrors publish-images.yml) ────────────+ # Keyless cosign signature + CycloneDX SBOM attestation per released+ # image. Verification commands: docs/operations/verifying-releases.md.+ - uses: sigstore/cosign-installer@398d4b0eeef1380460a10c8013a76f728fb906ac # v3++ - name: Install syft+ run: |+ set -euo pipefail+ curl -sSfL https://raw.githubusercontent.com/anchore/syft/main/install.sh \+ | sh -s -- -b /usr/local/bin v1.18.1++ - name: Sign image (cosign keyless)+ env:+ DIGEST: ${{ steps.build.outputs.digest }}+ run: cosign sign --yes "${{ matrix.image }}@${DIGEST}"++ - name: Attach CycloneDX SBOM attestation+ env:+ DIGEST: ${{ steps.build.outputs.digest }}+ run: |+ set -euo pipefail+ syft "${{ matrix.image }}@${DIGEST}" -o cyclonedx-json > /tmp/sbom.cdx.json+ cosign attest --yes \+ --type cyclonedx \+ --predicate /tmp/sbom.cdx.json \+ "${{ matrix.image }}@${DIGEST}"diff --git a/.github/workflows/scorecard.yml b/.github/workflows/scorecard.ymlindex 451793a80..50e4ed8f6 100644--- a/.github/workflows/scorecard.yml+++ b/.github/workflows/scorecard.yml@@ -22,12 +22,12 @@ jobs:actions: readsteps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:persist-credentials: false- name: Run analysis- uses: ossf/[email protected]+ uses: ossf/scorecard-action@4eaacf0543bb3f2c246792bd56e8cdeffafb205a # v2.4.3with:results_file: results.sarifresults_format: sarif@@ -38,7 +38,7 @@ jobs:publish_results: true- name: Upload artifact- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: SARIF filepath: results.sarifdiff --git a/.github/workflows/screencast.yml b/.github/workflows/screencast.ymlindex 55fe63183..7dfb0825f 100644--- a/.github/workflows/screencast.yml+++ b/.github/workflows/screencast.yml@@ -37,15 +37,15 @@ jobs:# Hard 15-minute ceiling — a runaway recorder should fail fast.timeout-minutes: 15steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up pnpm- uses: pnpm/action-setup@v4+ uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4with:version: 9- name: Set up Node 22- uses: actions/setup-node@v4+ uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4with:node-version: 22cache: pnpm@@ -107,7 +107,7 @@ jobs:ls -lh tmp/screencast/- name: Upload screencast artifacts- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: screencast-${{ github.sha }}path: |diff --git a/.github/workflows/security-audit.yml b/.github/workflows/security-audit.ymlindex 44439e6e2..0c56ec2d1 100644--- a/.github/workflows/security-audit.yml+++ b/.github/workflows/security-audit.yml@@ -20,21 +20,21 @@ jobs:PNPM_AUDIT_REGISTRY: https://registry.npmjs.org/steps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- - uses: pnpm/action-setup@v4+ - uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4- - uses: actions/setup-node@v4+ - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4with:node-version: '22'cache: pnpmcache-dependency-path: pnpm-lock.yaml- - uses: actions/setup-python@v6+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'- - uses: actions/setup-go@v6+ - uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6with:go-version: '1.26'diff --git a/.github/workflows/security.yml b/.github/workflows/security.ymlindex af263b7c4..b29de23e6 100644--- a/.github/workflows/security.yml+++ b/.github/workflows/security.yml@@ -30,8 +30,8 @@ jobs:name: Claim-to-gate matrix (ratchet)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.12"- name: Enforce no new NO GATE rows@@ -42,7 +42,7 @@ jobs:name: Secret scan (gitleaks, observe)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Install gitleaksrun: |set -euo pipefail@@ -60,8 +60,8 @@ jobs:name: Semgrep (observe)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.12"- name: Install semgrep@@ -83,7 +83,7 @@ jobs:name: Trivy filesystem (observe)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Install & run Trivy (report-only)continue-on-error: truerun: |@@ -98,8 +98,8 @@ jobs:name: IaC scan (checkov + tfsec, observe)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: actions/setup-python@v6+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.12"- name: checkov (terraform + helm)@@ -110,6 +110,6 @@ jobs:checkov -d infra/helm --quiet --compact || true- name: tfsec (terraform)continue-on-error: true- uses: aquasecurity/[email protected]+ uses: aquasecurity/tfsec-action@b466648d6e39e7c75324f25d83891162a721f2d6 # v1.0.3with:working_directory: infra/terraformdiff --git a/.github/workflows/sync-marketplace.yml b/.github/workflows/sync-marketplace.ymlindex a7f833703..413370df2 100644--- a/.github/workflows/sync-marketplace.yml+++ b/.github/workflows/sync-marketplace.yml@@ -34,10 +34,10 @@ jobs:steps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up Python- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.11"diff --git a/.github/workflows/terraform-ci.yml b/.github/workflows/terraform-ci.ymlindex 6e83be9c5..804830cc2 100644--- a/.github/workflows/terraform-ci.yml+++ b/.github/workflows/terraform-ci.yml@@ -19,8 +19,8 @@ jobs:name: Terraform fmt -check (whole tree)runs-on: ubuntu-lateststeps:- - uses: actions/checkout@v7- - uses: hashicorp/setup-terraform@v4+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: hashicorp/setup-terraform@dfe3c3f87815947d99a8997f908cb6525fc44e9e # v4with:terraform_version: "1.15"terraform_wrapper: false@@ -39,8 +39,8 @@ jobs:run:working-directory: infra/terraform/${{ matrix.dir }}steps:- - uses: actions/checkout@v7- - uses: hashicorp/setup-terraform@v4+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7+ - uses: hashicorp/setup-terraform@dfe3c3f87815947d99a8997f908cb6525fc44e9e # v4with:terraform_version: "1.15"terraform_wrapper: falsediff --git a/.github/workflows/validate-detections.yml b/.github/workflows/validate-detections.ymlindex e2c036388..d4370524a 100644--- a/.github/workflows/validate-detections.yml+++ b/.github/workflows/validate-detections.yml@@ -18,10 +18,10 @@ jobs:steps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up Python- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.11"diff --git a/.github/workflows/validate-playbooks.yml b/.github/workflows/validate-playbooks.ymlindex f4db0f7e4..d3505ccf5 100644--- a/.github/workflows/validate-playbooks.yml+++ b/.github/workflows/validate-playbooks.yml@@ -17,10 +17,10 @@ jobs:steps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Set up Python- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: "3.11"diff --git a/.github/workflows/visual-regression.yml b/.github/workflows/visual-regression.ymlindex 788fab86c..98921e500 100644--- a/.github/workflows/visual-regression.yml+++ b/.github/workflows/visual-regression.yml@@ -66,7 +66,7 @@ jobs:steps:- name: Checkout repo- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7- name: Setup pnpm# Intentionally omit `version:` — the root `package.json`@@ -74,10 +74,10 @@ jobs:# picks that up automatically. Pinning `version: 9` here# would clash with the packageManager field and abort the# job with ERR_PNPM_BAD_PM_VERSION.- uses: pnpm/action-setup@v4+ uses: pnpm/action-setup@b906affcce14559ad1aafd4ab0e942779e9f58b1 # v4- name: Setup Node 22- uses: actions/setup-node@v4+ uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4with:node-version: "22"cache: "pnpm"@@ -136,7 +136,7 @@ jobs:- name: Upload captured baselines (first-run only)if: steps.baseline_state.outputs.have_baselines == 'false'- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: visual-baselines-seedpath: apps/web/e2e/visual/visual.spec.ts-snapshots@@ -146,7 +146,7 @@ jobs:# The HTML report carries the diff overlays the reviewers need.# `if: always()` so it ships on failures too.if: always()- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: playwright-reportpath: apps/web/playwright-report@@ -158,7 +158,7 @@ jobs:# ship the whole directory so reviewers don't have to scrub the# HTML report just to compare two pixels.if: failure()- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: playwright-test-resultspath: apps/web/test-resultsdiff --git a/.github/workflows/wet-eval.yml b/.github/workflows/wet-eval.ymlindex f4cdc7f06..f3e2785a7 100644--- a/.github/workflows/wet-eval.yml+++ b/.github/workflows/wet-eval.yml@@ -65,7 +65,7 @@ jobs:timeout-minutes: 90steps:- name: Checkout- uses: actions/checkout@v7+ uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7with:# We open a PR back to this repo, so we need a fetchable# history. Shallow is fine — the PR is created from a fresh@@ -73,7 +73,7 @@ jobs:fetch-depth: 1- name: Set up Python- uses: actions/setup-python@v6+ uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6with:python-version: '3.12'@@ -235,7 +235,7 @@ jobs:# ──────────────────────────────────────────────- name: Upload wet-eval artifactif: always() && steps.preflight.outputs.should_run == 'True'- uses: actions/upload-artifact@v7+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7with:name: wet-eval-reportpath: |diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 208f534df..9f8a3bbe8 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -9,6 +9,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0### Security+- **Phase 2 continuation — signed, attested container images + SHA-pinned CI.** Every `ghcr.io/beenuar/*` service image pushed by `publish-images.yml` (push-to-main) and `release.yml` (tags) is now: (1) signed with `cosign` keyless/OIDC, (2) attested with a CycloneDX SBOM generated by `syft` and attached via `cosign attest --type cyclonedx`, and (3) built with BuildKit `provenance: mode=max` + `sbom: true` so SLSA provenance and an SPDX SBOM ride the image manifest. Every third-party GitHub Action across all 32 workflows is pinned to a full commit SHA (tag retained as a comment) so a tag-hijack of an upstream action cannot change what CI executes. `docs/operations/verifying-releases.md` rewritten with copy-pasteable verification commands for all four artifact types. Claim-to-gate matrix: "Signed / attested release artifacts" moved PARTIAL → GATED (11 GATED / 13 PARTIAL / 3 NO GATE).+- **Phase 2 — supply chain + truth gates.** New `.github/workflows/security.yml`: a claim-to-gate matrix ratchet (`scripts/check_claim_gate_matrix.py` — the NO GATE count may only decrease; enforces the Phase 0 promise) as the HARD gate, plus gitleaks (secret), Semgrep, Trivy (fs), and checkov/tfsec in report-and-ratchet ("observe") mode with a triage allowlist at `.security/allowlist.yml` / `.gitleaksignore` (GitHub push-protection remains the always-on hard secret gate). **Insecure defaults now hard-fail the boot in production**: `enforce_secure_defaults()` (`services/api/app/core/config.py`) raises `InsecureProductionDefaultsError` when `ENVIRONMENT=production` and any placeholder secret remains, wired into `app/main.py` startup and gated by `services/api/tests/test_security_defaults.py::test_enforce_*`. Added `TRADEMARK.md` (the MIT code is free; the name is not), `docs/operations/verifying-releases.md`, a README `Maturity` note, and fixed the `.github/LICENSES.md` license inconsistency (AiSOC ships under MIT, matching `LICENSE`/README, not Apache-2.0). Claim-to-gate matrix now 10 GATED / 14 PARTIAL / 3 NO GATE. Per-image CycloneDX SBOM + cosign signing + SLSA provenance, SHA-pinning all actions, and flipping the code scanners to blocking are the tracked Phase 2 continuation.- **Phase 1.6 — platform/vault hardening (KMS envelope encryption).** New `services/api/app/security/envelope_cipher.py`: optional envelope encryption for the credential vault. Each secret is encrypted with a fresh per-secret data key (DEK); the DEK is wrapped by a key-encryption key (KEK) that never leaves KMS/HSM (`vault:v2:<kek_id>:<wrapped_dek>:<ciphertext>`), so a DB dump or a leaked env var yields only wrapped DEKs. Pluggable `KeyManager` protocol with `LocalKeyManager` (default, backward-compatible), `AwsKmsKeyManager` (boto3; GCP KMS / Vault Transit implement the same protocol), and an in-memory `FakeKmsKeyManager` for tests. Key rotation is a cheap **re-wrap** (`EnvelopeCipher.rewrap`) that never re-encrypts the secret body. Gated by `services/api/tests/test_envelope_cipher.py` (round-trip, rotation + re-wrap, plaintext-never-in-token, fail-closed on tamper/wrong-KEK). Added `docs/security/platform-threat-model.md` (STRIDE, vault as top asset) and `docs/security/connector-least-privilege.md`. Completes Phase 1.diff --git a/ROADMAP.md b/ROADMAP.mdindex fa2a6bc37..25b06e551 100644--- a/ROADMAP.md+++ b/ROADMAP.md@@ -24,7 +24,7 @@ A proof-first, security-first program to make every README claim gate-backed, cl- [x] Phase 0 — Reality audit (claim-to-gate matrix, ranked overclaims/untested-paths/circular-gates)- [x] Phase 1 — Four existential holes (prompt injection, memory poisoning, cross-store tenant isolation, data-exfiltration/redaction, cost DoS, vault)-- [x] Phase 2 — Supply chain + truth (security.yml scanners, claim-gate ratchet, hard-fail insecure prod defaults, TRADEMARK, verifying-releases, license fix; per-image SBOM/cosign/SLSA + SHA-pin = continuation)+- [x] Phase 2 — Supply chain + truth (security.yml scanners, claim-gate ratchet, hard-fail insecure prod defaults, TRADEMARK, verifying-releases, license fix; continuation landed: per-image cosign signatures + CycloneDX SBOM attestations + SLSA provenance, all actions SHA-pinned)- [ ] Phase 3 — Integration / E2E / chaos / DR (real-container spine test, backup-restore, chaos, upgrade)- [ ] Phase 4 — Real evals + detection content truth table (third-party-labeled corpus, hallucination/calibration/abstention, model matrix)- [ ] Phase 5 — Data spine correctness (schema registry, DLQ, idempotency, watermarking, backfill/replay, lineage)diff --git a/docs/audit/CLAIM_TO_GATE_MATRIX.md b/docs/audit/CLAIM_TO_GATE_MATRIX.mdindex 4031d710e..f8ebeaffe 100644--- a/docs/audit/CLAIM_TO_GATE_MATRIX.md+++ b/docs/audit/CLAIM_TO_GATE_MATRIX.md@@ -32,15 +32,15 @@ Statuses: `GATED` (a CI job fails when the claim stops being true) · `PARTIAL`| Dependency CVE scanning | (implied by security) | `security-audit.yml` | GATED | - || OpenSSF Scorecard | README badge L13 | `scorecard.yml` | GATED | - || Container image / IaC / secret scanning (Trivy/checkov/tfsec/gitleaks/Semgrep) | (implied by security) | `security.yml` (claim-matrix ratchet HARD; gitleaks/Semgrep/Trivy/checkov/tfsec observe) | PARTIAL (matrix ratchet enforced; secret + code/IaC/container scanners report-and-ratchet, allowlist at `.security/allowlist.yml` / `.gitleaksignore`; GitHub push-protection is the always-on hard secret gate) | Phase 2 |-| Signed / attested release artifacts | (implied by "run next to crown jewels") | `release.yml` (SPDX source SBOM), `build-extensions.yml` (extension cosign) | PARTIAL (images unsigned; no per-image SBOM/SLSA) | Phase 2 |+| Signed / attested release artifacts | (implied by "run next to crown jewels") | `release.yml` + `publish-images.yml` (cosign keyless signatures, CycloneDX SBOM attestation, BuildKit SLSA provenance + SPDX SBOM per image; SHA-pinned actions), `build-extensions.yml` (extension cosign) | GATED | - || Insecure defaults hard-fail in production | (implied by self-host) | `ci.yml` api tests (`test_security_defaults.py::test_enforce_*`; `enforce_secure_defaults` raises at boot in production) | GATED | - || OpenAPI stability for 3 SDKs + MCP | (implied by SDKs) | `check-openapi.yml` (drift only) | NO GATE (no breaking-change semantics) | Phase 11 |## Summary-- GATED: 10-- PARTIAL: 14-- NO GATE: 3 (Phase 2 moved insecure-defaults-hard-fail to GATED and secret/IaC/container scanning to PARTIAL; remaining NO GATE close in Phases 4/10/11)+- GATED: 11+- PARTIAL: 13+- NO GATE: 3 (Phase 2 moved insecure-defaults-hard-fail to GATED and secret/IaC/container scanning to PARTIAL; the Phase 2 continuation moved signed/attested releases to GATED; remaining NO GATE close in Phases 4/10/11)The ratchet is enforced by `scripts/check_claim_gate_matrix.py` (wired into `security.yml`): the NO GATE count may only decrease.diff --git a/docs/operations/verifying-releases.md b/docs/operations/verifying-releases.mdindex 50cfae93b..02b7dc1c9 100644--- a/docs/operations/verifying-releases.md+++ b/docs/operations/verifying-releases.md@@ -31,21 +31,43 @@ cosign verify-blob \<artifact>```-## Landing (Phase 2 continuation)+### Container image signatures (`publish-images.yml`, `release.yml`)-The following are tracked to complete the signed-and-attested supply chain for the container images (today the 12 GHCR service images are pushed unsigned):+Every `ghcr.io/beenuar/*` service image pushed to `main` or a release tag is signed with `cosign` (keyless / OIDC). Verify before running:-- **CycloneDX SBOM per image**, attached to each `ghcr.io/beenuar/*` image.-- **`cosign` image signatures** (keyless OIDC) for every service image, verifiable with:+```bash+cosign verify \+ --certificate-identity-regexp 'https://github.com/beenuar/AiSOC/.*' \+ --certificate-oidc-issuer https://token.actions.githubusercontent.com \+ ghcr.io/beenuar/aisoc-core-api:<version>+```++### Per-image CycloneDX SBOM attestation++Each image carries a CycloneDX SBOM attached as a cosign attestation (generated by `syft` at push time):++```bash+cosign verify-attestation \+ --type cyclonedx \+ --certificate-identity-regexp 'https://github.com/beenuar/AiSOC/.*' \+ --certificate-oidc-issuer https://token.actions.githubusercontent.com \+ ghcr.io/beenuar/aisoc-core-api:<version> \+ | jq -r '.payload' | base64 -d | jq '.predicate'+```++### SLSA build provenance + SPDX SBOM (BuildKit attestations)++Images are built with `provenance: mode=max` and `sbom: true`, so BuildKit attaches SLSA provenance and an SPDX SBOM directly to the image manifest:++```bash+docker buildx imagetools inspect ghcr.io/beenuar/aisoc-core-api:<version> \+ --format '{{ json .Provenance }}'+docker buildx imagetools inspect ghcr.io/beenuar/aisoc-core-api:<version> \+ --format '{{ json .SBOM }}'+```- ```bash- cosign verify \- --certificate-identity-regexp 'https://github.com/beenuar/AiSOC/.*' \- --certificate-oidc-issuer https://token.actions.githubusercontent.com \- ghcr.io/beenuar/aisoc-api:<version>- ```+### SHA-pinned GitHub Actions-- **SLSA v1 build provenance** attestation per image, verifiable with `slsa-verifier`.-- **SHA-pinned GitHub Actions** across all workflows (currently pinned by tag).+Every third-party action in `.github/workflows/` is pinned to a full commit SHA (the tag is retained as a trailing comment). A tag-hijack of an upstream action cannot change what our CI executes.-Progress and the enforcing gates are tracked in [`docs/audit/CLAIM_TO_GATE_MATRIX.md`](../audit/CLAIM_TO_GATE_MATRIX.md) and `ROADMAP.md`.+The enforcing gates are tracked in [`docs/audit/CLAIM_TO_GATE_MATRIX.md`](../audit/CLAIM_TO_GATE_MATRIX.md) and `ROADMAP.md`.