Enable/disable windows firewall

Win XP
(desativar FW) netsh firewall set opmode disable
(habilitar FW) netsh firewall set opmode enable

Win 7
(desativar FW) netsh advfirewall set allprofiles state off
(habilitar FW) netsh advfirewall set allprofiles state on

(parar serviço FW) net stop MpsSvc
(iniciar serviço FW) net start MpsSvc

* Para executar remoto, utilize PSEXEC.EXE ou envie um .BAT com os comandos para o usuário.

How to list open ports and application using them in Windows

  netstat -abn or netstat -a -n -p tcp -o

Mais vistos