Browse Source

Improve/Fix error messages when key is not found

pull/542/head
WindowsAddict 5 months ago
parent
commit
3d16fc6a07
  1. 22
      MAS/Separate-Files-Version/Activators/HWID_Activation.cmd
  2. 21
      MAS/Separate-Files-Version/Activators/KMS38_Activation.cmd
  3. 7
      MAS/Separate-Files-Version/Activators/Ohook_Activation_AIO.cmd
  4. 21
      MAS/Separate-Files-Version/Activators/Online_KMS_Activation.cmd

22
MAS/Separate-Files-Version/Activators/HWID_Activation.cmd

@ -428,7 +428,6 @@ call :dk_errorcheck
set key= set key=
set altkey= set altkey=
set skufound=
set changekey= set changekey=
set altapplist= set altapplist=
set altedition= set altedition=
@ -453,14 +452,17 @@ call :dk_color %Red% "Checking Alternate Edition For HWID [%altedition% Acti
if not defined key ( if not defined key (
%eline% %eline%
echo [%winos% ^| %winbuild% ^| SKU:%osSKU%] echo [%winos% ^| %winbuild% ^| SKU:%osSKU%]
if not defined skufound ( if not defined skunotfound (
echo Unable to find this product in the supported product list. echo This product does not support HWID Activation.
) else ( echo Try KMS38 Activation option.
echo Required License files not found in %SysPath%\spp\tokens\skus\
)
echo Make sure you are using updated version of the script. echo Make sure you are using updated version of the script.
set fixes=%fixes% %mas% set fixes=%fixes% %mas%
echo %mas% echo %mas%
) else (
echo Required License files not found in %SysPath%\spp\tokens\skus\
set fixes=%fixes% %mas%troubleshoot
call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%troubleshoot"
)
echo: echo:
goto dk_done goto dk_done
) )
@ -1242,23 +1244,24 @@ call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%evaluation-editions"
) )
set osedition= set osedition=0
for /f "skip=2 tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul6%') do set "osedition=%%a" for /f "skip=2 tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul6%') do set "osedition=%%a"
:: Workaround for an issue in builds between 1607 and 1709 where ProfessionalEducation is shown as Professional :: Workaround for an issue in builds between 1607 and 1709 where ProfessionalEducation is shown as Professional
if defined osedition ( if not %osedition%==0 (
if "%osSKU%"=="164" set osedition=ProfessionalEducation if "%osSKU%"=="164" set osedition=ProfessionalEducation
if "%osSKU%"=="165" set osedition=ProfessionalEducationN if "%osSKU%"=="165" set osedition=ProfessionalEducationN
) )
if not defined officeact ( if not defined officeact (
if not defined osedition ( if %osedition%==0 (
call :dk_color %Red% "Checking Edition Name [Not Found In Registry]" call :dk_color %Red% "Checking Edition Name [Not Found In Registry]"
) else ( ) else (
if not exist "%SysPath%\spp\tokens\skus\%osedition%\%osedition%*.xrm-ms" if not exist "%SysPath%\spp\tokens\skus\Security-SPP-Component-SKU-%osedition%\*-%osedition%-*.xrm-ms" ( if not exist "%SysPath%\spp\tokens\skus\%osedition%\%osedition%*.xrm-ms" if not exist "%SysPath%\spp\tokens\skus\Security-SPP-Component-SKU-%osedition%\*-%osedition%-*.xrm-ms" (
set error=1 set error=1
set skunotfound=1
call :dk_color %Red% "Checking License Files [Not Found] [%osedition%]" call :dk_color %Red% "Checking License Files [Not Found] [%osedition%]"
) )
@ -1628,7 +1631,6 @@ for /f "tokens=1-9 delims=_" %%A in ("%%#") do (
REM Detect key REM Detect key
if %1==key if %osSKU%==%%C if not defined key ( if %1==key if %osSKU%==%%C if not defined key (
set skufound=1
echo "!allapps! !altapplist!" | find /i "%%A" %nul1% && ( echo "!allapps! !altapplist!" | find /i "%%A" %nul1% && (
if %%F==1 set notworking=1 if %%F==1 set notworking=1
set key=%%B set key=%%B

21
MAS/Separate-Files-Version/Activators/KMS38_Activation.cmd

@ -473,7 +473,6 @@ call :k_channel
set key= set key=
set pkey= set pkey=
set altkey= set altkey=
set skufound=
set changekey= set changekey=
set altedition= set altedition=
@ -499,14 +498,16 @@ call :dk_color %Red% "Checking Alternate Edition For KMS38 [%altedition% Acti
if not defined key if not defined _gvlk ( if not defined key if not defined _gvlk (
%eline% %eline%
echo [%winos% ^| %winbuild% ^| SKU:%osSKU%] echo [%winos% ^| %winbuild% ^| SKU:%osSKU%]
if not defined skufound ( if not defined skunotfound (
echo Unable to find this product in the supported product list. echo This product does not support KMS38 Activation.
) else (
echo Required License files not found in %SysPath%\spp\tokens\skus\
)
echo Make sure you are using updated version of the script. echo Make sure you are using updated version of the script.
set fixes=%fixes% %mas% set fixes=%fixes% %mas%
echo %mas% echo %mas%
) else (
echo Required License files not found in %SysPath%\spp\tokens\skus\
set fixes=%fixes% %mas%troubleshoot
call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%troubleshoot"
)
echo: echo:
goto dk_done goto dk_done
) )
@ -1381,23 +1382,24 @@ call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%evaluation-editions"
) )
set osedition= set osedition=0
for /f "skip=2 tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul6%') do set "osedition=%%a" for /f "skip=2 tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul6%') do set "osedition=%%a"
:: Workaround for an issue in builds between 1607 and 1709 where ProfessionalEducation is shown as Professional :: Workaround for an issue in builds between 1607 and 1709 where ProfessionalEducation is shown as Professional
if defined osedition ( if not %osedition%==0 (
if "%osSKU%"=="164" set osedition=ProfessionalEducation if "%osSKU%"=="164" set osedition=ProfessionalEducation
if "%osSKU%"=="165" set osedition=ProfessionalEducationN if "%osSKU%"=="165" set osedition=ProfessionalEducationN
) )
if not defined officeact ( if not defined officeact (
if not defined osedition ( if %osedition%==0 (
call :dk_color %Red% "Checking Edition Name [Not Found In Registry]" call :dk_color %Red% "Checking Edition Name [Not Found In Registry]"
) else ( ) else (
if not exist "%SysPath%\spp\tokens\skus\%osedition%\%osedition%*.xrm-ms" if not exist "%SysPath%\spp\tokens\skus\Security-SPP-Component-SKU-%osedition%\*-%osedition%-*.xrm-ms" ( if not exist "%SysPath%\spp\tokens\skus\%osedition%\%osedition%*.xrm-ms" if not exist "%SysPath%\spp\tokens\skus\Security-SPP-Component-SKU-%osedition%\*-%osedition%-*.xrm-ms" (
set error=1 set error=1
set skunotfound=1
call :dk_color %Red% "Checking License Files [Not Found] [%osedition%]" call :dk_color %Red% "Checking License Files [Not Found] [%osedition%]"
) )
@ -1780,7 +1782,6 @@ c2e946d1-cfa2-4523-8c87-30bc696ee584_XGN3F-F394H-FD2MY-PP6FD-8M%f%CRC_407_Server
19b5e0fb-4431-46bc-bac1-2f1873e4ae73_NTBV8-9K7Q8-V27C6-M2BTV-KH%f%MXV_407_ServerTurbine_RS5 19b5e0fb-4431-46bc-bac1-2f1873e4ae73_NTBV8-9K7Q8-V27C6-M2BTV-KH%f%MXV_407_ServerTurbine_RS5
) do ( ) do (
for /f "tokens=1-5 delims=_" %%A in ("%%#") do if %osSKU%==%%C ( for /f "tokens=1-5 delims=_" %%A in ("%%#") do if %osSKU%==%%C (
set skufound=1
if %1==key if not defined key echo "!allapps!" | find /i "%%A" %nul1% && set key=%%B if %1==key if not defined key echo "!allapps!" | find /i "%%A" %nul1% && set key=%%B
) )
) )

7
MAS/Separate-Files-Version/Activators/Ohook_Activation_AIO.cmd

@ -1686,23 +1686,24 @@ call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%evaluation-editions"
) )
set osedition= set osedition=0
for /f "skip=2 tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul6%') do set "osedition=%%a" for /f "skip=2 tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul6%') do set "osedition=%%a"
:: Workaround for an issue in builds between 1607 and 1709 where ProfessionalEducation is shown as Professional :: Workaround for an issue in builds between 1607 and 1709 where ProfessionalEducation is shown as Professional
if defined osedition ( if not %osedition%==0 (
if "%osSKU%"=="164" set osedition=ProfessionalEducation if "%osSKU%"=="164" set osedition=ProfessionalEducation
if "%osSKU%"=="165" set osedition=ProfessionalEducationN if "%osSKU%"=="165" set osedition=ProfessionalEducationN
) )
if not defined officeact ( if not defined officeact (
if not defined osedition ( if %osedition%==0 (
call :dk_color %Red% "Checking Edition Name [Not Found In Registry]" call :dk_color %Red% "Checking Edition Name [Not Found In Registry]"
) else ( ) else (
if not exist "%SysPath%\spp\tokens\skus\%osedition%\%osedition%*.xrm-ms" if not exist "%SysPath%\spp\tokens\skus\Security-SPP-Component-SKU-%osedition%\*-%osedition%-*.xrm-ms" ( if not exist "%SysPath%\spp\tokens\skus\%osedition%\%osedition%*.xrm-ms" if not exist "%SysPath%\spp\tokens\skus\Security-SPP-Component-SKU-%osedition%\*-%osedition%-*.xrm-ms" (
set error=1 set error=1
set skunotfound=1
call :dk_color %Red% "Checking License Files [Not Found] [%osedition%]" call :dk_color %Red% "Checking License Files [Not Found] [%osedition%]"
) )

21
MAS/Separate-Files-Version/Activators/Online_KMS_Activation.cmd

@ -524,7 +524,6 @@ call :k_channel
set key= set key=
set pkey= set pkey=
set altkey= set altkey=
set skufound=
set changekey= set changekey=
set altedition= set altedition=
@ -539,7 +538,7 @@ set /a UBR=0
if %osSKU%==191 if defined altkey if defined altedition ( if %osSKU%==191 if defined altkey if defined altedition (
for /f "skip=2 tokens=2*" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v UBR %nul6%') do if not errorlevel 1 set /a UBR=%%b for /f "skip=2 tokens=2*" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v UBR %nul6%') do if not errorlevel 1 set /a UBR=%%b
if %winbuild% LSS 22598 if !UBR! LSS 2788 ( if %winbuild% LSS 22598 if !UBR! LSS 2788 (
call :dk_color %Blue% "Windows must to be updated to build 19044.2788 or higher for IotEnterpriseS KMS38 activation." call :dk_color %Blue% "Windows must to be updated to build 19044.2788 or higher for IotEnterpriseS %KS% activation."
) )
) )
@ -549,14 +548,16 @@ call :dk_color %Red% "Checking Alternate Edition For %KS% [%altedition% Act
if not defined key if not defined _gvlk ( if not defined key if not defined _gvlk (
echo [%winos% ^| %winbuild% ^| SKU:%osSKU%] echo [%winos% ^| %winbuild% ^| SKU:%osSKU%]
if not defined skufound ( if not defined skunotfound (
call :dk_color %Red% "Unable to find this product in the supported product list." echo This product does not support %KS% Activation.
echo:
set fixes=%fixes% %mas%unsupported_products_activation set fixes=%fixes% %mas%unsupported_products_activation
call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%unsupported_products_activation" call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%unsupported_products_activation"
) else ( ) else (
echo Required License files not found in %SysPath%\spp\tokens\skus\ echo Required License files not found in %SysPath%\spp\tokens\skus\
set fixes=%fixes% %mas%troubleshoot
call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%troubleshoot"
) )
echo:
goto :ks_office goto :ks_office
) )
@ -653,9 +654,7 @@ if defined ohub (
echo: echo:
echo You have only Office dashboard app installed, you need to install full Office version. echo You have only Office dashboard app installed, you need to install full Office version.
) )
echo:
call :dk_color %Blue% "Download and install Office from below URL and try again." call :dk_color %Blue% "Download and install Office from below URL and try again."
echo:
set fixes=%fixes% %mas%genuine-installation-media set fixes=%fixes% %mas%genuine-installation-media
call :dk_color %_Yellow% "%mas%genuine-installation-media" call :dk_color %_Yellow% "%mas%genuine-installation-media"
goto :ks_activate goto :ks_activate
@ -2694,23 +2693,24 @@ call :dk_color2 %Blue% "Help - " %_Yellow% " %mas%evaluation-editions"
) )
set osedition= set osedition=0
for /f "skip=2 tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul6%') do set "osedition=%%a" for /f "skip=2 tokens=3" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion" /v EditionID %nul6%') do set "osedition=%%a"
:: Workaround for an issue in builds between 1607 and 1709 where ProfessionalEducation is shown as Professional :: Workaround for an issue in builds between 1607 and 1709 where ProfessionalEducation is shown as Professional
if defined osedition ( if not %osedition%==0 (
if "%osSKU%"=="164" set osedition=ProfessionalEducation if "%osSKU%"=="164" set osedition=ProfessionalEducation
if "%osSKU%"=="165" set osedition=ProfessionalEducationN if "%osSKU%"=="165" set osedition=ProfessionalEducationN
) )
if not defined officeact ( if not defined officeact (
if not defined osedition ( if %osedition%==0 (
call :dk_color %Red% "Checking Edition Name [Not Found In Registry]" call :dk_color %Red% "Checking Edition Name [Not Found In Registry]"
) else ( ) else (
if not exist "%SysPath%\spp\tokens\skus\%osedition%\%osedition%*.xrm-ms" if not exist "%SysPath%\spp\tokens\skus\Security-SPP-Component-SKU-%osedition%\*-%osedition%-*.xrm-ms" ( if not exist "%SysPath%\spp\tokens\skus\%osedition%\%osedition%*.xrm-ms" if not exist "%SysPath%\spp\tokens\skus\Security-SPP-Component-SKU-%osedition%\*-%osedition%-*.xrm-ms" (
set error=1 set error=1
set skunotfound=1
call :dk_color %Red% "Checking License Files [Not Found] [%osedition%]" call :dk_color %Red% "Checking License Files [Not Found] [%osedition%]"
) )
@ -3407,7 +3407,6 @@ d0eded01-0881-4b37-9738-190400095098_MQ84N-7VYDM-FXV7C-6K7CC-VF%f%W9J__16_Word20
for /f "tokens=1-5 delims=_" %%A in ("%%#") do ( for /f "tokens=1-5 delims=_" %%A in ("%%#") do (
if %1==winkey if %osSKU%==%%C if not defined key ( if %1==winkey if %osSKU%==%%C if not defined key (
set skufound=1
echo "!allapps!" | find /i "%%A" %nul1% && set key=%%B echo "!allapps!" | find /i "%%A" %nul1% && set key=%%B
) )

Loading…
Cancel
Save