Skip to content

🐛 [fix] (packaging) Remove Squirrel from Windows releases - #211

Merged
Nick2bad4u merged 3 commits into
mainfrom
fix/remove-squirrel-packaging
Sep 3, 2026
Merged

Nick2bad4u merged 3 commits into
mainfrom
fix/remove-squirrel-packaging

Conversation

@Nick2bad4u

Copy link
Copy Markdown
Owner

What changed

  • Remove the Squirrel.Windows build target, release upload path, asset-renaming helper, direct dependency, tests, and current documentation references.
  • Keep NSIS as the supported Windows auto-update path alongside MSI, portable, and archive builds.
  • Fail packaged smoke tests if a Squirrel-named file/directory or *_ExecutionStub.exe leaks into release output.
  • Refresh compatible app/docs dependencies, Node 26.7.0, and npm 12.0.2 while pinning the lint/format versions that remain compatible with this repository.
  • Replace extract-zip with guarded yauzl extraction and make the audit exception fail closed.

Why

Discussion #208 reported antivirus detections on the Windows download. Artifact-level checks isolated the strongest trigger to Squirrel's ExecutionStub.exe, even though FitFileViewer updates through NSIS/electron-updater and the Squirrel release assets had almost no usage. Removing that unused packaging path also prevents the helper from contaminating shared Windows staging output used by the other targets.

The release will still be unsigned because no Windows signing credential is configured. This should remove the concrete Squirrel false-positive source, but it cannot guarantee that reputation-based scanners or SmartScreen will stop warning.

Validation

  • npm run release:verify
    • 720 Vitest files / 6,074 tests passed
    • TypeDoc + Docusaurus production build passed (4,721 documents)
    • root audit: 0 vulnerabilities
    • docs audit: only the two exact unpatched image-size advisories accepted by the gate
    • Electron Playwright: 13/13 passed
    • unsigned package + packaged startup smoke passed
  • Clean Windows x64 matrix built MSI, ZIP/7z/tar archives, NSIS, NSIS-web, and portable outputs.
  • All installer/archive listings contained zero Squirrel or ExecutionStub entries.
  • Microsoft Defender custom scan of the clean release-dist tree: no threats, exit code 0.
  • actionlint and git diff --check passed.
  • Commit signature verified with git verify-commit.

Release plan

After CI and review pass, merge this PR and dispatch the standard Build workflow as a patch release (v30.0.2) with signing explicitly not required. Then verify the published asset inventory and scan the exact release artifacts before following up in Discussion #208.

🐛 [fix] Remove the Squirrel target, release upload path, asset renamer, package dependency, and current documentation references.
 - Keep NSIS as the supported auto-update installer and preserve MSI, portable, and archive targets.

🛡️ [fix] Reject Squirrel-named artifacts and ExecutionStub helpers before packaged-app smoke launches.
 - Fail closed on malformed npm audit responses and allow only the two known unpatched Docusaurus image-size advisory cascades.

🔒️ [fix] Replace extract-zip with traversal- and symlink-safe yauzl extraction for Electron downloads.

⬆️ [build] Refresh compatible root and Docusaurus dependencies, Node 26.7.0, and npm 12.0.2.
 - Pin the known-compatible lint and formatting toolchain instead of accepting the breaking shared-config major.
 - Explicitly deny the transitive electron-winstaller install script under npm 12.

🧪 [test] Add packaging, extraction, audit, and workflow regression coverage.

📝 [docs] Align installation, release, development, and dependency inventories with the supported artifact set.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 3, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-03T03:11:06.966154Z 86c40bc New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Greetings, thanks for opening a pull request, I'll look when I can.

@socket-security

socket-security Bot commented Sep 3, 2026 •

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updated@​garmin/​fitsdk@​21.208.0 ⏵ 21.214.099 +14100100 +194 +160
Updatedmakensis@​3.0.5 ⏵ 3.0.66810096 -288 +1100
Updatedelectron-builder@​26.15.3 ⏵ 26.16.0991006995100
Updated@​docusaurus/​module-type-aliases@​3.10.1 ⏵ 3.10.210010069 +198 +5100
Updatedgitleaks-config-nick2bad4u@​1.0.4 ⏵ 1.0.570 +31009190100
Updated@​docusaurus/​preset-classic@​3.10.1 ⏵ 3.10.29910070 +195 +3100
Updatedncu-config-nick2bad4u@​0.2.0 ⏵ 0.2.17210010090 +2100
Updated@​docusaurus/​types@​3.10.1 ⏵ 3.10.29910072 +198 +5100
Updatedremark-config-nick2bad4u@​1.1.3 ⏵ 1.1.472 +110010093 -1100
Updatedeslint-config-nick2bad4u@​14.2.1 ⏵ 1.2.772 -310010096100
Updated@​easyops-cn/​docusaurus-search-local@​0.55.2 ⏵ 0.55.398 +11007393 +3100
Updatedprettier-config-nick2bad4u@​1.0.13 ⏵ 1.0.237310010095 +2100
Updatedesbuild@​0.28.1 ⏵ 0.28.292 +110073 +190100
Updatedtypedoc-config-nick2bad4u@​2.0.3 ⏵ 2.1.074 +11009893 +2100
Updatedgitcliff-config-nick2bad4u@​1.3.0 ⏵ 1.5.074 +7100100 +993 +1100
Updated@​types/​react-dom@​19.2.3 ⏵ 19.2.5100 +110075 +189100
Updated@​vitest/​ui@​4.1.10 ⏵ 4.1.11991007599 +2100
Updated@​docusaurus/​core@​3.10.1 ⏵ 3.10.298 +110076 +198 +5100
Updatedjscpd-config-nick2bad4u@​1.1.0 ⏵ 1.1.176 +31008890100
Updated@​docusaurus/​theme-mermaid@​3.10.1 ⏵ 3.10.2991007695 -2100
Updated@​types/​leaflet@​1.9.21 ⏵ 1.9.221001007784 +3100
Updateddocusaurus-plugin-copy-page-button@​0.8.3 ⏵ 0.8.47810010096100
Updated@​types/​react@​19.2.16 ⏵ 19.2.18100 +11007990 -2100
Updated@​vitest/​coverage-v8@​4.1.10 ⏵ 4.1.11991007999100
Updatedvitest@​4.1.10 ⏵ 4.1.119810079 +199100
Updatedvite@​8.1.4 ⏵ 8.2.29810082 +197100
Updatedreact@​19.2.7 ⏵ 19.2.81001008497100
Updated@​electron/​get@​5.0.0 ⏵ 5.1.099 +1100100 +184100
Updated@​docusaurus/​theme-live-codeblock@​3.10.1 ⏵ 3.10.2971008598100
Updated@​maplibre/​maplibre-gl-leaflet@​0.1.3 ⏵ 0.1.498 +4100100 +190 +5100
Updatedleaflet.locatecontrol@​0.90.0 ⏵ 0.90.1100 +4100100 +191 +3100
Updatedreact-dom@​19.2.7 ⏵ 19.2.81001009298100
See 8 more rows in the dashboard

View full report

@socket-security

socket-security Bot commented Sep 3, 2026 •

Copy link
Copy Markdown

Warning

Review the following alerts detected in dependencies.

According to your organization's Security Policy, it is recommended to resolve "Warn" alerts. Learn more about Socket for GitHub.

Action Severity Alert  (click "▶" to expand/collapse)
Warn High
Obfuscated code: npm @astrojs/compiler is 90.0% likely obfuscated

Confidence: 0.90

Location: Package overview

From: package-lock.json → npm/eslint-config-nick2bad4u@1.2.7 → npm/prettier-config-nick2bad4u@1.0.23 → npm/@astrojs/compiler@2.13.1

ℹ Read more on: This package | This alert | What is obfuscated code?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Packages should not obfuscate their code. Consider not using packages with obfuscated code.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/@astrojs/compiler@2.13.1. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

Warn High
Obfuscated code: npm @noble/hashes is 90.0% likely obfuscated

Confidence: 0.90

Location: Package overview

From: package-lock.json → npm/jsdom@29.1.1 → npm/electron-builder@26.16.0 → npm/@noble/hashes@1.8.0

ℹ Read more on: This package | This alert | What is obfuscated code?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Packages should not obfuscate their code. Consider not using packages with obfuscated code.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/@noble/hashes@1.8.0. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

Warn High
Obfuscated code: npm @noble/hashes is 90.0% likely obfuscated

Confidence: 0.90

Location: Package overview

From: package-lock.json → npm/jsdom@29.1.1 → npm/electron-builder@26.16.0 → npm/@noble/hashes@1.8.0

ℹ Read more on: This package | This alert | What is obfuscated code?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Packages should not obfuscate their code. Consider not using packages with obfuscated code.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/@noble/hashes@1.8.0. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

View full report

@codacy-production

codacy-production Bot commented Sep 3, 2026 •

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 79 complexity · -1 duplication

Metric Results
Complexity 79
Duplication -1

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@codecov

codecov Bot commented Sep 3, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 63.09%. Comparing base (4b03e68) to head (a6222ab).
⚠️ Report is 9 commits behind head on main.

Flag Coverage Δ
electron-app 63.09% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@@           Coverage Diff           @@
##             main     #211   +/-   ##
=======================================
  Coverage   63.09%   63.09%           
=======================================
  Files           8        8           
  Lines        1084     1084           
  Branches      208      208           
=======================================
  Hits          684      684           
  Misses        299      299           
  Partials      101      101           

Impacted file tree graph

Components Coverage Δ
⚡ Core Electron Process ∅ <ø> (∅)
Renderer & UI ∅ <ø> (∅)
Utilities 63.70% <ø> (ø)
FIT Parsing ∅ <ø> (∅)
Window State Management ∅ <ø> (∅)

Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 05c3e87...a6222ab. Read the comment docs.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: cf3d47cf22

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

{},
commandRunner
)
).toThrow("forbidden Squirrel packaging artifacts");

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Make the Windows-only smoke assertion portable

On Linux and macOS, this assertion cannot pass because runPackagedSmoke() ultimately calls findForbiddenWindowsPackagingArtifacts() with its default process.platform; the scanner therefore returns early instead of reporting the fixture's Windows artifacts, and the empty commandRunner produces a different error. This breaks npm test in the Ubuntu release gate in Build.yml, the Ubuntu dependency-validation job, and the Linux/macOS release-rehearsal matrix. Inject a Windows platform into this path or isolate the host-dependent assertion.

Useful? React with 👍 / 👎.

Comment on lines +193 to +195
const packagingInspectionPath = configuredExecutablePath
? path.dirname(resolvedExecutablePath)
: resolvedReleaseDistPath;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Inspect the requested release directory with explicit executables

On Windows, supplying --executable or FFV_PACKAGED_APP makes this inspect only the executable's immediate directory, even when --release-dist explicitly identifies the complete release output. For example, an executable under release-dist/win-unpacked passes when a leaked release-dist/squirrel-windows directory exists beside it; the added test fixture includes exactly this layout but its _ExecutionStub.exe masks the missed sibling. Prefer the supplied release directory, or otherwise inspect a common release root, so the new artifact guard covers the full output.

Useful? React with 👍 / 👎.

♻️ [refactor] Divide ZIP entry extraction, symlink verification, audit result validation, npm command resolution, and captured-failure handling into focused helpers.
 - Preserve the traversal, symlink, exact-advisory, and fail-closed behavior while bringing every changed method below the repository's Codacy complexity and length thresholds.

🧪 [test] Re-run the focused extraction and audit regressions, formatter, root lint, and both audit gates.
🐛 [fix] Remove the host-platform shortcut from Squirrel artifact discovery so Linux release-assembly and dependency-validation runners reject Windows Squirrel output before launching a package.

🧪 [test] Keep the regression platform-independent and verify the command runner is never reached when forbidden output exists.
@sonarqubecloud

sonarqubecloud Bot commented Sep 3, 2026

Copy link
Copy Markdown

@Nick2bad4u
Nick2bad4u merged commit 097a80d into main Sep 3, 2026
35 checks passed
@Nick2bad4u
Nick2bad4u deleted the fix/remove-squirrel-packaging branch September 3, 2026 03:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant