feat(sccm): complete end-to-end diagnostics epic - #490
Conversation
validate_card_with_inventory resolved superseded_by but ignored supersedes, so a card could name a predecessor no catalog card declares or one failing the card-id grammar. Apply the inventory rule to both edges, cover it in the deprecation test, and state the rule in the catalog doc. Refs #334
Before this change the json_string and string_array helpers and the counterpartReadyFacts expect panicked when caller-controlled JSON carried a wrong shape, so seven adjacent malformed-shape mutations crashed the validator instead of producing failure strings. Convert both helpers to return failure strings and route every call site (transaction and observation ids, finding subjectId, subject outcome fields, coverage entries, prohibited claims, same-minute update keys, coverage gap ids, manifest artifact ids, and the counterpart facts array) through the accumulated-failure path, so the entire malformed-shape class fails closed rather than only the enumerated shapes. Refs #323
Before this change the prep doc stated that CBS.log carries no ConfigMgr sourceVersion, yet the supplemental-conflict fixture shipped CBS.log with sourceVersion 5.00.TEST.0000 and the validator constrained sourceVersion to null only for the supplementalLog kind, so both null and non-null CBS values passed. Add a test proving a cbsLog artifact with a ConfigMgr sourceVersion is rejected by kind validation and by the full scenario validator, and pinning the shipped fixture value to null. Refs #323
Before this change the supplemental-conflict fixture shipped CBS.log with a ConfigMgr sourceVersion of 5.00.TEST.0000 while the prep doc states neither CBS.log nor ReportingEvents.log carries one, and the validator forced null only for the supplementalLog kind. Key the null-sourceVersion constraint on the basename-derived expected kind so both cbsLog and supplementalLog artifacts reject any ConfigMgr sourceVersion, and null the shipped CBS.log fixture value so the corpus matches the documented supplemental servicing boundary. Refs #323
Before this change the supplemental-conflict source-local CBS observation carried key null with keyConfidence none yet claimed lastSuccessfulPhase install, and its finding mirrored the claim. The prep doc requires every non-null lastSuccessfulPhase to be proven by a compatible cited complete record containing the exact key, which an unkeyed observation can never satisfy, but the validator accepted the claim. Add a test proving a null-key observation claiming lastSuccessfulPhase is rejected and pinning the shipped observation and finding values to null. Refs #323
Before this change a source-local observation with key null could carry a non-null lastSuccessfulPhase even though the corpus contract requires every non-null lastSuccessfulPhase to be proven by a cited complete record containing the exact key, which an unkeyed CBS symptom can never provide. Enforce null lastSuccessfulPhase on every keyless observation, null the supplemental-conflict observation and finding claims, and update the scenario contract so the keyed client transaction remains the only install-success result. Refs #323
Before the malformed-shape closure a scalar counterpartReadyFacts value panicked the validator at the counterpart facts expect, the same site as the object variant. The closure commit already routes every non-array counterpartReadyFacts value through the failure string path; add the scalar variant to the shape battery explicitly so object, scalar, and scalar-handoff forms are each pinned by a named mutation. Refs #323
Before this change evidence citations were only bounds-checked per tuple, so duplicating a transaction evidence citation in the success scenario, adding an overlapping updates-success-01-scan line 1-1 range beside the existing 1-2 range, and duplicating the supplemental-conflict observation citation all validated clean, double-counting the same logical CCM record for chronology and corroboration. Add a test proving each mutation is rejected, the class that blocked sibling lanes #326 and #375. Refs #323
Before this change citation validation only bounds-checked each tuple, so duplicate tuples and overlapping line ranges could cite the same logical CCM record twice within one evidence list and inflate chronology or corroboration. Expand every in-bounds cited range into (artifactId, line) identities with the same evidence_refs_cite_unique_records helper sibling lane #326 uses and fail closed inside citation_failures, closing the class for transaction, observation, finding, and counterpart citations alike. Refs #323
Convert the panic-based matrix, guard, and registry assertions into Result-returning validators so adversarial mutation probes can assert rejection without process aborts. Behavior-preserving: the six existing contract tests still pass unchanged. Refs #333
Before this change an absent or access-denied artifact could carry encoding, collectionLimit, or truncated metadata and still validate clean because artifact_provenance_projection silently nulled the fields instead of the validator rejecting them, letting noncapture artifacts retain stale physical provenance. Add a test proving each field is rejected on an absent artifact in the incomplete scenario and on the access-denied artifact, the class that blocked sibling lanes #324 and #352. Refs #323
Before this change the noncapture manifest branch only rejected relativePath and nonzero bytesCopied, so absent, access-denied, skipped, unsupported, and parse-failed artifacts could carry stale encoding, collectionLimit, or truncated metadata that the provenance projection silently nulled. Reject each physical metadata field on every noncapture capture state so stale provenance fails closed, mirroring the sibling lane #324 noncapture idiom. Refs #323
Add mutation probes proving the redaction contract inspects only serialized JSON bytes: a decoded LAB backslash marker value, an undeclared raw Windows log path, and a marker hidden in a projection key all pass because serde escaping defeats the byte containment check. Fails until the projection walk is decoded. Refs #333
Walk the expected public projection as a decoded JSON value tree: every object key and string value must fit a closed public grammar (ascii alphanumerics, dash, dot, max 96 bytes) and no decoded string may contain a declared private marker. Escaped backslash identities, raw Windows paths, and marker-shaped keys now fail. Refs #333
Before this change the malformed-shape helper probe vector used an inline tuple type that trips the clippy type_complexity gate under -D warnings. Name the probe tuple with a lifetime-parameterized type alias; behavior is unchanged. Refs #323
Before this change five constructs added during the review-fix round drifted from rustfmt layout in the updates contract test. Run rustfmt on that single changed file so the format gate passes; no behavioral change. Refs #323
Add mutation probes proving fixture refs are unconditional: the pending #329 server side accepts a merged client repo dir or a synthetic ref, a policy server slot accepts a client-side repo dir or a pending issue ref, and the registry accepts a rewritten content server issue or a dropped #329 acceptance blocker. Refs #333
Give each pair side an explicit corpus state: merged sides must cite repo dirs under their own side prefix or synthetic inputs, while the pending #329 content server side may only use issue:#329 refs or absent. Pin registry pair ownership (#322 to #329, #321 to #328, #323 to #330) and keep the #329 pending acceptance blocker declared. Refs #333
Add the review's mutation set: every guard label survives with its adversarial input neutralized (missing to exact, conflicting to exact, incompatible to compatible, mismatch and unknown to validated, invalid offset to usable, split to complete, partial to complete, unrelated to corroborating) and an absent server ref survives a complete-coverage claim. All must fail closed. Refs #333
Bind guard labels to input state in both directions: each of the thirteen guards has an exact demonstration predicate over the scenario inputs, a declared guard whose inputs were neutralized is rejected, a demonstrated guard that is undeclared is rejected, and absent fixture refs must agree with one-sided coverage. Refs #333
Require the A/B reordered scenarios to carry an ordered input evidence manifest: same multiset, B replaying A in opposite order, both sides present, identical fixture refs and input state, and one deterministic serialization and result id. Fails because the scenarios encode no reordered inputs at all. Refs #333
Give each reordered A/B scenario an orderedInputEvidence manifest of synthetic client and server evidence tokens, with B replaying A's multiset in opposite order, and admit the field in the typed scenario contract. Refs #333
…nt-corpus test(sccm): prepare Distribution Point corpus
Add mutation probes proving the validator ignores the encoded reorder evidence: B replaying A's order unchanged, a divergent B client fixture ref, an emptied A manifest under a declared reordered-input guard, and an untagged evidence token all pass. Refs #333
…ation-corpus test(sccm): prepare hierarchy and replication corpus
…ance-metering-corpus test(sccm): prepare inventory compliance metering corpus
…point-corpus test(sccm): prepare SUP and WSUS diagnostic corpus
Demonstrate the reordered-input guard by the encoded manifest: entries must be side-tagged synthetic tokens covering both sides, exactly two reordered scenarios must share identical fixture refs and input state, B must replay A's evidence in opposite order, and both must serialize one deterministic expected contract and public projection. Refs #333
Add mutation probes proving requiredOutputs are decorative: an arbitraryOutput token in the shared guard matrix, a projection reduced to a bare notCausal outcome, and a client-only scenario requesting no server artifact all pass the suite. Refs #333
feat(sccm): assess pure server intake coverage
Windows SCCM lab executor handoffFrozen candidate: Authority and privacy boundaryProceed only after the operator confirms this is an authorized development SCCM lab containing no customer data. Do not attach raw logs, hostnames, domains, site codes, user names, IPs, paths containing identities, credentials, tokens, or certificates to GitHub. Stop and report a blocker if this boundary cannot be satisfied. Bootstrap
Native acceptance matrix
Required report back on this PRPost one comment beginning
Do not mark the PR ready or merge it. Roger will review the report, synchronize the board/issues, and perform the protected landing. |
|
SCCM-LAB-RESULT: REWORK
The PR must remain draft and must not merge at this SHA. |
|
SCCM-LAB-REWORK-ACKNOWLEDGED The result is accepted as a release blocker on exact SHA Root cause: the SCCM parser/native reader contracts are present, but Rework plan: The PR remains draft. The repair is implementing:
A new provenance-bound Windows artifact and a full repeat of the authorized lab matrix are required before merge. |
|
SCCM native product-path rework is published at exact commit Local evidence gates:
Merge remains blocked pending a provenance-bound Windows artifact from this SHA and a fresh authorized SCCM lab result. The prior |
|
SCCM-LAB-RESULT: REWORK Exact candidate and artifact
Sanitized environment and reproduction
Finding: installed ConfigMgr Client is omitted
Bounded server capture results
Expected rework
Privacy statement: this is an authorized development SCCM lab with no customer data. No hostname, site code, credential, raw log content, source path, customer datum, or identifying evidence was uploaded. The PR must remain draft and must not merge on this result. |
|
RAW-LAB-EVIDENCE-INTAKE The operator has explicitly authorized transfer of raw evidence from this fresh whitebox SCCM installation to the coding staff through GitHub. A draft prerelease intake exists under tag Lab executor: package the complete existing run (raw client/server capture bundles, manifests, discovery output, application logs, artifact provenance, timestamps, and reproduction notes) into gh release upload sccm-lab-pr490-19da86e4 .\sccm-lab-pr490-19da86e4.zip .\sccm-lab-pr490-19da86e4.zip.sha256 --clobberDo not redact or synthesize the engineering asset. Keep the release in draft state. Post only the asset names and hashes back here; coding staff will pull the raw bundle with |
|
Client discovery rework is published at exact commit
A draft raw-evidence release is ready under tag |
|
SCCM-LAB-EXECUTION-READY Exact candidate: Lab executor: download artifact Raw evidence is required. Package the complete unredacted run: discovery output, client/server bundles, manifests, retained payloads, application/test logs, screenshots if useful, build provenance, timestamps, and reproduction notes. Create a ZIP and SHA-256 sidecar, then upload both to the existing draft release: gh release upload sccm-lab-pr490-6fbf1f09 .\sccm-lab-pr490-6fbf1f09.zip .\sccm-lab-pr490-6fbf1f09.zip.sha256 --clobberConfirm the release assets are downloadable with |
|
SCCM-LAB-RESULT: PASS Exact candidate and artifact
Authorized whitebox reproduction
Validation
Raw draft-release intake
Authorization/privacy statement: this is an authorized fresh whitebox development SCCM lab with no customer data. The operator explicitly authorized the complete unredacted engineering intake through the draft GitHub release. No raw evidence was placed in the PR comment itself. The PR was not marked ready and was not merged. |
|
@coderabbitai review |
|
|
FINAL-MERGE-GATE: ACCEPTED. CodeRabbit could not execute because the integrated epic changes 592 files, exceeding its 300-file limit. This is a tooling limit, not a review finding. The merge proceeds under the owner-authorized admin path based on exact-SHA staff SHIP ACCEPT, complete hosted CI/build success, authorized SCCM-LAB-RESULT: PASS, and independently replayed raw evidence with zero payload accounting discrepancies. Accepted residual risks are recorded in the PR body. |
Outcome
Completes the SCCM diagnostics epic end to end: deterministic intake, conservative evidence contracts, client/server analyzers, native Windows discovery and bounded capture, Tauri commands, and the SCCM Diagnostics workspace.
Frozen accepted target:
6fbf1f090d1ffc22a11cdfa2690da4e2ec072c66Evidence gates
30958500549: every test, analysis, Windows diagnostics, MSRV, E2E, and platform build job passed.cmtrace-open-Windows-x64ID8912448983: provenance binds to the frozen target.sccm-lab-pr490-6fbf1f09; ZIP SHA-256f46df02daeabbe53d73f98ea9782ea53bf7949ef7cca8322a633d9d0ba55e217.Lab result
The shipped workspace detected Client from exact
CcmExecservice evidence despite the Setup registry key being absent, plus Site Server, Management Point, Distribution Point, and Provider. Two native captures produced both client and server manifests.The whitebox uses a nonstandard client installation. Its fixed allow-listed
%WINDIR%\CCM\Logsroot does not exist, so the client manifest truthfully records 41 explicit absent declarations rather than deriving an untrusted path. Each server manifest records 19 captured and 8 absent declarations with retained rotation and collection-limit provenance.Accepted residual risks
Closes #317
Closes #319
Closes #320
Closes #321
Closes #322
Closes #323
Closes #324
Closes #325
Closes #326
Closes #327
Closes #328
Closes #329
Closes #330
Closes #331
Closes #332
Closes #333
Closes #334
Closes #335