Windows portable release flagged by Microsoft VirusTotal heuristic detection
Describe the bug
The Windows portable release of Markpad 2.7.0 appears to trigger false-positive malware detections on VirusTotal.
To Reproduce
-
Download the Markpad 2.7.0 portable Windows x64 release from the official GitHub release page.
-
Verify that the SHA-256 checksum matches the published checksum.
-
Scan the executable with VirusTotal.
-
Observe the following detections:
- Microsoft:
Trojan:Win32/Wacatac.B!ml - Trapmine:
Suspicious.low.ml.score
- Microsoft:
Expected behavior
The official release binary should ideally not trigger false-positive malware detections.
Actual behavior
VirusTotal reports 2/70 heuristic/ML-based detections for the official portable Windows release.
Additional context
VirusTotal report: https://www.virustotal.com/gui/file/ed58d83b7342dcbc58352202a472d719747d5070b373dd537a8c997e38876646
The executable is not digitally signed, so this may be related to reputation or heuristic detection.
The SHA-256 checksum matches the one published with the release.
I wanted to report this so other users are not discouraged from using the portable version due to antivirus warnings.
Thanks for maintaining Markpad.
Not malicious, and I think it is worth naming exactly what trips it rather than leaving it at "false positive" — the pattern is real, it just belongs to the uninstaller.
@alecdotdev this is the same root cause you diagnosed in #334 ("a false positive caused by the custom uninstall script"). It is still there, and it now shows on the portable exe because the portable and the installer are the same binary.
What the scanner is reacting to
src-tauri/src/setup.rs, the uninstall path:
:898 writes %TEMP%\markpad_uninstall_<suffix>.bat
:920 writes a .vbs: CreateObject("Wscript.Shell").Run "<bat>", 0, False
↑ 0 = hidden window
:922 fso.DeleteFile WScript.ScriptFullName ← the script deletes itself
:956 launches it via C:\Windows\System32\wscript.exe
:843 Command::new(&target_exe).spawn()
Drop a script that runs hidden, have it delete itself, then start an executable — that sequence is close to the definition of Trojan:Win32/Wacatac.B!ml, which is a behaviour classifier rather than a signature match. Each property is there for a good reason (the batch waits on the PID rather than the image name so a portable copy survives an uninstall, #358), but the shape is what gets scored.
Two consequences worth separating:
Reachability does not help. get_app_mode() only enters installer mode when the filename contains installer or --install is passed, and since #355 no MarkpadInstaller_*.exe is published — so the portable download can never run this code. Heuristic and ML scanners read what is in the file, not what the file can reach, so it is flagged anyway.
Signing will not fix it either. A Developer ID or an Authenticode cert addresses SmartScreen reputation; it does not change a behaviour classifier's score. Worth knowing before spending money on one, and the same distinction applies to #209 on the macOS side.
What would actually fix it
Three routes, and each has a real constraint:
- Don't compile the installer code into the shipped binary. Cleanest for the scanner, but Tauri bundles only
mainBinaryName, so a second target means another CI artifact — reintroducing the extra download #355 deliberately removed. - Rework the uninstall mechanism so it doesn't need a hidden self-deleting script. This is what you said you'd do in #334. The constraint is that legacy installs have
UninstallStringpointing atMarkpad.exe --uninstall, so it can't simply go away — though that window is closing on its own, since v2.7.0 installs via NSIS and NSIS rewritesUninstallStringto its ownuninstall.exeon the next install or update. - Leave it and document it. Two of seventy is low, but a Microsoft detection is the one users actually see.
All three are really the same decision as #395 — what happens to the custom installer now that no shipped artifact can reach it. I've added a note there. Happy to implement whichever route you pick; I'd want your call before touching an uninstall path that live installations depend on.
@cindyyoyo — thanks for checking the checksum before reporting, that ruled out the thing that actually matters. The portable exe is safe to run; if your AV quarantines it, the -setup.exe installer is unaffected by this particular pattern.
@PathGao could we strip the install/uninstall code from the compiled executable and just use the NSIS installer. I've submitted a false-positive report to MS Defender Threat Intelligence re: #334 but not a proper solution.
once its ready we can cut a release for 2.7.1 to address this and #463 and anything else that has hit master.
Yes — and it splits cleanly into a free half and a half with one thing to check.
The install half is already dead code. get_app_mode() only enters installer mode on a filename containing installer or an --install argument, and #355 stopped publishing any installer-named artifact. Nothing shipped can reach install_app, create_shortcut, check_install_status or Installer.svelte. Removing them changes no observable behaviour for anyone on 2.7.0.
The uninstall half is where the detection actually lives — the %TEMP%\markpad_uninstall_*.bat, the hidden self-deleting .vbs, the wscript.exe launch. That is the sequence Wacatac scores, so it has to go for the report to be worth anything. One compatibility question decides whether it can go in the same release:
Custom installs from 2.6.x wrote UninstallString = "…\Markpad.exe" --uninstall (setup.rs:715). NSIS writes UninstallString = "$INSTDIR\uninstall.exe" and does it unconditionally in its install section, so an update through the NSIS setup migrates those entries. The question is whether the auto-updater's run of the setup actually executes that section — tauri-plugin-updater passes /UPDATE, and the template skips some steps in update mode. If it skips the registry write, a legacy install would end up with UninstallString pointing at a Markpad.exe that no longer understands --uninstall, and Add/Remove Programs would silently do nothing.
I cannot test that from macOS. Two ways to be safe:
- Verify it once on Windows — install 2.6.13 with the old
MarkpadInstaller_*.exe, update to a 2.7.1 build, then readHKCU\…\Uninstall\Markpad\UninstallString. If it saysuninstall.exe, the whole thing can go now. - Or keep only the
--uninstallentry point for one release — a few hundred lines instead of ~2,500, and none of the flagged pattern survives if the batch/vbs mechanism is replaced by a plain synchronous delete. Slower, but it cannot strand anyone.
I'd rather do the first if you can spare ten minutes on a Windows box, since the second still leaves a decision for later. Happy to prepare the change either way — say which and I'll open it against 2.7.1.
Two more things worth knowing while this is open:
- Signing would not have fixed this. A certificate addresses SmartScreen reputation, not a behaviour classifier's score. Worth keeping in mind for #209 on the macOS side too, where notarization fixes quarantine and the TCC grant but not a heuristic detection.
- This also answers #395, which was open on exactly this question. I'll note your decision there.
https://github.com/sftwrdotdev/Markpad/releases/download/v2.7.1/Markpad_2.7.1_x64-setup.exe gets removed by Widows Defender .
@alexeiroz that is a different file from the one this issue is about — #466 was the portable Markpad_x64.exe, and the code behind it was removed in #481, which is in the 2.7.1 tag. So a detection on 2.7.1_x64-setup.exe is either a different cause or a generic verdict on a new unsigned file, and this thread is the wrong place to work that out.
Could you open it as a new report? → Bug report (nothing in the form is required)
Three things decide it, and only you can see them:
- The detection name, from Windows Security → Protection history → the Markpad entry.
Trojan:Win32/Wacatac.B!ml,Program:Win32/Wacapew.C!ml, something else — the name says whether this is the same classifier as #334 or an unrelated one. - Whether the portable
Markpad_2.7.1_x64.exeis also quarantined. Same release page. This is the one test that separates "something in the app" from "something in the installer wrapper", and it takes a minute. - Defender version / OS build, if the history entry shows them.
With those I can point Microsoft at the right file — the false-positive report @alecdotdev filed for #334 was for an older build and does not cover this one.
Meanwhile: the installer is safe to run. If you want to skip the whole question, the portable exe on the same page needs no install.
Just a quick update, MS Defender definitions has been updated to remove the false-positive.
Analyst comments: At this time, the submitted files do not meet our criteria for malware or potentially unwanted applications. The detection has been removed. Please follow the steps below to clear cached detections and obtain the latest malware definitions. 1. Open command prompt as administrator and change directory to c:\Program Files\Windows Defender 2. Run “MpCmdRun.exe -removedefinitions -dynamicsignatures” 3. Run "MpCmdRun.exe -SignatureUpdate" Alternatively, the latest definition is available for download here: https://docs.microsoft.com/microsoft-365/security/defender-endpoint/manage-updates-baselines-microsoft-defender-antivirus Thank you for contacting Microsoft.
Just a quick update, MS Defender definitions has been updated to remove the false-positive.
Analyst comments: At this time, the submitted files do not meet our criteria for malware or potentially unwanted applications. The detection has been removed. Please follow the steps below to clear cached detections and obtain the latest malware definitions.
- Open command prompt as administrator and change directory to c:\Program Files\Windows Defender
- Run “MpCmdRun.exe -removedefinitions -dynamicsignatures”
- Run "MpCmdRun.exe -SignatureUpdate" Alternatively, the latest definition is available for download here: https://docs.microsoft.com/microsoft-365/security/defender-endpoint/manage-updates-baselines-microsoft-defender-antivirus Thank you for contacting Microsoft.
Markpad_2.7.3_x64-setup.exe on Visrustotal
- Arctic Wolf: Unsafe
- Microsoft: Trojan:Win32/Wacatac.B!ml
- SecureAge: Malicious
- Sophos: Generic ML PUA (PUA)