-
Notifications
You must be signed in to change notification settings - Fork 47
/
Turn On or Off Admin Password.bat
46 lines (46 loc) · 1.22 KB
/
Turn On or Off Admin Password.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
@echo off
title Admin Passwort Manager
color 30
echo.
echo.
:start
@echo off
echo Press A to disable admin password prompts.
echo.
echo Press B to enable admin password prompts.
echo.
set /p example=
if %example% == 0 goto start
if %example% == a goto A
if %example% == A goto A
if %example% == b goto B
if %example% == B goto B
:A
echo.
echo.
@echo on
reg add "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System" /v "ConsentPromptBehaviorAdmin" /t REG_DWORD /d "5" /f
reg add "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System" /v "ConsentPromptBehaviorUser" /t REG_DWORD /d "3" /f
set /p example=
if %example% == 0 goto start
if %example% == a goto A
if %example% == A goto A
if %example% == b goto B
if %example% == B goto B
:A
echo.
echo.
@echo on
:B
:A
echo.
echo.
@echo on
reg add "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System" /v "ConsentPromptBehaviorAdmin" /t REG_DWORD /d "1" /f
reg add "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System" /v "ConsentPromptBehaviorUser" /t REG_DWORD /d "0" /f
set /p example=
if %example% == 0 goto start
if %example% == a goto A
if %example% == A goto A
if %example% == b goto B
if %example% == B goto B