We have a self-hosted instance of Discourse on a virtual machine and after applying most recent Discourse updates v3.4.0.beta3 +431we have received alert from Microsoft Defender about Wacatac malware:
We have removed the file, restarted the virtual machine and now we´re waiting for another scan to run. This has already happened on December 2024 when we were pulling most recent Discourse updates.
It seems that Wacatac is somehow coming via Discourse updates or it might also be a false positive…
And for the one from December 2024:
/var/lib/docker/overlay2/d5d34d6148be507180106dc3b39b8b3d266b5e221fd5df48ce023df57186d4ef/diff/home/discourse/.local/share/pnpm/store/v3/files/23/f5520e308f56ab79324ef0ea1249acf7aa09f192d1b5e5599b3b284e46f1e6c0d6d58707b63a9c965399930b6148639ef2bd6d1d4d55343448ba42b4535440-exec
Those md5 hashes correspond to the published versions on npm, so we can be confident that they haven’t been tampered with between the registry and your installation:
So I think this has to be a false positive from Microsoft Defender. Removing esbuild from your Discourse installation will cause issues, so I’d recommend against that.
Searching online, it seems like Microsoft Defender falsely alerting against npm packages is fairly common. Here’s an example of a false detection of esbuild in the past.