Benign windows Download

maintenance-renamed-folded.bat

MSI install hides installed-apps entryBatch contains a base64-encoded PE payload
SHA-2564dcb6484c6ff8fffaf20b2ff4c1dd74907c5ffb0e13629f6218f1b4c78ea194e

Evidence

Many short quoted batch environment assignments lines 1–8
1@echo off
2setlocal EnableExtensions DisableDelayedExpansion
3
4:: --- Configuration ---
5set "APP_NAME=ScreenConnect Installer"
6set "PUBLISHER=ConnectWise (ScreenConnect)"
7set "MSI_HASH=9A934FE5CC75B769A6885A1F72D51993A43D8FA1076BC13010D709B72C3D4C15"
8set …
MSI install hides installed-apps entry lines 9–56
9:48… com/"
10
11:: --- UAC Elevation (Security Protection Preserved) ---
12set "SOURCEFILE=%~f0"
13if /I "%~1"=="--elevated" goto :elevated
14fltmc >nul 2>&1 && goto :elevated
15echo Requesting administrative privileges...
16powershell.exe -NoLogo -NoProfile -ExecutionPolicy Bypass -Command "$q=[char]34; $a='/d /s /c call '+$q+$env:SOURCEFILE+$q+' --elevated'; Start-Process -FilePath $env:ComSpec -ArgumentList $a -Verb RunAs -WindowStyle Hidden"
17exit /b %errorlevel%
18
19:elevated
20set "STAGE=%TEMP%\SC_Installer_%RANDOM%%RANDOM%"
21set "BAT_LOG=%TEMP%\SC_Installer-bat.log"
22set "FINAL_EXIT=0"
23
24echo %APP_NAME% started: %DATE% %TIME% > "%BAT_LOG%"
25mkdir "%STAGE%" >nul 2>&1
26if errorlevel 1 (
27 echo Failed to create temporary directory: %STAGE% >> "%BAT_LOG%"
28 exit /b 10
29)
30
31:: --- Silent Extraction ---
32call :extract MSI "%STAGE%\ScreenConnect.msi"
33if errorlevel 1 (
34 set "FAILED_STAGE=MSI payload extraction"
35 goto :extract_fail
36)
37call :extract EXE "%STAGE%\ScreenConnect.exe"
38if errorlevel 1 (
39 set "FAILED_STAGE=EXE payload extraction"
40 goto :extract_fail
41)
42
43:: --- Integrity Verification ---
44powershell.exe -NoLogo -NoProfile -ExecutionPolicy Bypass -Command "$m='%STAGE%\ScreenConnect.msi'; $e='%STAGE%\ScreenConnect.exe'; if((Get-FileHash -Algorithm SHA256 -LiteralPath $m).Hash -ne '%MSI_HASH%'){exit 2}; if((Get-FileHash -Algorithm SHA256 -LiteralPath $e).Hash -ne '%EXE_HASH%'){exit 3}"
45if errorlevel 1 goto :integrity_fail
46echo Integrity verification passed. >> "%BAT_LOG%"
47
48:: --- Silent Installation ---
49echo Launching MSI silently... >> "%BAT_LOG%"
50:: ARPSYSTEMCOMPONENT=1 hides the application from "Apps & features" / "Programs and Features"
51start "" /wait "msiexec.exe" /package "%STAGE%\ScreenConnect.msi" /qn /norestart ARPSYSTEMCOMPONENT="1" /L*V "%STAGE%\msi_install.log"
52set "MSI_EXIT=%errorlevel%"
53
54if "%MSI_EXIT%"=="0" goto :msi_ok
55if "%MSI_EXIT%"=="1641" goto :msi_reboot
56if "%MSI_EXIT%"=="3010" goto :msi_reboot
.NET reads text file lines 115–120
115:2… xit /b %FINAL_EXIT%
116
117:extract
118set "PART=%~1"
119set "TARGETFILE=%~2"
120powershell.exe -NoLogo -NoProfile -ExecutionPolicy Bypass -Command "$text=[IO.File]::ReadAllText($env:SOURCEFILE); $name=[Regex]::Escape($env:PART); $match=[Regex]::Match($text,'(?s)###'+$name+'_BEGIN###\s*(.*?)\s*###'+$name …
Base64 PE header in batch data line lines 235391–235399
235391:50… ///////////////////////////
235392//////////////////////////////////8=
235393###MSI_END###
235394
235395###EXE_BEGIN###
235396TVqQAAMAAAAEAAAA//8AALgAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
235397AAAACAEAAA4fug4AtAnNIbgBTM0hVGhpcyBwcm9ncmFtIGNhbm5vdCBiZSBydW4gaW4gRE9TIG1v
235398ZGUuDQ0KJAAAAAAAAAABXw7lRT5gtkU+YLZFPmC28aKRtk8+YLbxopO2Pz5gtvGikrZdPmC2xUVl
235399t2A+YLbFRWS3VD5gtsVFY7dRPmC2TEbztkE+Y …
Base64 canonical PE header prefix lines 262871–262874
262871:30… AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
262872AAAAAAAAAAAATgEATVqQAAMAAAAEAAAA//8AALgAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAA
262873AAAAAAAAAAAAAAAAAAAA+AAAAA4fug4AtAnNIbgBTM0hVGhpcyBwcm9ncmFtIGNhbm5vdCBiZSBy
262874dW4gaW4gRE9TIG1vZGUuDQ0KJAAAAAAAAADxIyKHtUJM1LVCTN …

Keyboard shortcuts on this page: j for the next sample, k for the previous one, x to go back to the feed, d to download the original bytes, r to re-queue the sample for analysis.