Commit Graph

27 Commits

Author SHA1 Message Date
Binh c26216a4f7 feat(comparison): Compare tab, Work Change facet and Finding Reader section (2.26.0)
Register src/features/comparison as the Comparison Engine UI path and wire its
extension points: the Engines popup entry, the Client Info Compare tab (A/B
selection, score delta over comparable sources, change counts, source table),
the Work Change facet before Source: Scan (only after the tab loaded a
comparison of the open timeslot) and a collapsed Finding Reader Compare
section with both states and the retained GPO values side by side. The engine
now carries those values. The Data Flow diagram shows the engine; product
version 2.26.0.
2026-10-13 14:13:57 +02:00
Binh c982f0a0a2 feat(comparison): register the Comparison Engine and relocate the Phase 8 scan-run comparison
Move compareScanRuns, comparison normalization and local comparison rules
unchanged to src/evaluation/scan-run-comparison so src/comparison can become
the Comparison Engine; only import paths change. Register the engine paths,
document it in AGENTS.md and onboarding, extend the boundary test and add the
permanent on/off invariance test. Record the decision and staging in the plan.
2026-10-13 11:34:10 +02:00
Binh 8d72805b27 2.25.0: integrate the rebased branch with Michael's Remediation base
- Client Info: Defender, Compliance and AI Overview move into Michael's
  ClientInfoTabs (Overview, Security, Defender, Compliance, AI Overview);
  engine tabs are lazy so hidden tabs start no requests.
- Drop the old client-info-tabs nav styles; compliance switches use the
  shared defender-tabs segmented style.
- Port the derived-forest note into client-info-facts.ts; tolerate
  observations without attributes.
- Risk register ring opens the matched record (recordId is optional for
  scoped acceptances).
- Import gate: additive synthetic Defender vulnerability and alert contracts.
  PingCastle snapshots stay unchanged pending review.
- Version 2.25.0; AGENTS engine list names the Remediation Engine.
2026-10-12 10:53:44 +02:00
Binh 682ce43c45 fix(compliance): fit Compliance tab tiles to content; mapping refresh and hit cap
Compliance tab layout (user corrections 2026-10-12):
- Overview row is only as tall as its taller tile; Mapping coverage is no longer forced square and both tiles share the row height.
- Annex A and BSI Kernel footprint cells grow with the tile up to 64px (5:3, 14px numbers); each Annex A theme column is as wide as its six cells and the columns spread across the tile. BSI requirements fill an auto-fill grid of the same cell size, also in the Show all window.
- Kernel footprint tile shows only the practice with the most findings.
- BSI Grundschutz++ framework tile shows 4 to 10 practices, as many as its square fits (container queries on the inner width).

Fixes from 2026-10-09:
- Compliance tab signals changed coverage or mapping history so Work reloads its assignments; `Mapping failed` no longer opens Work without its filter value.
- Hybrid ISO retrieval counts hits in rank order against the 8,000 character cap per control and always keeps the best hit, so large mappings no longer fail with regulatory_mapping_prompt_too_large.

Governance (Core-Freigabe: Governance): AGENTS.md BSI tile rule updated to the content-fitted practice count. Engine code only otherwise.
2026-10-12 10:38:14 +02:00
Binh be16428fbb feat(compliance): direct BSI mapping, ISO/BSI review and hybrid search
Release 2.23.0 (Phase 13F, BSI Grundschutz++ stage 2).

- Map rules directly to BSI Kernel requirements from a dedicated BSI
  corpus in Qdrant; mappings and decisions carry a framework
  (migration 029, verified backup before applying).
- Compare directly accepted BSI requirements with those derived from
  accepted ISO controls (Consistent / Inconsistent / No ISO reference)
  in a new "ISO <-> BSI review" tile in the Client Info Compliance tab,
  with Accept/Reject and "Mark reviewed" per fingerprint.
- Hybrid retrieval for ISO and BSI: German restatement of the public
  query, dense English + dense German + German BM25 fused by
  reciprocal rank; BSI skips BES/DLS/GEB/PERS and sends 16 candidates.
- ISO prompt 1.3.0 gives the model the full ISO/IEC 27002 control text
  (never sent to the browser).
- Auto-accept only the first two strong proposals (primary, high or
  medium confidence).
- Recognize Purple Knight scoped tool ids and SI indicator ids in the
  mapping query.
- Rename Result DB "Map all ISO controls" to "Compliance mapping" with
  ISO and BSI batches; "Mapping history" lists ISO and BSI runs.
- Data Hub BSI tile shows the BSI search index state and can build or
  rebuild it.
- Update AGENTS.md and the implementation plan with these decisions.
2026-10-12 10:37:59 +02:00
Binh ca66fbdef9 2.22.0: BSI Grundschutz++ derived from ISO mappings
Compliance Engine stage 1 for BSI Grundschutz++ (Kernel requirements only):
- Pinned snapshots of the BSI Kernel catalog and the official ISO 27001
  Annex A -> Grundschutz++ mapping with source URL, SHA-256 and CC BY-SA
  attribution, generated by server/compliance/update-bsi-assets.mjs.
- Requirements are derived from accepted ISO controls, never stored as
  decisions; missing mapping targets are reported.
- Client Info Compliance tab: BSI Grundschutz++ tile and Results window.
- Finding Reader: collapsed BSI requirements section grouped by ISO control.
- Work: BSI requirement and BSI practice facets.
- Data Hub: BSI catalog tile with Update from BSI and Use bundled catalog;
  new outbound target documented in SECURITY.md.
2026-10-12 10:37:39 +02:00
Binh 8649d01229 2.21.0: Client Info Compliance tab with ISO mapping history
The Compliance row moves from the Client Info Overview into its own
Compliance tab (before AI Overview). The framework tile row and its
Results button stay unchanged so later frameworks add a tile.

The tab heading carries a Last mapping button. Its window lists up to 50
mapping batches and single finding mappings of all clients, because
mappings are global per rule. Each entry shows its trigger (Automatic,
Manual, Single finding), where it came from relative to the shown
timeslot (This timeslot, Other timeslot, Other client, Unknown), status
and content-free counts. Mapping runs now record their trigger, and
single mappings their origin as SHA-256 tokens only, since runs are
exported with every client. The tab refreshes while a mapping runs and
shows the last overview at once when returning to it.

Also: history table keeps the 14px table role in every column, and the
flaky sheet-selection-cost test uses 300 instead of 2,537 sheets.

Core changes (released Presentation, Governance, Platform, Core Tests):
DashboardPanel Compliance tab, AGENTS.md decisions, product version
2.20.0 -> 2.21.0, sheet-selection-cost test.
2026-10-12 10:37:29 +02:00
Binh 5fd8f98014 2.20.0: Automatic ISO mapping of new scans and GPO imports
The Compliance Engine maps newly uploaded scans and GPO evaluations to
ISO controls while the new Data Hub switch "Map new scans automatically"
is on (default off). An engine-side watcher reads only through
ComplianceReadPort: active scan runs and, for GPOs, the deviation rows of
each timeslot as filtered Result DB pages. It starts the existing ISO
batch per new scan run or per timeslot with new GPO rows; already mapped
rules are reused, so only new rules reach the model. Existing data forms
the baseline and is not mapped retroactively.

The switch lives in the engine's own settings file, not a Core table.
Switching the Compliance Engine off in the Engines popup also switches
automatic mapping off server-wide.

Core changes (released Platform, Core Tests, Presentation, Governance):
PUT /reference-data/iso-corpus/auto-mapping route, setIsoAutoMapping API
client method, subscribeEnginePreferences export, AGENTS.md decision and
product version 2.19.1 -> 2.20.0.
2026-10-12 10:37:17 +02:00
Binh ac7c7b6283 feat(compliance): update compliance UI and logic for ISO controls
- Refactor compliance CSS to enhance layout and styling for the new Compliance row.
- Update RESULT_DB_DISCLOSURE_POLICY_VERSION to 3.8.0 for consistency across modules.
- Implement rollup logic for policy comparisons in result DB materialization.
- Enhance DashboardPanel to support theme filtering alongside control filtering.
- Introduce new ClientTileParts component for shared dashboard elements.
- Add tests for result DB materialization to ensure correct handling of GPO comparisons.
- Update existing tests to reflect changes in compliance logic and UI.
2026-10-12 10:36:31 +02:00
Binh 7185ec0e56 feat: extend Compliance Engine and ISO workflows for v2.19.0
- Move AI overview and privacy-safe JSON export into Compliance Engine
- Add ISO control and theme facets to Work, including GPO settings
- Enrich ISO queries with baseline context, Windows code meanings and technical explanations
- Count GPO settings once and preserve editable decisions across mapping runs
- Fix GPO mapping version conflicts and backup domain identity resolution
- Add regression coverage and update architecture and reimport documentation
2026-10-12 10:35:38 +02:00
Binh c5edcd9aa0 2.18.0: Compliance Engine for ISO control mapping
Extract the regulatory ISO control mapping from the Core into the
Compliance Engine (src/compliance, server/compliance, tests/compliance).

- Fix ISO mapping after the Result DB privacy merge: look up a finding's
  Result DB row scoped to its project instead of comparing a stripped
  project id.
- Engine reads the Core only through ComplianceReadPort and writes only
  its own ComplianceStore (existing migration 026 tables, own pool);
  engine writes no longer advance the Core revision.
- Engines popup gains Compliance Engine; switched off it shows nothing
  and sends no requests. Permanent on/off invariance test.
- Map ISO controls opens a window like Accepted Risk; accepted controls
  appear as an ISO controls section in the Finding Reader and as tiles
  below the Context heatmap in Client Info (drill-down into Work).
- First two proposals of a finished mapping are accepted automatically
  (provisional user decision); existing decisions are never overridden.
- Activity log names Compliance Engine work, keeps running mappings,
  batches and corpus embedding until the backend ends them, and no
  longer logs repeated status checks.
- Data Flow diagram shows the Compliance Engine.
- Core guard treats a bare engine folder name as engine path; new guard
  area test.
2026-10-12 10:34:43 +02:00
Binh 45088e9bcd feat(profiles): add Microsoft Defender for IoT Alerts profile
Adapted pick of fdd46e8: recognition, source extractor, domain model and
tool profile for Defender for IoT alert exports, the common-description
first read with its AGENTS.md rule, and the shared markdown, recognition,
status-outcome and scan-sequence changes.

Also brings forward two fixes Defender needs on this base: the title
fallback in recordTitleFor (from 210bbc0) and the Source Rule ID
exception for ID columns that are the finding title (from 21a6266).

Product version 2.12.0 for the Defender series.
2026-10-12 10:33:06 +02:00
Michael 614ac1b147 Backup 2026-10-11 03:33:25 +02:00
Michael 250c213fc1 Business Impact + Management Report 2026-10-04 19:58:04 +02:00
Michael ec0d9f2d3e Context Engine + Backup Commit - not ready yet! 2026-10-01 18:05:02 +02:00
Michael 49b2696882 docs: Phase 13E Kontext-Engine und Kontext-Layer planen
Nutzerfreigabe 2026-09-30: kuratierter, quellenbelegter Katalog,
UI-Reihenfolge und Work-Facette Kontext-Cluster. Der Kontext ist eine
parallele, abschaltbare Lesart und beeinflusst nie Verdict, Score,
Filter, Reviews oder Result DB. Kernregel in AGENTS.md aufgenommen;
offene Report-Engine-Entscheidungen im Plan vermerkt. Nur Dokumentation,
Produktversion unveraendert.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 09:22:15 +02:00
Michael 0fe283d68f 2.9.0: privacy-compliant Result DB, materialized rows and disclosure policy 3.4.0
- Result DB is checked and stored on creation (migration 024, assessor_result_db_rows)
  with a content-free per-row trace, per-client identity guard and Open original in Work
- Disclosure policy 3.4.0: review state no longer revealed via withheld-field trace,
  per-finding scanner scores withheld, CIS numbers keep all seven levels
- Less over-redaction: "Limited" is no legal form, attached versions (Tls1.2, v1.0),
  Windows 95, 2012-R2, step/option/page references, documented Microsoft GUIDs and
  documented vendor values in the recommendation field stay
- Maester first read shows the native result statement verbatim

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 14:29:52 +02:00
Michael d8f131d6da Anpassung Mitre Catalog Update 2026-09-28 09:03:24 +02:00
Michael add2aceb1d 2.8.6: reference recognition, scanner report first read and CIS section titles
Reference recognition (Phase 13D, 2.8.0-2.8.5):
- ATT&CK 19.2 / D3FEND 1.6.0 catalogs, versioned recognizer and
  append-only reference runs (migration 023), catalog references in the
  reader, Data Hub status and reprocessing, MITRE online update.

Scanner report and Work (2.8.6):
- Resolve scope-named Purple Knight runs to their profile via runNames.
- Maester "Remediation action" section as next step; PowerShell scripts
  as command blocks with display-only line layout.
- Purple Knight likelihood without the appended references section.
- CIS section titles from the run's own report in the CIS Category
  filter, Work headings and badge tooltips.
- Keep all record metadata when GPO results rebuild All Records
  (withRebuiltLayout) with a guard test for future metadata.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-26 20:12:33 +02:00
Michael a5262f19f5 neuer Goldstandart :) 2026-09-25 21:33:12 +02:00
Michael 83284c2183 Bug Fix Result DB 2026-09-23 13:53:40 +02:00
Michael cdd93fe9e8 Abtrennung zu neuem Datenmodell 2026-09-21 09:10:54 +02:00
Michael 03ea022f08 feat: add native scanner scoring and preserve client data on reimport 2026-09-10 12:41:18 +02:00
Michael dd92aa26d0 GPO Implementierung Testbereit 2026-09-06 20:54:33 +02:00
Michael a5331de771 UI Anpassung- PK + PC HTML Import implementiert
Deploy / Test, build & deploy (push) Successful in 2m3s Details
2026-08-26 08:29:00 +02:00
Michael 6cfe0c1fd5 Design Anpassungen Dashboard + Rep. PC Importer 2026-08-24 15:17:22 +02:00
Tronth c473b0c94e Initial import 2026-08-24 09:16:16 +02:00