11@ echo off
22rem Display info and license
33color f0
4- echo Telemetry Kill Script 1.0 .0
4+ echo Telemetry Kill Script 1.1 .0
55echo A tool for disabling Windows Telemetry (at least part of it).
66echo https://github.com/DavisNT/Telemetry-Kill-Script
77echo .
8- echo Copyright (c) 2017 Davis Mosenkovs
8+ echo Copyright (c) 2017-2019 Davis Mosenkovs
99echo .
1010echo Permission is hereby granted, free of charge, to any person obtaining a copy
1111echo of this software and associated documentation files (the " Software" ), to deal
@@ -33,6 +33,9 @@ if not "%1"=="/AUTO" if not "%1"=="/auto" set /P accepted=Press enter if you agr
3333if not " %accepted% " == " " goto :end
3434echo .
3535
36+ rem Check 64-bit environment on 64-bit Windows
37+ if not " %PROCESSOR_ARCHITEW6432% " == " " goto :wow
38+
3639rem Check admin rights
3740net session > nul 2 > nul
3841if errorlevel 1 goto :noadmin
@@ -51,6 +54,10 @@ if errorlevel 1 set errors=1
5154icacls %SystemRoot% \system32\GeneralTel.dll /deny *S-1-1-0:(X)
5255if errorlevel 1 set errors = 1
5356echo .
57+ echo Setting diagnostic data level to Security/Basic (lowest possible)...
58+ reg add " HKLM\Software\Policies\Microsoft\Windows\DataCollection" /v AllowTelemetry /t REG_DWORD /d 0 /f
59+ if errorlevel 1 set errors = 1
60+ echo .
5461echo Disabling Telemetry service...
5562sc config DiagTrack start= disabled
5663if errorlevel 1 set errors = 1
@@ -69,18 +76,28 @@ if "%errors%"=="1" goto :errors
6976rem Success
7077color f2
7178echo Telemetry should be disabled now.
79+ echo You might need to reboot your computer for some of the changes to take effect.
7280if not " %1 " == " /AUTO" if not " %1 " == " /auto" pause
7381
7482goto :end
7583
76- rem Errors occured
84+ rem Errors occurred
7785:errors
7886color fc
7987echo Error(s) occurred, please review the script output!
8088if not " %1 " == " /AUTO" if not " %1 " == " /auto" pause
8189
8290goto :end
8391
92+ rem 32-bit environment on 64-bit Windows error
93+ :wow
94+ color fc
95+ echo This script must NOT be run from 32-bit environment on 64-bit Windows.
96+ echo Please run this script from 64-bit application (e.g. File Explorer window).
97+ if not " %1 " == " /AUTO" if not " %1 " == " /auto" pause
98+
99+ goto :end
100+
84101rem Missing admin rights error
85102:noadmin
86103color fc
0 commit comments