1

How can you open ports in windows firewall for WMI using netsh command ?

On windows vista and newer MS OS-es you run this command

netsh advfirewall firewall set rule group="windows management instrumentation (wmi)" new enable=yes

What is netsh alternative for Win XP and 2003 ?

EDIT: User for WMI isn't administrator.

Primoz
  • 397
  • 3
  • 7
  • 16

1 Answers1

3

Netsh firewall set service RemoteAdmin

colealtdelete
  • 6,009
  • 1
  • 29
  • 34
  • This only works if user under which WMI runs is part of administrators group. What if user is not administrator ? – Primoz Apr 06 '11 at 16:35
  • @Primoz So you want to use an admin account or not? I am not sure how you plan to modify the OS firewall without an admin account. At the very least, you need to elevate to an admin account once logged in using `runas` or an equivalent, so you have confused me/us here. – songei2f Apr 07 '11 at 06:11
  • I'll run this command as administrator. But for querying WMI i'll use non admin account. – Primoz Apr 07 '11 at 08:41
  • Yo need to open port 135 for dcom. – Primoz Apr 12 '11 at 18:16