diff options
| author | WindowsAddict <[email protected]> | 2024-08-17 07:17:04 +0530 |
|---|---|---|
| committer | WindowsAddict <[email protected]> | 2024-08-17 07:17:04 +0530 |
| commit | 73eabbff59964ef0386c014e5256d33981211f1a (patch) | |
| tree | b42cf1d321e2dea3a7813edc1eb42ce1a2f0d97c /MAS/Separate-Files-Version/Troubleshoot.cmd | |
| parent | bc5efae19d9b10efcdb1777489c03f4eaacf5f7e (diff) | |
| download | Microsoft-Activation-Scripts-73eabbff59964ef0386c014e5256d33981211f1a.zip | |
Remove WPA check
Already present in activation scripts
Diffstat (limited to 'MAS/Separate-Files-Version/Troubleshoot.cmd')
| -rw-r--r-- | MAS/Separate-Files-Version/Troubleshoot.cmd | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/MAS/Separate-Files-Version/Troubleshoot.cmd b/MAS/Separate-Files-Version/Troubleshoot.cmd index 72b7b2c..27070aa 100644 --- a/MAS/Separate-Files-Version/Troubleshoot.cmd +++ b/MAS/Separate-Files-Version/Troubleshoot.cmd @@ -613,15 +613,6 @@ call :dk_color %Red% "tokens.dat file not found." echo tokens.dat file: [%token%]
)
-echo:
-set wpainfo=
-for /f "delims=" %%a in ('%psc% "$f=[io.file]::ReadAllText('!_batp!') -split ':wpatest\:.*';iex ($f[1]);" %nul6%') do (set wpainfo=%%a)
-echo "%wpainfo%" | find /i "Error Found" %nul% && (
-call :dk_color %Red% "WPA Registry Error: %wpainfo%"
-) || (
-echo WPA Registry Count: %wpainfo%
-)
-
set tokenstore=
for /f "skip=2 tokens=2*" %%a in ('reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v TokenStore %nul6%') do call set "tokenstore=%%b"
@@ -1109,44 +1100,6 @@ exit /b ::========================================================================================================================================
-:: This code checks for invalid registry keys in HKLM\SYSTEM\WPA. This issue may appear even on healthy systems
-
-:wpatest:
-$wpaKey = [Microsoft.Win32.RegistryKey]::OpenBaseKey('LocalMachine', 'Registry64').OpenSubKey("SYSTEM\\WPA")
-$count = $wpaKey.SubKeyCount
-
-$osVersion = [System.Environment]::OSVersion.Version
-$minBuildNumber = 14393
-
-if ($osVersion.Build -ge $minBuildNumber) {
- $subkeyHashTable = @{}
- foreach ($subkeyName in $wpaKey.GetSubKeyNames()) {
- $keyNumber = $subkeyName -replace '.*-', ''
- $subkeyHashTable[$keyNumber] = $true
- }
- for ($i=1; $i -le $count; $i++) {
- if (-not $subkeyHashTable.ContainsKey("$i")) {
- Write-Host "Total Keys $count. Error Found- $i key does not exist"
- $wpaKey.Close()
- exit
- }
- }
-}
-$wpaKey.GetSubKeyNames() | ForEach-Object {
- $subkey = $wpaKey.OpenSubKey($_)
- $p = $subkey.GetValueNames()
- if (($p | Where-Object { $subkey.GetValueKind($_) -eq [Microsoft.Win32.RegistryValueKind]::Binary }).Count -eq 0) {
- Write-Host "Total Keys $count. Error Found- Binary Data is corrupt"
- $wpaKey.Close()
- exit
- }
-}
-$count
-$wpaKey.Close()
-:wpatest:
-
-::========================================================================================================================================
-
:checkperms
set permerror=
|
