fix(windows): remove dead installer code from the shipped binary - #507
Merged
PathGao merged 2 commits intoAug 7, 2026
Merged
Conversation
The code that triggered Trojan:Win32/Wacatac.B!ml was removed in sftwrdotdev#481, but three things that still look like an installer to a behaviour classifier were left in the binary: - forward_legacy_uninstall() — answered --uninstall from pre-2.7 custom installs. The NSIS template writes UninstallString = uninstall.exe unconditionally, and the auto-updater passes /UPDATE which runs Section Install, so every install that has ever updated through 2.7.1 already has the corrected registry entry. The hooks.nsi macro also drops stray --uninstall entries from both hives as a backstop. - is_installer_mode detection — checked for --install or 'installer' in the exe name. No shipped artifact has triggered either since sftwrdotdev#355 stopped publishing an installer-named file, and sftwrdotdev#481 removed Installer.svelte, install_app, and the invoke_handler registrations that were the only consumers of the resulting window label. - The 'installer' window label in capabilities/default.json — window that no code can create any more. None of these do anything observable today, but a scanner that reads the file rather than tracing reachability still sees them. Removing them shrinks the binary by the 55 lines of Rust that remained from the old custom installer. Addresses the setup.exe detection reported in sftwrdotdev#466 (comment).
npm audit reports 5 moderate vulnerabilities in mermaid <= 11.16.0: - GHSA-c4c3-pg64-4m4v (prototype pollution) - GHSA-6x64-9x62-f2gx (CSS injection) - GHSA-3rrr-jr9j-h3q3 (prototype pollution) - GHSA-2v8p-3f2j-5mp7 (infinite loop DoS) - GHSA-rhh3-jpg6-66xh (DoS) All fixed in 11.16.1.
This was referenced Aug 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The code that triggered
Trojan:Win32/Wacatac.B!mlwas removed in #481, but the setup.exe (NSIS installer) is still being flagged by Windows Defender — see this comment on #466.Three things that still look like an installer to a behaviour classifier were left in the binary:
forward_legacy_uninstall()— answered--uninstallfrom pre-2.7 custom installs. The NSIS template writesUninstallString = uninstall.exeunconditionally, and the auto-updater's/UPDATEpass runs Section Install, so every install that has ever updated through 2.7.1 already has the corrected registry entry. Thehooks.nsimacro also drops stray--uninstallentries from both hives as a backstop.is_installer_modedetection — checked for--installor "installer" in the exe name. No shipped artifact has triggered either since build: harden release inputs and isolate test bundles #355 stopped publishing an installer-named file, and fix(windows): remove the bundled installer and uninstaller (#466) #481 removedInstaller.svelte,install_app, and theinvoke_handlerregistrations that were the only consumers of the resulting window label.The
"installer"window label in capabilities — a window that no code can create any more.None of these do anything observable today, but a scanner that reads the file rather than tracing reachability still sees them.
Change
forward_legacy_uninstall()and its call site inrun()is_installer_modedetection, hardcode label to"main"is_installer_modewindow-sizing block"installer"fromcapabilities/default.jsonVerification
npm test— 722 pass / 5 fail (same as master; the 5 are pre-existing Node.js v25 localStorage incompatibility)