From 3852a29394d26e6385d4560b3b71c783a4064fd7 Mon Sep 17 00:00:00 2001 From: JakeyPrime Date: Wed, 25 Jun 2025 00:41:42 -0400 Subject: [PATCH] Update MAS --- Wimdows/All-In-One-Version-KL/Wimdows_AIO.cmd | 203 +++++++++++------- 1 file changed, 128 insertions(+), 75 deletions(-) diff --git a/Wimdows/All-In-One-Version-KL/Wimdows_AIO.cmd b/Wimdows/All-In-One-Version-KL/Wimdows_AIO.cmd index bbb1144..249b5cb 100644 --- a/Wimdows/All-In-One-Version-KL/Wimdows_AIO.cmd +++ b/Wimdows/All-In-One-Version-KL/Wimdows_AIO.cmd @@ -1,8 +1,28 @@ @::yfh37fow-random -@set wimdowsver=3.4 +@set masver=3.4 @setlocal DisableDelayedExpansion @echo off + + +:: For command line switches, check mass<>grave<.>dev/command_line_switches +:: If you want to better understand script, read from MAS separate files version. + + + +::============================================================================ +:: +:: Homepage: mass<>grave<.>dev +:: Email: mas.help@outlook.com +:: +::============================================================================ + + + +::======================================================================================================================================== + +:: Set environment variables, it helps if they are misconfigured in the system + setlocal EnableExtensions setlocal DisableDelayedExpansion @@ -46,9 +66,9 @@ exit /b ::======================================================================================================================================== set "blank=" -set "mas=ht%blank%tps%blank%://discord.gg/zira" -set "github=ht%blank%tps%blank%://discord.gg/zira" -set "selfgit=ht%blank%tps%blank%://discord.gg/zira" +set "mas=ht%blank%tps%blank%://mass%blank%grave.dev/" +set "github=ht%blank%tps%blank%://github.com/massgra%blank%vel/Micro%blank%soft-Acti%blank%vation-Scripts" +set "selfgit=ht%blank%tps%blank%://git.acti%blank%vated.win/massg%blank%rave/Micr%blank%osoft-Act%blank%ivation-Scripts" :: Check if Null service is working, it's important for the batch script @@ -58,16 +78,35 @@ echo: echo Null service is not running, script may crash... echo: echo: -echo https://discord.gg/zira +echo Check this webpage for help - %mas%fix_service echo: echo: ping 127.0.0.1 -n 20 ) cls +:: Check LF line ending + +pushd "%~dp0" +>nul findstr /v "$" "%~nx0" && ( +echo: +echo Error - Script either has LF line ending issue or an empty line at the end of the script is missing. +echo: +echo: +echo Check this webpage for help - %mas%troubleshoot +echo: +echo: +ping 127.0.0.1 -n 20 >nul +popd +exit /b +) +popd + +::======================================================================================================================================== + cls color 07 -title Wimdows %wimdowsver% +title Microsoft_Activation_Scripts %masver% set _args= set _elev= @@ -99,15 +138,15 @@ if %winbuild% EQU 1 ( echo Failed to detect Windows build number. echo: setlocal EnableDelayedExpansion -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%troubleshoot +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot" goto dk_done ) if %winbuild% LSS 6001 ( %nceline% echo Unsupported OS version detected [%winbuild%]. -echo Wimdows only supports Windows Vista/7/8/8.1/10/11 and their Server equivalents. +echo MAS only supports Windows Vista/7/8/8.1/10/11 and their Server equivalents. if %winbuild% EQU 6000 ( echo: echo Windows Vista RTM is not supported because Powershell cannot be installed. @@ -191,15 +230,15 @@ echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLangua echo FullLanguage mode not found in PowerShell. Aborting... echo If you have applied restrictions on Powershell then undo those changes. echo: -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%fix_powershell +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%fix_powershell" goto dk_done ) REM check Powershell core version cmd /c "%psc% "$PSVersionTable.PSEdition"" | find /i "Core" %nul1% && ( -echo Windows Powershell is needed for Wimdows but it seems to be replaced with Powershell core. Aborting... +echo Windows Powershell is needed for MAS but it seems to be replaced with Powershell core. Aborting... goto dk_done ) @@ -209,8 +248,8 @@ for /r "%ProgramFiles%\" %%f in (secureboot.exe) do if exist "%%f" ( echo "%%f" echo Mal%blank%ware found, PowerShell is not working properly. echo: -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%remove_mal%w%ware +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%remove_mal%w%ware" goto dk_done ) @@ -225,8 +264,8 @@ cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiV ) echo: -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%troubleshoot +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot" goto dk_done ) @@ -278,7 +317,7 @@ exit /b set -= set old= set pingp= -set upver=%wimdowsver:.=% +set upver=%masver:.=% for %%A in ( activ%-%ated.win @@ -295,11 +334,11 @@ if not "%%C"=="" set old= if defined old ( echo ________________________________________________ %eline% -echo Your version of Wimdows [%wimdowsver%] is outdated. +echo Your version of MAS [%masver%] is outdated. echo ________________________________________________ echo: if not %_unattended%==1 ( -echo [1] Get Latest Wimdows +echo [1] Get Latest MAS echo [0] Continue Anyway echo: call :dk_color %_Green% "Choose a menu option using your keyboard [1,0] :" @@ -351,7 +390,7 @@ goto dk_done cls color 07 -title Wimdows %wimdowsver% +title Microsoft %blank%Activation %blank%Scripts %masver% if not defined terminal mode 76, 34 if %winbuild% GEQ 10240 if not exist "%SystemRoot%\Servicing\Packages\Microsoft-Windows-Server*Edition~*.mum" if not exist "%SystemRoot%\Servicing\Packages\Microsoft-Windows-*EvalEdition~*.mum" set _hwidgo=1 @@ -490,7 +529,7 @@ if not defined terminal mode 78, 30 echo: echo: echo: -echo: Welcome to Team Hydra's Windows activator, thanks to MAS for their core. +echo: echo: Extract $OEM$ folder on the desktop echo: ____________________________________________________________ echo: @@ -583,7 +622,7 @@ set _NoEditionChange=0 cls color 07 -title HWID Activation %wimdowsver% +title HWID Activation %masver% set _args= set _elev= @@ -628,7 +667,7 @@ if not defined terminal ( mode 110, 34 if exist "%SysPath%\spp\store_test\" mode 134, 34 ) -title HWID Activation %wimdowsver% +title HWID Activation %masver% echo: echo Initializing... @@ -646,8 +685,8 @@ if not defined results ( call :dk_color %Blue% "Go back to Main Menu, select Troubleshoot and run DISM Restore and SFC Scan options." call :dk_color %Blue% "After that, restart system and try activation again." echo: -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%troubleshoot +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot" ) goto dk_done ) @@ -693,8 +732,8 @@ echo: echo Evaluation editions cannot be activated outside of their evaluation period. call :dk_color %Blue% "Use TSforge activation option from the main menu to reset evaluation period." echo: -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%evaluation_editions +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%evaluation_editions" goto dk_done ) ) @@ -776,12 +815,12 @@ if not defined skunotfound ( echo This product does not support HWID activation. echo Make sure you are using the latest version of the script. echo If you are, then try TSforge activation option from the main menu. -set fixes=%fixes% https://discord.gg/zira -echo https://discord.gg/zira +set fixes=%fixes% %mas% +echo %mas% ) else ( echo Required license files not found in %SysPath%\spp\tokens\skus\ -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%troubleshoot +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot" ) echo: goto dk_done @@ -960,8 +999,8 @@ licensing.mp.microsoft.com findstr /i "%%#" "%SysPath%\drivers\etc\hosts" %nul1% && set "hosfail= [%%# Blocked in Hosts]" ) call :dk_color %Red% "Checking Licensing Servers [Failed to Connect]!hosfail!" -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%licensing-servers-issue +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%licensing-servers-issue" ) ::========================================================================================================================================== @@ -997,8 +1036,8 @@ set error=1 call :dk_color %Red% "Checking Windows Update Registry [Corruption Found]" if !wcount! GTR 2 ( call :dk_color %Red% "Windows seems to be infected with Mal%w%ware." -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%remove_mal%w%ware +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%remove_mal%w%ware" ) else ( call :dk_color %Blue% "HWID activation needs working Windows updates, if you have used any tool to block updates, undo it." ) @@ -1022,8 +1061,8 @@ if %keyerror% EQU 0 if not defined _perm if defined _int ( if not defined wucorrupt if not defined wublock if not defined wuerror if not defined storeblock if not defined resfail ( echo "%error_code%" | findstr /i "0x80072e 0x80072f 0x800704cf 0x87e10bcf 0x800705b4" %nul% && ( call :dk_color %Red% "Checking Internet Issues [Found] %error_code%" -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%licensing-servers-issue +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%licensing-servers-issue" ) ) ) @@ -1121,7 +1160,7 @@ set "_exitmsg=Go back" set "_fixmsg=Go back to Main Menu, select Troubleshoot and run Fix Licensing option." ) else ( set "_exitmsg=Exit" -set "_fixmsg=In Wimdows folder, run Troubleshoot script and select Fix Licensing option." +set "_fixmsg=In MAS folder, run Troubleshoot script and select Fix Licensing option." ) exit /b @@ -1570,8 +1609,8 @@ call :dk_color %Blue% "Reboot your machine using the restart option to fix this set showfix=1 ) echo %serv_e% | findstr /i "sppsvc-1060" %nul% && ( -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%fix_service +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%fix_service" set showfix=1 ) ) @@ -1599,8 +1638,8 @@ set showfix=1 call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode." ) echo "%imagestate%" | find /i "UNDEPLOYABLE" %nul% && ( -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "If the activation fails, do this - " %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%in-place_repair_upgrade +call :dk_color2 %Blue% "If the activation fails, do this - " %_Yellow% " %mas%in-place_repair_upgrade" ) ) @@ -1627,8 +1666,8 @@ echo Checking WPA Registry Count [%wpainfo%] if not defined notwinact if exist "%SystemRoot%\Servicing\Packages\Microsoft-Windows-*EvalEdition~*.mum" ( reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul2% | find /i "Eval" %nul1% || ( call :dk_color %Red% "Checking Eval Packages [Non-Eval Licenses are installed in Eval Windows]" -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "https://discord.gg/zira" %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%evaluation_editions +call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%evaluation_editions" ) ) @@ -1732,8 +1771,8 @@ reg query "HKU\S-1-5-20\Software\Microsoft\Windows NT\CurrentVersion" %nul% || ( set error=1 set showfix=1 call :dk_color %Red% "Checking HKU\S-1-5-20 Registry [Not Found]" -set fixes=%fixes% https://discord.gg/zira -call :dk_color2 %Blue% "In case of activation issues, do this - " %_Yellow% " https://discord.gg/zira" +set fixes=%fixes% %mas%in-place_repair_upgrade +call :dk_color2 %Blue% "In case of activation issues, do this - " %_Yellow% " %mas%in-place_repair_upgrade" ) @@ -2129,7 +2168,7 @@ set _rem=0 cls color 07 -title Ohook Activation %wimdowsver% +title Ohook Activation %masver% set _args= set _elev= @@ -2156,7 +2195,7 @@ if %_rem%==1 goto :oh_uninstall if %_unattended%==0 ( cls if not defined terminal mode 76, 25 -title Ohook Activation %wimdowsver% +title Ohook Activation %masver% call :oh_checkapps echo: echo: @@ -2195,7 +2234,7 @@ mode 140, 32 if exist "%SysPath%\spp\store_test\" mode 140, 32 %psc% "&{$W=$Host.UI.RawUI.WindowSize;$B=$Host.UI.RawUI.BufferSize;$W.Height=32;$B.Height=300;$Host.UI.RawUI.WindowSize=$W;$Host.UI.RawUI.BufferSize=$B;}" %nul% ) -title Ohook Activation %wimdowsver% +title Ohook Activation %masver% echo: echo Initializing... @@ -2521,7 +2560,7 @@ goto :dk_done cls if not defined terminal mode 145, 32 -title Uninstall Ohook Activation %wimdowsver% +title Uninstall Ohook Activation %masver% set _present= set _unerror= @@ -3071,7 +3110,7 @@ call :dk_inskey "[!key!] [!_prod!] [!_lic!]" ) else ( set error=1 call :dk_color %Red% "Checking Product In Script [Office %oVer%.0 !_prod! key not found in script]" -call :dk_color %Blue% "Make sure you are using the latest version of Wimdows." +call :dk_color %Blue% "Make sure you are using the latest version of MAS." set fixes=%fixes% %mas% call :dk_color %_Yellow% "%mas%" ) @@ -3973,7 +4012,7 @@ set "_debug=0" cls color 07 set KS=K%blank%MS -title TSforge Activation %wimdowsver% +title TSforge Activation %masver% set _args= set _elev= @@ -4021,7 +4060,7 @@ goto dk_done if %_unattended%==0 ( cls if not defined terminal mode 76, 33 -title TSforge Activation %wimdowsver% +title TSforge Activation %masver% echo: echo: @@ -4138,7 +4177,7 @@ mode 125, %height% if exist "%SysPath%\spp\store_test\" mode 134, %height% %psc% "&{$W=$Host.UI.RawUI.WindowSize;$B=$Host.UI.RawUI.BufferSize;$W.Height=%height%;$B.Height=300;$Host.UI.RawUI.WindowSize=$W;$Host.UI.RawUI.BufferSize=$B;}" %nul% ) -title TSforge Activation %wimdowsver% +title TSforge Activation %masver% echo: echo Initializing... @@ -5523,7 +5562,7 @@ cls if not defined terminal ( mode 100, 30 ) -title Remove TSforge Activation %wimdowsver% +title Remove TSforge Activation %masver% echo: echo TSforge activation doesn't modify any Windows components and doesn't install any new files. @@ -11642,7 +11681,7 @@ set _NoEditionChange=0 cls color 07 -title KMS38 Activation %wimdowsver% +title KMS38 Activation %masver% set _args= set _elev= @@ -11689,7 +11728,7 @@ if %_rem%==1 goto :k_uninstall if %_unattended%==0 ( cls if not defined terminal mode 76, 25 -title KMS38 Activation %wimdowsver% +title KMS38 Activation %masver% echo: echo: @@ -11723,7 +11762,7 @@ if not defined terminal ( mode 110, 34 if exist "%SysPath%\spp\store_test\" mode 134, 34 ) -title KMS38 Activation %wimdowsver% +title KMS38 Activation %masver% echo: echo Initializing... @@ -12175,7 +12214,7 @@ goto :dk_done cls if not defined terminal mode 99, 28 -title Remove KMS38 Protection %wimdowsver% +title Remove KMS38 Protection %masver% %nul% reg delete "HKLM\%specific_kms%" /f %nul% reg delete "HKU\S-1-5-20\%specific_kms%" /f @@ -12456,7 +12495,7 @@ set _port= cls color 07 set KS=K%blank%MS -title Online %KS% Activation %wimdowsver% +title Online %KS% Activation %masver% set _args= set _elev= @@ -12491,7 +12530,7 @@ if not defined _server set _port= if %_unattended%==0 ( cls if not defined terminal mode 76, 30 -title Online %KS% Activation %wimdowsver% +title Online %KS% Activation %masver% echo: echo: @@ -12559,7 +12598,7 @@ mode 115, 32 if exist "%SysPath%\spp\store_test\" mode 135, 32 %psc% "&{$W=$Host.UI.RawUI.WindowSize;$B=$Host.UI.RawUI.BufferSize;$W.Height=32;$B.Height=300;$Host.UI.RawUI.WindowSize=$W;$Host.UI.RawUI.BufferSize=$B;}" %nul% ) -title Online %KS% Activation %wimdowsver% +title Online %KS% Activation %masver% echo: echo Initializing... @@ -13251,7 +13290,7 @@ call :dk_inskey "[!key!] [!_prod!]" if not defined _oMSI ( set error=1 call :dk_color %Red% "Checking Product In Script [Office %oVer%.0 !_prod! not found in script]" -call :dk_color %Blue% "Make sure you are using Latest Wimdows script." +call :dk_color %Blue% "Make sure you are using Latest MAS script." ) else ( call :dk_color %Red% "Checking Product In Script [!_prod! MSI Retail is not supported]" call :dk_color %Blue% "Use Ohook option to activate it. To activate with %KS%, you need to install Volume version of Office." @@ -13308,7 +13347,7 @@ exit /b cls if not defined terminal mode 91, 30 -title Online %KS% Complete Uninstall %wimdowsver% +title Online %KS% Complete Uninstall %masver% set "uline=__________________________________________________________________________________________" @@ -13374,6 +13413,8 @@ echo Deleting [Folder] %ProgramFiles%\Activation-Renewal\ rmdir /s /q "%ProgramFiles%\Activation-Renewal\" %nul% ) +:: Stuff from old MAS versions + schtasks /delete /tn Online_%KS%_Activation_Script-Renewal /f %nul% schtasks /delete /tn Online_%KS%_Activation_Script-Run_Once /f %nul% del /f /q "%ProgramData%\Online_%KS%_Activation.cmd" %nul% @@ -13400,6 +13441,16 @@ exit /b :_extracttask: @echo off +:: Renew K-M-S activation with Online servers via scheduled task + +::============================================================================ +:: +:: Homepage: mass grave[.]dev +:: Email: mas.help@outlook.com +:: +::============================================================================ + + if not "%~1"=="Task" ( echo: echo ====== Error ====== @@ -14001,8 +14052,10 @@ echo C:\Program Files\Activation-Renewal\Info.txt echo C:\Program Files\Activation-Renewal\Logs.txt echo ______________________________________________________________________________________________ echo: -echo This Script is a part of Wimdows project. +echo This Script is a part of MAS project. echo: +echo Homepage: mass grave[.]dev +echo Email: mas.help@outlook.com )>"%_dest%\Info.txt" exit /b @@ -16275,7 +16328,7 @@ set "line=______________________________________________________________________ :at_menu cls -title Troubleshoot %wimdowsver% +title Troubleshoot %masver% if not defined terminal mode 77, 30 echo: @@ -17358,7 +17411,7 @@ set "line=echo _________________________________________________________________ cls if not defined terminal mode 98, 30 -title Change Windows Edition %wimdowsver% +title Change Windows Edition %masver% if %winbuild% LSS 7600 ( %eline% @@ -18223,7 +18276,7 @@ set "line=echo _________________________________________________________________ cls if not defined terminal mode 98, 30 -title Change Office Edition %wimdowsver% +title Change Office Edition %masver% if %winbuild% LSS 7600 ( %eline% @@ -18368,7 +18421,7 @@ goto dk_done cls set fixes= if not defined terminal mode 76, 25 -title Change Office Edition %wimdowsver% +title Change Office Edition %masver% echo: echo: echo: @@ -18410,9 +18463,9 @@ goto :oe_goback cls if not defined terminal mode 76, 25 if %change%==1 ( -title Change all editions %wimdowsver% +title Change all editions %masver% ) else ( -title Add edition %wimdowsver% +title Add edition %masver% ) echo: @@ -18755,7 +18808,7 @@ goto :oe_goback :oe_editedition cls -title Add/Remove Apps %wimdowsver% +title Add/Remove Apps %masver% call :oe_chkinternet if not defined _int ( @@ -18813,7 +18866,7 @@ goto :oe_excludeappspre :oe_removeedition -title Remove Office editions %wimdowsver% +title Remove Office editions %masver% call :ch_getinfo @@ -18896,7 +18949,7 @@ goto :oe_goback :oe_changeupdchnl -title Change Office update channel %wimdowsver% +title Change Office update channel %masver% call :ch_getinfo cls @@ -19378,4 +19431,4 @@ if ($appIdsList.Count -gt 0) { ::======================================================================================================================================== :: -:: Leave empty line below +:: Leave empty line below \ No newline at end of file