Skip to main content

Analysis results and main integration

This integration merges main 851d63a (6 November 2026) into the unified analysis-results branch at 9dc7c79. The common ancestor is aa279a5. Main changed 58 files since that ancestor; the branch also contains an uncommitted frontend component separation, preserved separately from the merge.

Changes and overlap​

AreaMain changesIntegration
ExtractionFACT/unblob/sasquatch/JFFS2/vendor routing, nested extraction, rootfs selection, encrypted-image detection and signature storageKeep main's extraction pipeline unchanged. Run it once and use its summary to produce the dashboard inventory and metrics.
Extractor outputEXTRACTOR_RESULT protocol, extractor-output.json, manufacturer and timing informationPreserve the JSON contract and all summary fields, including JFFS2 counts. No second extraction or separate DB inventory.
Tool inputsShared rootfs helper for CVE, SBOM and boot analysis; whole extraction for secret searchesUse main's helper. Firmwalker and TruffleHog still inspect extra configuration partitions. Keep task-scoped SBOM reports to isolate execution history.
LogsMain uses *-output.txt; branch used *_output.txt and dashboard sidecarsNew runs use main's names, including extractor/SBOM aliases. Existing stored paths and both log patterns remain readable.
Tool statusBoot failures and SBOM exit code 1 handlingRetain branch diagnostics, timeout and dependency-skip states. Exit code 1 is accepted only with a newly generated valid SBOM. Missing extractor summaries cannot look like clean scans.
Boot resultsExpanded dependency trees, corrected primary key, longer pathsPreserve the full original result and dashboard details; store existing boot fields in the main table.
DatabaseBoot-result migration and existing result tablesJoin both migration heads with b7c42a90e615. Reuse existing tables and foreign keys. Do not copy findings into a new dashboard table.
UploadsContent-hashed paths, safe filenames, image reuse and missing-file repairKeep main's implementation, including checksum-based deduplication.
InfrastructureVersioned images, Docker log limits, extractor worker count, Redis restart, offline SQLite CVE data, public-only frontend configuration and pre-commit checksKeep main's changes. Boot's Dockerfile includes both the rootfs helper and dashboard/result helpers.

Database identity and history​

analysis_executions stores execution metadata and report paths, not findings. Its unique key ensures one record per job/image/execution/tool; repeated worker returns update that record.

Binwalk, TruffleHog, boot and CVE writes compare the stored fields within an image before inserting. The transaction first locks the image row, serializing concurrent writers even when no findings exist yet. Duplicate entries inside one report or across repeated runs are reused. Different CVE locations, secret values and boot configurations remain distinct. SBOM retains its existing unique component identity and image/component mapping.

Run-specific reports remain files, so historical dashboards do not incorrectly read the latest cumulative image results. This intentionally preserves separate execution history. No existing database records or historical duplicates are deleted by this merge.

Verification​

Verified locally:

  • 161 unit tests, including execution history and actual SQLite result storage.
  • 118 targeted MySQL/Redis integration tests, including four concurrent-writer cases.
  • Fresh SQL bootstrap followed by all migrations; ORM/schema comparison succeeds.
  • Upgrade from each previous head to the merge head, with existing records retained; a second upgrade leaves row counts unchanged.
  • Ruff, frontend ESLint, Codespell on tracked docs, and Hadolint for the affected tool/frontend Dockerfiles.
  • Production Docusaurus build, including the new integration report and sidebar.
  • Production Angular build and browser checks for all six tools, filters, history, error/timeout states, mobile layout and separate CVE dashboard navigation.

MySQL tests use disposable databases initialized with the documented init.sql bootstrap followed by Alembic migrations. The live application database is not changed. Angular reports existing bundle/style budget and CommonJS warnings.

The unit and integration suites mock scanner processes. Full extraction regression tests with FACT and downloaded firmware require the dedicated extractor CI image and are not equivalent to these checks.