1 | ; $Id: VBoxWHQLFake.au3 76553 2019-01-01 01:45:53Z vboxsync $
|
---|
2 | ;; @file
|
---|
3 | ; VBoxFakeWHQL - Turns off / on the WHQL for installing unsigned drivers.
|
---|
4 | ; Currently only tested with Win2K / XP!
|
---|
5 | ;
|
---|
6 |
|
---|
7 | ;
|
---|
8 | ; Copyright (C) 2008-2019 Oracle Corporation
|
---|
9 | ;
|
---|
10 | ; This file is part of VirtualBox Open Source Edition (OSE), as
|
---|
11 | ; available from http://www.virtualbox.org. This file is free software;
|
---|
12 | ; you can redistribute it and/or modify it under the terms of the GNU
|
---|
13 | ; General Public License (GPL) as published by the Free Software
|
---|
14 | ; Foundation, in version 2 as it comes in the "COPYING" file of the
|
---|
15 | ; VirtualBox OSE distribution. VirtualBox OSE is distributed in the
|
---|
16 | ; hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
|
---|
17 | ;
|
---|
18 |
|
---|
19 | ; Strings for localization
|
---|
20 | ; When using an OS with another language, you have to provide the correct
|
---|
21 | ; strings for it. English and German is provided below.
|
---|
22 | ;
|
---|
23 | ; @todo Needs to be improved to handle the stuff without language strings in
|
---|
24 | ; the future!
|
---|
25 |
|
---|
26 | ;$sysprop_Title = "System Properties"
|
---|
27 | ;$drvsig_Title = "Driver Signing Options"
|
---|
28 |
|
---|
29 | $sysprop_Title = "Systemeigenschaften"
|
---|
30 | $drvsig_Title = "Treibersignaturoptionen"
|
---|
31 |
|
---|
32 | $ok_Title = "OK"
|
---|
33 |
|
---|
34 | If $CmdLine[0] < 1 Then
|
---|
35 | MsgBox ( 0, "ERROR", "Please specify 'ignore', 'warn' or 'block' as parameter!" )
|
---|
36 | Exit
|
---|
37 | EndIf
|
---|
38 |
|
---|
39 | Run("control.exe sysdm.cpl")
|
---|
40 | If WinWait($sysprop_Title, "", 5) = 0 Then
|
---|
41 | WinClose("[ACTIVE]", "")
|
---|
42 | Exit
|
---|
43 | EndIf
|
---|
44 |
|
---|
45 | ControlCommand($sysprop_Title, "", "SysTabControl321", "TabRight", "")
|
---|
46 | ControlCommand($sysprop_Title, "", "SysTabControl321", "TabRight", "")
|
---|
47 |
|
---|
48 | Sleep(200) ; Wait a while for tab switching above
|
---|
49 | ControlClick($sysprop_Title, "", 14007) ; Button 'Driver Signing'
|
---|
50 |
|
---|
51 | WinWait($drvsig_Title, "", 5)
|
---|
52 |
|
---|
53 | If $CmdLine[1] = "ignore" Then
|
---|
54 | ControlClick($drvsig_Title, "", 1000) ; 'Ignore' radio button
|
---|
55 | ElseIf $CmdLine[1] = "warn" Then
|
---|
56 | ControlClick($drvsig_Title, "", 1001) ; 'Warn' radio button
|
---|
57 | ElseIf $CmdLine[1] = "block" Then
|
---|
58 | ControlClick($drvsig_Title, "", 1002) ; 'Block' radio button
|
---|
59 | Else
|
---|
60 | Exit
|
---|
61 | EndIf
|
---|
62 |
|
---|
63 | ControlClick($drvsig_Title, "", 1) ; 'OK' button (ID=1) of dialog 'Driver Signing Options'
|
---|
64 |
|
---|
65 | WinWait($sysprop_Title, "", 5)
|
---|
66 | ControlClick($sysprop_Title, "", 1) ; 'OK' button (ID=1) of 'System Properties'
|
---|
67 |
|
---|