Compare commits

...

10 Commits

Author SHA1 Message Date
WindowsAddict d6aa8b97d1 Show update related troubleshooting when activation fails 2024-12-20 21:04:56 +05:30
WindowsAddict c00b076a86 change label name 2024-12-20 19:57:08 +05:30
WindowsAddict 8fff2ccb9c Check all act ids for errors instead of installed key's act id 2024-12-20 17:59:19 +05:30
WindowsAddict 5638898eaf Update license cleanup 2024-12-20 17:19:35 +05:30
WindowsAddict 22ed7a7a07 Update subscription editon keys 2024-12-20 16:49:21 +05:30
WindowsAddict f1ddb83df0 Update link in read me 2024-11-11 14:28:28 +05:30
WindowsAddict 4dd0215ccc Remove the box 2024-11-10 16:31:18 +05:30
WindowsAddict ec259dfbd7 Fix a typo 2024-11-10 00:47:15 +05:30
WindowsAddict bbdc9bdfd8 Revert export-ignore 2024-11-09 21:52:43 +05:30
WindowsAddict 7d036f57fd Export-ignore 2024-11-09 21:50:23 +05:30
10 changed files with 80 additions and 90 deletions

View File

@ -172,9 +172,9 @@ goto dk_done
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -900,29 +900,42 @@ call :dk_color %Red% "Generating New IdentityCRL Registry [Failed] [%_ident%
reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" /v DisableWindowsUpdateAccess %nul2% | find /i "0x1" %nul% && set wublock=1 reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" /v DisableWindowsUpdateAccess %nul2% | find /i "0x1" %nul% && set wublock=1
reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" /v DoNotConnectToWindowsUpdateInternetLocations %nul2% | find /i "0x1" %nul% && set wublock=1 reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" /v DoNotConnectToWindowsUpdateInternetLocations %nul2% | find /i "0x1" %nul% && set wublock=1
if defined wublock call :dk_color %Red% "Checking Update Blocker In Registry [Found]" if defined wublock (
call :dk_color %Red% "Checking Update Blocker In Registry [Found]"
call :dk_color %Blue% "HWID activation needs working Windows updates, if you have used any tool to block updates, undo it."
)
reg query "HKLM\SOFTWARE\Policies\Microsoft\WindowsStore" /v DisableStoreApps %nul2% | find /i "0x1" %nul% && ( reg query "HKLM\SOFTWARE\Policies\Microsoft\WindowsStore" /v DisableStoreApps %nul2% | find /i "0x1" %nul% && (
set storeblock=1 set storeblock=1
call :dk_color %Red% "Checking Store Blocker In Registry [Found]" call :dk_color %Red% "Checking Store Blocker In Registry [Found]"
call :dk_color %Blue% "If you have used any tool to block Store, undo it."
) )
set wcount=0
for %%G in (DependOnService Description DisplayName ErrorControl ImagePath ObjectName Start Type ServiceSidType RequiredPrivileges FailureActions) do if not defined wucorrupt ( for %%G in (DependOnService Description DisplayName ErrorControl ImagePath ObjectName Start Type ServiceSidType RequiredPrivileges FailureActions) do if not defined wucorrupt (
reg query HKLM\SYSTEM\CurrentControlSet\Services\wuauserv /v %%G %nul% || set wucorrupt=1 reg query HKLM\SYSTEM\CurrentControlSet\Services\wuauserv /v %%G %nul% || (set wucorrupt=1&set /a wcount+=1)
) )
for %%G in (Parameters Security TriggerInfo) do if not defined wucorrupt ( for %%G in (Parameters Security) do if not defined wucorrupt (
reg query HKLM\SYSTEM\CurrentControlSet\Services\wuauserv\%%G %nul% || set wucorrupt=1 reg query HKLM\SYSTEM\CurrentControlSet\Services\wuauserv\%%G %nul% || (set wucorrupt=1&set /a wcount+=1)
) )
if defined wucorrupt ( if defined wucorrupt (
call :dk_color %Red% "Checking Windows Update Registry [Corruption Found]" 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% %mas%remove_mal%w%ware
call :dk_color2 %Blue% "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."
)
) else ( ) else (
%psc% "Start-Job { Start-Service wuauserv } | Wait-Job -Timeout 20 | Out-Null" %psc% "Start-Job { Start-Service wuauserv } | Wait-Job -Timeout 20 | Out-Null"
sc query wuauserv | find /i "RUNNING" %nul% || ( sc query wuauserv | find /i "RUNNING" %nul% || (
set wuerror=1 set wuerror=1
sc start wuauserv %nul% sc start wuauserv %nul%
call :dk_color %Red% "Starting Windows Update Service [Failed] [!errorlevel!]" call :dk_color %Red% "Starting Windows Update Service [Failed] [!errorlevel!]"
call :dk_color %Blue% "HWID activation needs working Windows updates, if you have used any tool to block updates, undo it."
) )
) )
@ -1867,10 +1880,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
@ -2912,7 +2922,6 @@ rmdir /s /q "%ProgramData%\Microsoft\Office\Licenses\" %nul%
for %%x in (15 16) do ( for %%x in (15 16) do (
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Licensing /f %nul% reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Licensing /f %nul%
reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Identity /f %nul%
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do ( for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do (
rmdir /s /q "%%b\AppData\Local\Microsoft\Office\Licenses\" %nul% rmdir /s /q "%%b\AppData\Local\Microsoft\Office\Licenses\" %nul%
@ -2935,7 +2944,6 @@ if exist "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\Syst
set defname=DEFTEMP-%%# set defname=DEFTEMP-%%#
reg load HKU\!defname! "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\SystemAppData\Helium\User.dat" %nul% reg load HKU\!defname! "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\SystemAppData\Helium\User.dat" %nul%
reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Licensing /f %nul% reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Licensing /f %nul%
reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Identity /f %nul%
reg unload HKU\!defname! %nul% reg unload HKU\!defname! %nul%
) )
) )
@ -3146,15 +3154,15 @@ for %%# in (
15_9cedef15-be37-4ff0-a08a-13a045540641_RPHPB-Y7NC4-3VYFM-DW7VD-G8%f%YJ8_MAK___________WordVolume 15_9cedef15-be37-4ff0-a08a-13a045540641_RPHPB-Y7NC4-3VYFM-DW7VD-G8%f%YJ8_MAK___________WordVolume
:: Office 365 - 15.0 version :: Office 365 - 15.0 version
15_742178ed-6b28-42dd-b3d7-b7c0ea78741b_Y9NF9-M2QWD-FF6RJ-QJW36-RR%f%F2T_SubTest_______O365BusinessRetail 15_742178ed-6b28-42dd-b3d7-b7c0ea78741b_Y9NF9-M2QWD-FF6RJ-QJW36-RR%f%F2T_SubTest_______O365BusinessRetail
15_537ea5b5-7d50-4876-bd38-a53a77caca32_J2W28-TN9C8-26PWV-F7J4G-72%f%XCB_Subscription1_O365HomePremRetail 15_a96f8dae-da54-4fad-bdc6-108da592707a_3NMDC-G7C3W-68RGP-CB4MH-4C%f%XCH_SubTest1______O365HomePremRetail
15_e3dacc06-3bc2-4e13-8e59-8e05f3232325_H8DN8-Y2YP3-CR9JT-DHDR9-C7%f%GP3_Subscription2_O365ProPlusRetail 15_e3dacc06-3bc2-4e13-8e59-8e05f3232325_H8DN8-Y2YP3-CR9JT-DHDR9-C7%f%GP3_Subscription2_O365ProPlusRetail
15_bacd4614-5bef-4a5e-bafc-de4c788037a2_HN8JP-87TQJ-PBF3P-Y66KC-W2%f%K9V_Subscription1_O365SmallBusPremRetail 15_0bc1dae4-6158-4a1c-a893-807665b934b2_2QCNB-RMDKJ-GC8PB-7QGQV-7Q%f%TQJ_Subscription2_O365SmallBusPremRetail
:: Office 365 - 16.0 version :: Office 365 - 16.0 version
16_742178ed-6b28-42dd-b3d7-b7c0ea78741b_Y9NF9-M2QWD-FF6RJ-QJW36-RR%f%F2T_SubTest_______O365BusinessRetail 16_742178ed-6b28-42dd-b3d7-b7c0ea78741b_Y9NF9-M2QWD-FF6RJ-QJW36-RR%f%F2T_SubTest_______O365BusinessRetail
16_2f5c71b4-5b7a-4005-bb68-f9fac26f2ea3_W62NQ-267QR-RTF74-PF2MH-JQ%f%MTH_Subscription__O365EduCloudRetail 16_2f5c71b4-5b7a-4005-bb68-f9fac26f2ea3_W62NQ-267QR-RTF74-PF2MH-JQ%f%MTH_Subscription__O365EduCloudRetail
16_537ea5b5-7d50-4876-bd38-a53a77caca32_J2W28-TN9C8-26PWV-F7J4G-72%f%XCB_Subscription1_O365HomePremRetail 16_a96f8dae-da54-4fad-bdc6-108da592707a_3NMDC-G7C3W-68RGP-CB4MH-4C%f%XCH_SubTest1______O365HomePremRetail
16_e3dacc06-3bc2-4e13-8e59-8e05f3232325_H8DN8-Y2YP3-CR9JT-DHDR9-C7%f%GP3_Subscription2_O365ProPlusRetail 16_e3dacc06-3bc2-4e13-8e59-8e05f3232325_H8DN8-Y2YP3-CR9JT-DHDR9-C7%f%GP3_Subscription2_O365ProPlusRetail
16_bacd4614-5bef-4a5e-bafc-de4c788037a2_HN8JP-87TQJ-PBF3P-Y66KC-W2%f%K9V_Subscription1_O365SmallBusPremRetail 16_0bc1dae4-6158-4a1c-a893-807665b934b2_2QCNB-RMDKJ-GC8PB-7QGQV-7Q%f%TQJ_Subscription2_O365SmallBusPremRetail
:: Office 2016 :: Office 2016
16_bfa358b0-98f1-4125-842e-585fa13032e6_WHK4N-YQGHB-XWXCC-G3HYC-6J%f%F94_Retail________AccessRetail 16_bfa358b0-98f1-4125-842e-585fa13032e6_WHK4N-YQGHB-XWXCC-G3HYC-6J%f%F94_Retail________AccessRetail
16_9d9faf9e-d345-4b49-afce-68cb0a539c7c_RNB7V-P48F4-3FYY6-2P3R3-63%f%BQV_PrepidBypass__AccessRuntimeRetail 16_9d9faf9e-d345-4b49-afce-68cb0a539c7c_RNB7V-P48F4-3FYY6-2P3R3-63%f%BQV_PrepidBypass__AccessRuntimeRetail
@ -8651,12 +8659,12 @@ if defined UBR (set "fullbuild=%%G.!UBR!") else (set "fullbuild=%%G.%%H")
::======================================================================================================================================== ::========================================================================================================================================
:: Check Activation ID :: Check Activation IDs
call :dk_actid 55c92734-d682-4d71-983e-d6ec3f16059f call :dk_actids 55c92734-d682-4d71-983e-d6ec3f16059f
if not defined apps ( if not defined allapps (
%eline% %eline%
echo Either key is not insalled or script failed to get installed key's activation ID. Aborting... echo Failed to find activation IDs. Aborting...
echo: echo:
set fixes=%fixes% %mas%troubleshoot set fixes=%fixes% %mas%troubleshoot
call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%troubleshoot" call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%troubleshoot"
@ -8670,7 +8678,7 @@ goto dk_done
set osedition= set osedition=
set dismnotworking= set dismnotworking=
for /f "tokens=3 delims=: " %%a in ('DISM /English /Online /Get-CurrentEdition %nul6% ^| find /i "1Current Edition :"') do set "osedition=%%a" for /f "tokens=3 delims=: " %%a in ('DISM /English /Online /Get-CurrentEdition %nul6% ^| find /i "Current Edition :"') do set "osedition=%%a"
if not defined osedition set dismnotworking=1 if not defined osedition set dismnotworking=1
if %_wmic% EQU 1 set "chkedi=for /f "tokens=2 delims==" %%a in ('"wmic path %spp% where (ApplicationID='55c92734-d682-4d71-983e-d6ec3f16059f' AND LicenseDependsOn is NULL AND PartialProductKey IS NOT NULL) get LicenseFamily /VALUE" %nul6%')" if %_wmic% EQU 1 set "chkedi=for /f "tokens=2 delims==" %%a in ('"wmic path %spp% where (ApplicationID='55c92734-d682-4d71-983e-d6ec3f16059f' AND LicenseDependsOn is NULL AND PartialProductKey IS NOT NULL) get LicenseFamily /VALUE" %nul6%')"
@ -10259,10 +10267,7 @@ call :oe_tempcleanup
echo: echo:
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))

View File

@ -211,9 +211,9 @@ goto dk_done
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -663,29 +663,42 @@ call :dk_color %Red% "Generating New IdentityCRL Registry [Failed] [%_ident%
reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" /v DisableWindowsUpdateAccess %nul2% | find /i "0x1" %nul% && set wublock=1 reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" /v DisableWindowsUpdateAccess %nul2% | find /i "0x1" %nul% && set wublock=1
reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" /v DoNotConnectToWindowsUpdateInternetLocations %nul2% | find /i "0x1" %nul% && set wublock=1 reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" /v DoNotConnectToWindowsUpdateInternetLocations %nul2% | find /i "0x1" %nul% && set wublock=1
if defined wublock call :dk_color %Red% "Checking Update Blocker In Registry [Found]" if defined wublock (
call :dk_color %Red% "Checking Update Blocker In Registry [Found]"
call :dk_color %Blue% "HWID activation needs working Windows updates, if you have used any tool to block updates, undo it."
)
reg query "HKLM\SOFTWARE\Policies\Microsoft\WindowsStore" /v DisableStoreApps %nul2% | find /i "0x1" %nul% && ( reg query "HKLM\SOFTWARE\Policies\Microsoft\WindowsStore" /v DisableStoreApps %nul2% | find /i "0x1" %nul% && (
set storeblock=1 set storeblock=1
call :dk_color %Red% "Checking Store Blocker In Registry [Found]" call :dk_color %Red% "Checking Store Blocker In Registry [Found]"
call :dk_color %Blue% "If you have used any tool to block Store, undo it."
) )
set wcount=0
for %%G in (DependOnService Description DisplayName ErrorControl ImagePath ObjectName Start Type ServiceSidType RequiredPrivileges FailureActions) do if not defined wucorrupt ( for %%G in (DependOnService Description DisplayName ErrorControl ImagePath ObjectName Start Type ServiceSidType RequiredPrivileges FailureActions) do if not defined wucorrupt (
reg query HKLM\SYSTEM\CurrentControlSet\Services\wuauserv /v %%G %nul% || set wucorrupt=1 reg query HKLM\SYSTEM\CurrentControlSet\Services\wuauserv /v %%G %nul% || (set wucorrupt=1&set /a wcount+=1)
) )
for %%G in (Parameters Security TriggerInfo) do if not defined wucorrupt ( for %%G in (Parameters Security) do if not defined wucorrupt (
reg query HKLM\SYSTEM\CurrentControlSet\Services\wuauserv\%%G %nul% || set wucorrupt=1 reg query HKLM\SYSTEM\CurrentControlSet\Services\wuauserv\%%G %nul% || (set wucorrupt=1&set /a wcount+=1)
) )
if defined wucorrupt ( if defined wucorrupt (
call :dk_color %Red% "Checking Windows Update Registry [Corruption Found]" 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% %mas%remove_mal%w%ware
call :dk_color2 %Blue% "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."
)
) else ( ) else (
%psc% "Start-Job { Start-Service wuauserv } | Wait-Job -Timeout 20 | Out-Null" %psc% "Start-Job { Start-Service wuauserv } | Wait-Job -Timeout 20 | Out-Null"
sc query wuauserv | find /i "RUNNING" %nul% || ( sc query wuauserv | find /i "RUNNING" %nul% || (
set wuerror=1 set wuerror=1
sc start wuauserv %nul% sc start wuauserv %nul%
call :dk_color %Red% "Starting Windows Update Service [Failed] [!errorlevel!]" call :dk_color %Red% "Starting Windows Update Service [Failed] [!errorlevel!]"
call :dk_color %Blue% "HWID activation needs working Windows updates, if you have used any tool to block updates, undo it."
) )
) )
@ -1614,10 +1627,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))

View File

@ -214,9 +214,9 @@ goto dk_done
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -1779,10 +1779,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))

View File

@ -204,9 +204,9 @@ goto dk_done
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -1175,7 +1175,6 @@ rmdir /s /q "%ProgramData%\Microsoft\Office\Licenses\" %nul%
for %%x in (15 16) do ( for %%x in (15 16) do (
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Licensing /f %nul% reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Licensing /f %nul%
reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Identity /f %nul%
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do ( for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do (
rmdir /s /q "%%b\AppData\Local\Microsoft\Office\Licenses\" %nul% rmdir /s /q "%%b\AppData\Local\Microsoft\Office\Licenses\" %nul%
@ -1198,7 +1197,6 @@ if exist "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\Syst
set defname=DEFTEMP-%%# set defname=DEFTEMP-%%#
reg load HKU\!defname! "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\SystemAppData\Helium\User.dat" %nul% reg load HKU\!defname! "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\SystemAppData\Helium\User.dat" %nul%
reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Licensing /f %nul% reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Licensing /f %nul%
reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Identity /f %nul%
reg unload HKU\!defname! %nul% reg unload HKU\!defname! %nul%
) )
) )
@ -2110,10 +2108,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
@ -2190,15 +2185,15 @@ for %%# in (
15_9cedef15-be37-4ff0-a08a-13a045540641_RPHPB-Y7NC4-3VYFM-DW7VD-G8%f%YJ8_MAK___________WordVolume 15_9cedef15-be37-4ff0-a08a-13a045540641_RPHPB-Y7NC4-3VYFM-DW7VD-G8%f%YJ8_MAK___________WordVolume
:: Office 365 - 15.0 version :: Office 365 - 15.0 version
15_742178ed-6b28-42dd-b3d7-b7c0ea78741b_Y9NF9-M2QWD-FF6RJ-QJW36-RR%f%F2T_SubTest_______O365BusinessRetail 15_742178ed-6b28-42dd-b3d7-b7c0ea78741b_Y9NF9-M2QWD-FF6RJ-QJW36-RR%f%F2T_SubTest_______O365BusinessRetail
15_537ea5b5-7d50-4876-bd38-a53a77caca32_J2W28-TN9C8-26PWV-F7J4G-72%f%XCB_Subscription1_O365HomePremRetail 15_a96f8dae-da54-4fad-bdc6-108da592707a_3NMDC-G7C3W-68RGP-CB4MH-4C%f%XCH_SubTest1______O365HomePremRetail
15_e3dacc06-3bc2-4e13-8e59-8e05f3232325_H8DN8-Y2YP3-CR9JT-DHDR9-C7%f%GP3_Subscription2_O365ProPlusRetail 15_e3dacc06-3bc2-4e13-8e59-8e05f3232325_H8DN8-Y2YP3-CR9JT-DHDR9-C7%f%GP3_Subscription2_O365ProPlusRetail
15_bacd4614-5bef-4a5e-bafc-de4c788037a2_HN8JP-87TQJ-PBF3P-Y66KC-W2%f%K9V_Subscription1_O365SmallBusPremRetail 15_0bc1dae4-6158-4a1c-a893-807665b934b2_2QCNB-RMDKJ-GC8PB-7QGQV-7Q%f%TQJ_Subscription2_O365SmallBusPremRetail
:: Office 365 - 16.0 version :: Office 365 - 16.0 version
16_742178ed-6b28-42dd-b3d7-b7c0ea78741b_Y9NF9-M2QWD-FF6RJ-QJW36-RR%f%F2T_SubTest_______O365BusinessRetail 16_742178ed-6b28-42dd-b3d7-b7c0ea78741b_Y9NF9-M2QWD-FF6RJ-QJW36-RR%f%F2T_SubTest_______O365BusinessRetail
16_2f5c71b4-5b7a-4005-bb68-f9fac26f2ea3_W62NQ-267QR-RTF74-PF2MH-JQ%f%MTH_Subscription__O365EduCloudRetail 16_2f5c71b4-5b7a-4005-bb68-f9fac26f2ea3_W62NQ-267QR-RTF74-PF2MH-JQ%f%MTH_Subscription__O365EduCloudRetail
16_537ea5b5-7d50-4876-bd38-a53a77caca32_J2W28-TN9C8-26PWV-F7J4G-72%f%XCB_Subscription1_O365HomePremRetail 16_a96f8dae-da54-4fad-bdc6-108da592707a_3NMDC-G7C3W-68RGP-CB4MH-4C%f%XCH_SubTest1______O365HomePremRetail
16_e3dacc06-3bc2-4e13-8e59-8e05f3232325_H8DN8-Y2YP3-CR9JT-DHDR9-C7%f%GP3_Subscription2_O365ProPlusRetail 16_e3dacc06-3bc2-4e13-8e59-8e05f3232325_H8DN8-Y2YP3-CR9JT-DHDR9-C7%f%GP3_Subscription2_O365ProPlusRetail
16_bacd4614-5bef-4a5e-bafc-de4c788037a2_HN8JP-87TQJ-PBF3P-Y66KC-W2%f%K9V_Subscription1_O365SmallBusPremRetail 16_0bc1dae4-6158-4a1c-a893-807665b934b2_2QCNB-RMDKJ-GC8PB-7QGQV-7Q%f%TQJ_Subscription2_O365SmallBusPremRetail
:: Office 2016 :: Office 2016
16_bfa358b0-98f1-4125-842e-585fa13032e6_WHK4N-YQGHB-XWXCC-G3HYC-6J%f%F94_Retail________AccessRetail 16_bfa358b0-98f1-4125-842e-585fa13032e6_WHK4N-YQGHB-XWXCC-G3HYC-6J%f%F94_Retail________AccessRetail
16_9d9faf9e-d345-4b49-afce-68cb0a539c7c_RNB7V-P48F4-3FYY6-2P3R3-63%f%BQV_PrepidBypass__AccessRuntimeRetail 16_9d9faf9e-d345-4b49-afce-68cb0a539c7c_RNB7V-P48F4-3FYY6-2P3R3-63%f%BQV_PrepidBypass__AccessRuntimeRetail

View File

@ -233,9 +233,9 @@ goto dk_done
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -1328,7 +1328,6 @@ rmdir /s /q "%ProgramData%\Microsoft\Office\Licenses\" %nul%
for %%x in (15 16) do ( for %%x in (15 16) do (
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Licensing /f %nul% reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Licensing /f %nul%
reg delete HKU\%%#\Software\Microsoft\Office\%%x.0\Common\Identity /f %nul%
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do ( for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do (
rmdir /s /q "%%b\AppData\Local\Microsoft\Office\Licenses\" %nul% rmdir /s /q "%%b\AppData\Local\Microsoft\Office\Licenses\" %nul%
@ -1351,7 +1350,6 @@ if exist "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\Syst
set defname=DEFTEMP-%%# set defname=DEFTEMP-%%#
reg load HKU\!defname! "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\SystemAppData\Helium\User.dat" %nul% reg load HKU\!defname! "%%b\AppData\Local\Packages\Microsoft.Office.Desktop_8wekyb3d8bbwe\SystemAppData\Helium\User.dat" %nul%
reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Licensing /f %nul% reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Licensing /f %nul%
reg delete HKU\!defname!\Software\Microsoft\Office\16.0\Common\Identity /f %nul%
reg unload HKU\!defname! %nul% reg unload HKU\!defname! %nul%
) )
) )
@ -3211,10 +3209,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))

View File

@ -164,9 +164,9 @@ goto dk_done
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -1064,10 +1064,7 @@ call :oe_tempcleanup
echo: echo:
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
@ -1420,10 +1417,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))

View File

@ -169,9 +169,9 @@ goto dk_done
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -336,12 +336,12 @@ if defined UBR (set "fullbuild=%%G.!UBR!") else (set "fullbuild=%%G.%%H")
::======================================================================================================================================== ::========================================================================================================================================
:: Check Activation ID :: Check Activation IDs
call :dk_actid 55c92734-d682-4d71-983e-d6ec3f16059f call :dk_actids 55c92734-d682-4d71-983e-d6ec3f16059f
if not defined apps ( if not defined allapps (
%eline% %eline%
echo Either key is not insalled or script failed to get installed key's activation ID. Aborting... echo Failed to find activation IDs. Aborting...
echo: echo:
set fixes=%fixes% %mas%troubleshoot set fixes=%fixes% %mas%troubleshoot
call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%troubleshoot" call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%troubleshoot"
@ -355,7 +355,7 @@ goto dk_done
set osedition= set osedition=
set dismnotworking= set dismnotworking=
for /f "tokens=3 delims=: " %%a in ('DISM /English /Online /Get-CurrentEdition %nul6% ^| find /i "1Current Edition :"') do set "osedition=%%a" for /f "tokens=3 delims=: " %%a in ('DISM /English /Online /Get-CurrentEdition %nul6% ^| find /i "Current Edition :"') do set "osedition=%%a"
if not defined osedition set dismnotworking=1 if not defined osedition set dismnotworking=1
if %_wmic% EQU 1 set "chkedi=for /f "tokens=2 delims==" %%a in ('"wmic path %spp% where (ApplicationID='55c92734-d682-4d71-983e-d6ec3f16059f' AND LicenseDependsOn is NULL AND PartialProductKey IS NOT NULL) get LicenseFamily /VALUE" %nul6%')" if %_wmic% EQU 1 set "chkedi=for /f "tokens=2 delims==" %%a in ('"wmic path %spp% where (ApplicationID='55c92734-d682-4d71-983e-d6ec3f16059f' AND LicenseDependsOn is NULL AND PartialProductKey IS NOT NULL) get LicenseFamily /VALUE" %nul6%')"
@ -834,14 +834,14 @@ if %_wmic% EQU 1 wmic path %sps% where __CLASS='%sps%' call RefreshLicenseStatus
if %_wmic% EQU 0 %psc% "$null=(([WMICLASS]'%sps%').GetInstances()).RefreshLicenseStatus()" %nul% if %_wmic% EQU 0 %psc% "$null=(([WMICLASS]'%sps%').GetInstances()).RefreshLicenseStatus()" %nul%
exit /b exit /b
:: Get installed products Activation IDs :: Get all products Activation IDs
:dk_actid :dk_actids
set apps= set allapps=
if %_wmic% EQU 1 set "chkapp=for /f "tokens=2 delims==" %%a in ('"wmic path %spp% where (ApplicationID='%1' and PartialProductKey is not null) get ID /VALUE" %nul6%')" if %_wmic% EQU 1 set "chkapp=for /f "tokens=2 delims==" %%a in ('"wmic path %spp% where (ApplicationID='%1') get ID /VALUE" %nul6%')"
if %_wmic% EQU 0 set "chkapp=for /f "tokens=2 delims==" %%a in ('%psc% "(([WMISEARCHER]'SELECT ID FROM %spp% WHERE ApplicationID=''%1'' AND PartialProductKey IS NOT NULL').Get()).ID ^| %% {echo ('ID='+$_)}" %nul6%')" if %_wmic% EQU 0 set "chkapp=for /f "tokens=2 delims==" %%a in ('%psc% "(([WMISEARCHER]'SELECT ID FROM %spp% WHERE ApplicationID=''%1''').Get()).ID ^| %% {echo ('ID='+$_)}" %nul6%')"
%chkapp% do (if defined apps (call set "apps=!apps! %%a") else (call set "apps=%%a")) %chkapp% do (if defined allapps (call set "allapps=!allapps! %%a") else (call set "allapps=%%a"))
exit /b exit /b
:: Get Edition list :: Get Edition list
@ -996,10 +996,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))

View File

@ -163,9 +163,9 @@ goto done2
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -707,10 +707,7 @@ echo ______________________________________________________________
echo: echo:
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))

View File

@ -164,9 +164,9 @@ goto dk_done
:: Check PowerShell :: Check PowerShell
REM :PowerShellTest: $ExecutionContext.SessionState.LanguageMode :PowerShellTest: REM :PStest: $ExecutionContext.SessionState.LanguageMode :PStest:
cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PowerShellTest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || ( cmd /c "%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':PStest:\s*';iex ($f[1])"" | find /i "FullLanguage" %nul1% || (
%eline% %eline%
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode""
echo: echo:
@ -1384,10 +1384,7 @@ $key.SetAccessControl($acl)
echo: echo:
if defined fixes ( if defined fixes (
call :dk_color %White% " "
call :dk_color %White% "Follow ALL the ABOVE blue lines. " call :dk_color %White% "Follow ALL the ABOVE blue lines. "
call :dk_color %White% " "
echo:
call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))

View File

@ -36,7 +36,10 @@ irm https://massgrave.dev/get | iex
<details> <details>
<summary>Click here for info</summary> <summary>Click here for info</summary>
1. Download the file under the code button from [GitHub](https://github.com/massgravel/Microsoft-Activation-Scripts) or [Azure DevOps](https://dev.azure.com/massgrave/_git/Microsoft-Activation-Scripts) or [Self-hosted Git](https://git.activated.win/massgrave/Microsoft-Activation-Scripts) 1. Download the file using the links provided below.
`https://github.com/massgravel/Microsoft-Activation-Scripts/archive/refs/heads/master.zip`
or
`https://git.activated.win/massgrave/Microsoft-Activation-Scripts/archive/master.zip`
2. Right-click on the downloaded zip file and extract 2. Right-click on the downloaded zip file and extract
3. In the extracted folder, find the folder named `All-In-One-Version` 3. In the extracted folder, find the folder named `All-In-One-Version`
4. Run the file named `MAS_AIO.cmd` 4. Run the file named `MAS_AIO.cmd`