Instantiating COM object hnetcfg.fwpolicy2 on Remote Server
- by Pavan Keerthi
I locked my self out by inadvertently changing RDP firewall rule to use IPSec,but without completing proper steps to setup IPSec channel from my laptop to server.
Luckily all wmi remoting on Server works,So I am trying to edit the rule with Powershell
When I enter below code ,the COM object is invoking on local machine.How can I invoke it on remote machine?
Enter-PSSession $Session
$fw = New-Object -ComObject hnetcfg.fwpolicy2