docs(openspec): record executable-to-package ownership decision for exposure intelligence #5921
All Vouch review confidence checks passed
Residual risk 0.46 = Change Risk (0.52) × (1 − Review Confidence (0.13)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.52 · 650 lines diff across 8 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 13% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.388
Shallow Review Depth
shallow_review_depth
0.344
Real PR Conversation Timeline
1 comments
"Review active on #5921"
general
weight: 0.35
copilot-pull-request-reviewer[bot]
Intent
Documentation-only OpenSpec change for issue #5752 (prerequisite gate 0.3 of add-srql-exposure-intelligence). The approved requirement "Running Executables Resolve To Owning Packages" left two decisions open: the privilege model (netprobe drops to an unprivileged user and cannot read /proc/<pid>/exe of other users' processes) and the wire schema of the package reference. This change records the product owner's and coordinator's decisions as Decision 18 in design.md: netprobe keeps only CAP_SYS_PTRACE (permitted+effective, nothing ambient) after the drop; it resolves an executable to its owning package by comparing (dev, inode) of package-listed paths resolved inside the process root (dpkg, apk, rpm sqlite; rpm BerkeleyDB/NDB reported UNSUPPORTED_DB), cached per inode; it emits a shared ExecutableOwnership proto message with a resolution state, the EndpointPackageAssessmentIdentity fields, installed version and provenance, attached to FlowAttributionEvent/ProcessSnapshotEntry until #5738 moves it onto leases and summaries; core derives the pkgid key by matching to the device's current inventory package. The endpoint-software-inventory spec delta is tightened to match, with new scenarios for replaced binaries and unsupported rpm databases. Proof:
openspec validate add-srql-exposure-intelligence --strictreports the change valid. No code changes. Test step note: no local builds or databases; quick checks only.Review history: an earlier gate run of this branch went through four review rounds whose fixes are the four no-mistakes(review) commits on this branch (owner decisions on placement, disjoint and total states, identity fill rules mirroring the live ScaLibr producer with ecosystem empty, per-(root, dev, inode) cache entries, blank-as-absent key hashing, directory-symlink-only following); that run then failed only because the reviewer process hit "No space left on device". Already-decided points: the closed
detailvocabulary stays (the coordinator required unsupported databases to be reported with a reason).What Changed
add-srql-exposure-intelligence/design.md. It records the outcome of #5752's two open questions. On privilege: after the drop, netprobe keeps onlyCAP_SYS_PTRACE, in the permitted and effective sets, on one dedicated resolution thread. On wire schema: a sharedExecutableOwnershipmessage carries a resolution state and the package identity, version and provenance. The decision also fixes how resolution works. Netprobe matches(dev, inode)against package-listed paths read inside the process root: dpkg, apk and rpm sqlite are supported, and rpm BerkeleyDB/NDB is reported asUNSUPPORTED_DB. Results are cached per (root, dev, inode). The five states are ordered and total. Core derives the package key from the device's current inventory.endpoint-software-inventoryspec delta to match. Until #5738 moves the reference onto lease owner records and connection summary rows, it is attached toFlowAttributionEventandProcessSnapshotEntry. New scenarios cover the lease/summary carry-over,NOT_FOUNDfor unowned executables,UNKNOWNfor a replaced binary, andUNSUPPORTED_DBfor a BerkeleyDB rpm host.tasks.mdso they name the message types that carryExecutableOwnershipnow and after #5738.🤖 Generated with Claude Code
Risk Assessment
✅ Low: The deleted-executable cache bypass is stated the same way in the cost paragraph, the requirement, and the per-inode scenario, and it agrees with the UNKNOWN state that names no package.
Testing
The baseline
test -f .bazelrc.remotehad already passed. The diff touches only three OpenSpec Markdown files.openspec validate add-srql-exposure-intelligence --strictreported "Change 'add-srql-exposure-intelligence' is valid". A grep for non-ASCII bytes in the changed design and spec files found none. The spec delta includes the new replaced-binary and unsupported-package-database scenarios, and design.md contains Decision 18. No live scenario can be driven because nothing in the product changes at runtime, and per the intent no builds or databases were run.| Scenario | Result | Live | Evidence |
| --- | --- | --- | --- |
| OpenSpec change validates in strict mode | ⏸️ untested | no | Docs-only change, so there is no runtime product surface to drive. The strict validation passed, but it checks the spec documents and does not exercise the product. |
| netprobe resolves running executables to owning packages per Decision 18 | ⏸️ untested | no | This change only records the design and spec. The netprobe and core implementation are on other branches and PRs (#5914/#5919), so this change has nothing to drive live. |
<details>
<summary>Evidence: openspec strict validation</summary>
Change 'add-srql-exposure-intelligence' is valid</details>
Pipeline
Updates from git push no-mistakes
<!-- no-mistakes-pipeline-attestation:v1 {"head_sha":"23da0e8fe560b38744087c5d65c7466d6df84f55","steps":[{"step":"intent","status":"completed"},{"step":"rebase","status":"completed"},{"step":"review","status":"completed"},{"step":"test","status":"completed"},{"step":"document","status":"completed"},{"step":"lint","status":"completed"},{"step":"gate.lint.test-registration","status":"completed"},{"step":"gate.lint.elixir-quality","status":"completed"},{"step":"push","status":"completed"},{"step":"pr","status":"running"},{"step":"ci","status":"pending"}],"live_validation":{"verdict":"no-surface","live":0,"total":2}} -->
<details>
<summary>✅ Intent - passed</summary>
✅ No issues found.
</details>
<details>
<summary>✅ Rebase - passed</summary>
✅ No issues found.
</details>
<details>
<summary>🔧 Review - 1 issue found → auto-fixed ✅</summary>
openspec/changes/add-srql-exposure-intelligence/design.md:777- Round 3's cache-validity fix left this sibling of the deleted-executable rule. A cache entry stays valid while mtime, size, and package-database state are unchanged (design.md:777-779, spec.md:46, and the per-inode scenario GIVEN at spec.md:59). The state order then says a kernel deleted mark is UNKNOWN and names no package (design.md:787-790, spec.md:46, replaced-binary scenario at spec.md:68-71). Unlink does not change those three inputs. Concrete sequence: sshd inode 100 is resolved and cached as RESOLVED to openssh-server; the binary is then unlinked (admin rm, or dpkg's rename before status and the info-directory fingerprint change) so /proc/<pid>/exe gains the kernel deleted suffix while mtime, size, and the package database are unchanged. The cache rule returns the cached RESOLVED reference and still names the package; the state order for that same input is UNKNOWN and names no package. The same skip turns a cached NOT_FOUND into a lie after a later unlink. Invalidate when the deleted mark changes (do not serve a linked-file entry for a later deleted read), and narrow the per-inode scenario so "at most once" applies only while that mark is unchanged too.🔧 Fix applied.
✅ Re-checked - no issues remain.
</details>
<details>
<summary>⚠️ Test - 1 warning</summary>
| Scenario | Result | Live | Evidence |
| --- | --- | --- | --- |
| OpenSpec change validates in strict mode | ⏸️ untested | no | Docs-only change, so there is no runtime product surface to drive. The strict validation passed, but it checks the spec documents and does not exercise the product. |
| netprobe resolves running executables to owning packages per Decision 18 | ⏸️ untested | no | This change only records the design and spec. The netprobe and core implementation are on other branches and PRs (#5914/#5919), so this change has nothing to drive live. |
test -f .bazelrc.remotegit diff --stat 1fa2b23..23da0e8(confirms only the 3 openspec Markdown files changed)</code>openspec validate add-srql-exposure-intelligence --strict(valid)</code>LC_ALL=C grep -nP '[^\x00-\x7F]'on design.md and spec.md (no non-ASCII)</code>grep '#### Scenario'on the spec delta (replaced-binary and unsupported-DB scenarios present)</code></details>
<details>
<summary>✅ Document - passed</summary>
✅ No issues found.
</details>
<details>
<summary>✅ Lint - passed</summary>
✅ No issues found.
</details>
<details>
<summary>✅ gate.lint.test-registration - passed</summary>
✅ No issues found.
</details>
<details>
<summary>✅ gate.lint.elixir-quality - passed</summary>
✅ No issues found.
</details>
<details>
<summary>✅ Push - passed</summary>
✅ No issues found.
</details>