forked from coresh/DisableWinSvcs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdiswinsvc.bat
210 lines (165 loc) · 5.99 KB
/
diswinsvc.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
echo off
:: BatchGotAdmin
:-------------------------------------
REM --> Check for permissions
IF "%PROCESSOR_ARCHITECTURE%" EQU "amd64" (
>nul 2>&1 "%SYSTEMROOT%\SysWOW64\cacls.exe" "%SYSTEMROOT%\SysWOW64\config\system"
) ELSE (
>nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system"
)
REM --> If error flag set, we do not have admin.
if '%errorlevel%' NEQ '0' (
echo Requesting administrative privileges...
goto UACPrompt
) else ( goto gotAdmin )
:UACPrompt
echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs"
set params= %*
echo UAC.ShellExecute "cmd.exe", "/c ""%~s0"" %params:"=""%", "", "runas", 1 >> "%temp%\getadmin.vbs"
"%temp%\getadmin.vbs"
del "%temp%\getadmin.vbs"
exit /B
:gotAdmin
pushd "%CD%"
CD /D "%~dp0"
:MENU
@cls
@echo . .....................................................................................
@echo . Developed by: TIGAXMT .
@echo .......................................................................................
@echo . .
@echo . .
@echo . .
@echo . 1 - Disable Unnecessary Services .
@echo . 2 - Disable Unnecessary Services Powerful .
@echo . 3 - Windows License Expiration .
@echo . 4 - Hardware Info .
@echo . 5 - Install Default Apps (Avast, Spotify, Firefox etc) .
@echo . 6 - Reboot Windows .
@echo . 0 - Exit .
@echo . .
@echo . .
@echo .......................................................................................
@set /P M=Type the option NUMBER then press ENTER:
IF %M%==1 GOTO DUS
IF %M%==2 GOTO DUSP
IF %M%==3 GOTO SLMGREXP
IF %M%==4 GOTO HARDWARE
IF %M%==5 GOTO NINITE
IF %M%==6 GOTO RBT
IF %M%==0 GOTO EOF
IF %M%>5 GOTO MENU
:DUS
@echo Starting Disabling Unnecessary Services
@net stop Fax > null 2>&1
@sc config Fax start= disabled
@echo Disabling Fax
@net stop DPS > null 2>&1
@sc config DPS start= disabled
@echo Disabling Diagnostic Policy Service
@net stop seclogon > null 2>&1
@sc config seclogon start= disabled
@echo Disabling Secondary Logon
@net stop PcaSvc > null 2>&1
@sc config PcaSvc start= disabled
@echo Disabling Program Compatibility Assistant Service
@net stop ScDeviceEnum > null 2>&1
@sc config ScDeviceEnum start= disabled
@echo Smart Card Device Enumeration Service
@net stop CscService > null 2>&1
@sc config CscService start= disabled
@echo Disabling Offline Files
@net stop stisvc > null 2>&1
@sc config stisvc start= disabled
@echo Disabling Still Image Services
@net stop DiagTrack > null 2>&1
@sc config DiagTrack start= disabled
@echo Disabling Diagnostic Tracking Service
@net stop RemoteRegistry > null 2>&1
@sc config RemoteRegistry start= disabled
@echo Disabling Remote Registry
@net stop WerSvc > null 2>&1
@sc config WerSvc start= disabled
@echo Disabling Windows Error Reporting Service
@net stop dmwappushsvc > null 2>&1
@sc config dmwappushsvc start= disabled
@echo Disabling dmwappushsvc Service
@echo Finished!
@cls
GOTO MENU
:DUSP
@echo Starting Disabling Unnecessary Services Powerful
@net stop Fax > null 2>&1
@sc config Fax start= disabled
@echo Disabling Fax
@net stop DPS > null 2>&1
@sc config DPS start= disabled
@echo Disabling Diagnostic Policy Service
@net stop seclogon > null 2>&1
@sc config seclogon start= disabled
@echo Disabling Secondary Logon
@net stop PcaSvc > null 2>&1
@sc config PcaSvc start= disabled
@echo Disabling Program Compatibility Assistant Service
@net stop ScDeviceEnum > null 2>&1
@sc config ScDeviceEnum start= disabled
@echo Smart Card Device Enumeration Service
@net stop CscService > null 2>&1
@sc config CscService start= disabled
@echo Disabling Offline Files
@net stop stisvc > null 2>&1
@sc config stisvc start= disabled
@echo Disabling Still Image Services
@net stop DiagTrack > null 2>&1
@sc config DiagTrack start= disabled
@echo Disabling Diagnostic Tracking Service
@net stop RemoteRegistry > null 2>&1
@sc config RemoteRegistry start= disabled
@echo Disabling Remote Registry
@net stop WerSvc > null 2>&1
@sc config WerSvc start= disabled
@echo Disabling Windows Error Reporting Service
@net stop dmwappushsvc > null 2>&1
@sc config dmwappushsvc start= disabled
@echo Disabling dmwappushsvc Service
@net stop MapsBroker > null 2>&1
@sc config MapsBroker start= disabled
@echo Disabling Downloaded Maps Manager
@net stop iphlpsvc > null 2>&1
@sc config iphlpsvc start= disabled
@echo Disabling IP Helper
@net stop WSearch > null 2>&1
@sc config WSearch start= disabled
@echo Disabling Windows Search
@echo Finished!
@cls
GOTO MENU
:SLMGREXP
@slmgr -xpr
@cls
GOTO MENU
:HARDWARE
@cls
@echo CPU
@wmic cpu get name, numberofcores, maxclockspeed, status
@echo RAM
@wmic MEMORYCHIP get DeviceLocator, MemoryType, TypeDetail, Speed
@systeminfo | findstr /C:”Total Physical Memory
@echo GPU
@wmic path win32_VideoController get name
@echo HDD
@wmic logicaldisk get Caption, DriveType, Size
@pause
@cls
GOTO MENU
:NINITE
@cls
.\handler\ninite.exe
@cls
@echo Apps installed successfully!
@cls
@pause
GOTO MENU
:RBT
@shutdown /r /t 0
@pause