Announcement

Collapse
No announcement yet.

Two scripts that might be useful, C.A.D. for VNC and Turn on RDP access

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Two scripts that might be useful, C.A.D. for VNC and Turn on RDP access

    Ctrl Alt Del fix for VNC

    I had a problem that using TightVNC v2.0.3, some machines would not let you do remote Ctrl Alt Del. The following Vbscript fixed that problem.

    Vbscript code:
    ' CAD fix
    Dim strKeyPath, strComputer, strValueName, strValue
    Const HKEY_LOCAL_MACHINE = &H80000002
    strKeyPath = "SOFTWARE\Microsoft\Windows\CurrentVersion\Policie s\System"
    strComputer = Wscript.Arguments.Item(0)
    Set objReg=GetObject( _
    "winmgmts:{impersonationLevel=impersonate}!\\" & _
    strComputer & "\root\default:StdRegProv")
    strValueName = "SoftwareSASGeneration"
    strValue = "1"
    objReg.SetDWORDValue HKEY_LOCAL_MACHINE,_
    strKeyPath,strValueName,strValue
    ' added notification for when it was done
    WScript.Echo "Crtl, Alt, Delete fix for " & strComputer
    I saved it as cadFix.vbs in c:\scripts. You can place it where you need, just make sure in the Hynea tools you point to it.
    Hyena Tool:
    CAD Fix for VNC
    cscript c:\scripts\cadFix.vbs "%C1%"

    ---------------------------------------------------------------------------------------------------------------------------

    Turn On RDP so you can login as an Admin


    When I tryed to access a Windows 7 machine and the RPD is not activtive, this Vbscript gave my Admin account access.


    Vbscript code:
    Const HKEY_LOCAL_MACHINE = &H80000002
    'Var
    strComputer = Wscript.Arguments.Item(0)
    strKeyPath = "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Contr ol\Terminal Server"
    strValueName = "fDenyTSConnections"
    dwValue1 = 0
    'Permission
    Set oReg=GetObject("winmgmts:{impersonationLevel=imper sonate}!\\" & _
    strComputer & "\root\default:StdRegProv")
    ' change key
    oReg.SetDWORDValue HKEY_LOCAL_MACHINE,strKeyPath,strValueName,dwValue 1
    ' added notification for when it was done
    MsgBox "Dword has been set"
    I saved it as rdpFix.vbs in c:\scripts. You can place it where you need, just make sure in the Hynea tools you point to it.

    Hyena Tool:
    Open access through RDP
    cscript c:\scripts\rFpix.vbs "%C1%"


    I hope this help anybody that needs it.
    Last edited by ; 09-14-2012, 06:50 PM. Reason: remove spaces
Working...
X