openvpn.config/CLIENT_DATA/enable_rdp.vbs

13 lines
367 B
Plaintext
Raw Permalink Normal View History

2012-04-05 14:33:15 +02:00
Const ENABLE_CONNECTIONS = 1
WScript.Sleep 60000
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery _
("Select * from Win32_TerminalServiceSetting")
For Each objItem in colItems
objItem.SetAllowTSConnections(ENABLE_CONNECTIONS)
Next