# werewolf365/bnb26_arey_yaar_internal_round architecture

> Architecture diagram of the GitHub repository werewolf365/bnb26_arey_yaar_internal_round, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-04). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/werewolf365/bnb26_arey_yaar_internal_round
- Repository: https://github.com/werewolf365/bnb26_arey_yaar_internal_round

## Overview

Quorum verifies pinned software releases by collecting independent builder rebuild evidence, validating provenance, and evaluating it against quorum policy. Operators initiate and inspect runs through the CLI or dashboard; the API coordinates releases, evidence, jobs, and decisions, while workers report isolated rebuilds. The result is recorded in an audit chain and may be anchored on an EVM chain. The graph combines excerpted call paths with README-documented capabilities; several routes and integrations are unsampled, so undocumented links are omitted.

Main entry points: [`apps/api/internal/server/server.go`](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/api/internal/server/server.go) (REST API), [`apps/worker/main.go`](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/worker/main.go) (Worker daemon), [`internal/runner/verify.go`](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/internal/runner/verify.go) (Verification runner), [`services/policy/quorum.go`](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/policy/quorum.go) (Quorum evaluation)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_clients["Operator clients"]
  node_cli["Quorum CLI"]
  node_dashboard["Dashboard"]
  node_web_api["Dashboard API client<br/>[api.ts]"]
end

subgraph group_coordination["API coordination"]
  node_api["REST API<br/>[server.go]"]
  node_onboarding["Repository onboarding<br/>[onboard.go]"]
  node_release_store[("Release and job store")]
end

subgraph group_rebuild["Rebuild and evidence"]
  node_worker["Worker daemon<br/>[main.go]"]
  node_rebuild_engine["Isolated rebuild<br/>[rebuild.go]"]
  node_github["GitHub discovery<br/>[github.go]"]
  node_oss_rebuild["OSS Rebuild adapter<br/>[ossrebuild.go]"]
end

subgraph group_decision["Verification services"]
  node_policy["Quorum evaluation<br/>[quorum.go]"]
  node_verify_runner["Verification runner<br/>[verify.go]"]
  node_attestation["DSSE and SLSA<br/>[dsse.mjs]"]
  node_sigstore["Signing and verification<br/>[sigstore.go]"]
  node_cosign["Cosign and Rekor<br/>[cosign.go]"]
  node_trust["Trust-root governance<br/>[trust.go]"]
end

subgraph group_records["Records and anchoring"]
  node_audit["Audit hash chain<br/>[chain.mjs]"]
  node_blob_storage[("Evidence blob storage<br/>[storage.go]")]
  node_s3["S3-compatible backend<br/>[s3.go]"]
  node_anchor["EVM anchoring<br/>[blockchain.go]"]
end

node_operator(("Operator"))
node_evm(("EVM chain"))

node_operator -->|"runs commands"| node_cli
node_operator -->|"uses dashboard"| node_dashboard
node_cli -.->|"runs verification"| node_verify_runner
node_dashboard -->|"calls API client"| node_web_api
node_web_api -->|"sends REST requests"| node_api
node_api -.->|"routes onboarding"| node_onboarding
node_api -->|"reads and writes"| node_release_store
node_api -->|"evaluates evidence"| node_policy
node_api -->|"stores evidence"| node_blob_storage
node_api -.->|"appends audit"| node_audit
node_api -.->|"uses discovery"| node_github
node_worker -->|"builds source"| node_rebuild_engine
node_worker -.->|"claims and reports jobs"| node_release_store
node_worker -->|"signs provenance"| node_sigstore
node_worker -.->|"reports job results"| node_api
node_verify_runner -->|"evaluates evidence"| node_policy
node_verify_runner -.->|"verifies attestations"| node_attestation
node_attestation -->|"uses policy mirror"| node_policy
node_cosign -.->|"checks trust roots"| node_trust
node_blob_storage -.->|"selects backend"| node_s3
node_anchor -.->|"reads or anchors digest"| node_evm
node_api -->|"looks up anchor"| node_anchor
node_oss_rebuild -.->|"optional rebuild source"| node_worker

click node_cli "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/tree/main/apps/cli/cmd"
click node_dashboard "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/tree/main/apps/web/src/app"
click node_web_api "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/web/src/lib/api.ts"
click node_api "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/api/internal/server/server.go"
click node_onboarding "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/api/internal/server/onboard.go"
click node_release_store "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/tree/main/apps/api/internal/store"
click node_worker "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/worker/main.go"
click node_rebuild_engine "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/worker/internal/rebuild/rebuild.go"
click node_github "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/github/github.go"
click node_oss_rebuild "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/ossrebuild/ossrebuild.go"
click node_policy "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/policy/quorum.go"
click node_verify_runner "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/internal/runner/verify.go"
click node_attestation "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/attestation/dsse.mjs"
click node_sigstore "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/sigstore/sigstore.go"
click node_cosign "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/cosign/cosign.go"
click node_trust "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/cosign/trust.go"
click node_audit "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/audit/chain.mjs"
click node_blob_storage "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/storage/storage.go"
click node_s3 "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/storage/s3.go"
click node_anchor "https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/internal/runner/blockchain.go"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_cli,node_dashboard,node_web_api toneBlue
class node_api,node_onboarding,node_release_store toneAmber
class node_worker,node_rebuild_engine,node_github,node_oss_rebuild toneMint
class node_policy,node_verify_runner,node_attestation,node_sigstore,node_cosign,node_trust toneRose
class node_audit,node_blob_storage,node_s3,node_anchor,node_operator,node_evm toneIndigo
```

## Components

### Operator clients

- [Quorum CLI](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/tree/main/apps/cli/cmd): `apps/cli/cmd`
- [Dashboard](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/tree/main/apps/web/src/app): `apps/web/src/app`
- [Dashboard API client](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/web/src/lib/api.ts): `apps/web/src/lib/api.ts`

### API coordination

- [REST API](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/api/internal/server/server.go): `apps/api/internal/server/server.go`
- [Repository onboarding](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/api/internal/server/onboard.go): `apps/api/internal/server/onboard.go`
- [Release and job store](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/tree/main/apps/api/internal/store): `apps/api/internal/store`

### Rebuild and evidence

- [Worker daemon](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/worker/main.go): `apps/worker/main.go`
- [Isolated rebuild](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/apps/worker/internal/rebuild/rebuild.go): `apps/worker/internal/rebuild/rebuild.go`
- [GitHub discovery](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/github/github.go): `services/github/github.go`
- [OSS Rebuild adapter](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/ossrebuild/ossrebuild.go): `services/ossrebuild/ossrebuild.go`

### Verification services

- [Quorum evaluation](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/policy/quorum.go): `services/policy/quorum.go`
- [Verification runner](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/internal/runner/verify.go): `internal/runner/verify.go`
- [DSSE and SLSA](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/attestation/dsse.mjs): `services/attestation/dsse.mjs`
- [Signing and verification](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/sigstore/sigstore.go): `services/sigstore/sigstore.go`
- [Cosign and Rekor](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/cosign/cosign.go): `services/cosign/cosign.go`
- [Trust-root governance](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/cosign/trust.go): `services/cosign/trust.go`

### Records and anchoring

- [Audit hash chain](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/audit/chain.mjs): `services/audit/chain.mjs`
- [Evidence blob storage](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/storage/storage.go): `services/storage/storage.go`
- [S3-compatible backend](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/services/storage/s3.go): `services/storage/s3.go`
- [EVM anchoring](https://github.com/werewolf365/bnb26_arey_yaar_internal_round/blob/main/internal/runner/blockchain.go): `internal/runner/blockchain.go`

### Other components

- **Operator**
- **EVM chain**

## Connections

- Operator → Quorum CLI: runs commands
- Operator → Dashboard: uses dashboard
- Quorum CLI → Verification runner: runs verification
- Dashboard → Dashboard API client: calls API client (evidence: `apps/web/src/app/onboard/page.tsx`)
- Dashboard API client → REST API: sends REST requests (evidence: `apps/web/src/lib/api.ts`)
- REST API → Repository onboarding: routes onboarding
- REST API → Release and job store: reads and writes (evidence: `apps/api/internal/server/server.go`)
- REST API → Quorum evaluation: evaluates evidence (evidence: `apps/api/internal/server/server.go`)
- REST API → Evidence blob storage: stores evidence (evidence: `apps/api/internal/server/server.go`)
- REST API → Audit hash chain: appends audit
- REST API → GitHub discovery: uses discovery
- Worker daemon → Isolated rebuild: builds source (evidence: `apps/worker/main.go`)
- Worker daemon → Release and job store: claims and reports jobs
- Worker daemon → Signing and verification: signs provenance (evidence: `apps/worker/main.go`)
- Worker daemon → REST API: reports job results
- Verification runner → Quorum evaluation: evaluates evidence (evidence: `internal/runner/verify.go`)
- Verification runner → DSSE and SLSA: verifies attestations
- DSSE and SLSA → Quorum evaluation: uses policy mirror (evidence: `services/attestation/dsse.mjs`)
- Cosign and Rekor → Trust-root governance: checks trust roots
- Evidence blob storage → S3-compatible backend: selects backend
- EVM anchoring → EVM chain: reads or anchors digest
- REST API → EVM anchoring: looks up anchor (evidence: `apps/api/internal/server/server.go`)
- OSS Rebuild adapter → Worker daemon: optional rebuild source
