Página 1 de 1

[Script] VBS desabilitando a USB via registro

Enviado: 05 Jul 2013 06:24
por marceloleaes
Script para desabilitar a porta USB via registro. Abra o bloco de notas copie este código e salve com a extensão .vbs

Bloqueando

Código: Selecionar todos

Dim WSHShell
Set WSHShell = WScript.CreateObject("WScript.Shell")

WSHShell.RegWrite "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\USBSTOR\Start",4 ,"REG_DWORD"

Set WSHShell = nothing
Liberando

Código: Selecionar todos

Dim WSHShell
Set WSHShell = WScript.CreateObject("WScript.Shell")

WSHShell.RegWrite "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\USBSTOR\Start",3 ,"REG_DWORD"

Set WSHShell = nothing