Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I would like to assign Windows Firewall's public profile to the public Ethernet interface and the private profile to the private Ethernet interface. I can do this with the GUI via

  1. Open Windows Firewall with Advanced Security
  2. Click on Windows Firewall Properties
  3. Click the Private Profile Tab
  4. Click Customize
  5. Select the Interface I want (private)
  6. Click OK
  7. Repeat step 3-6 for the public profile

How do I do this via command line? I'm using Windows Server 2008 R2

share|improve this question

3 Answers 3

You can find full information about Netsh AdvFirewall Firewall Commands at MS Technet:

TechNet Library: Windows Server Netsh AdvFirewall Firewall Commands

share|improve this answer

From PowerShell: Set-NetFirewallProfile -Name %ProfileName% -DisabledInterfaceAliases %YouConnectionName%

share|improve this answer

I'm afraid this GUI won't assign profiles to interfaces. It seems like it can only guarantee that certain profile won't apply to certain NIC when Windows thinks its network classifies as such profile. Mind the name of the PS parameter, "DisabledInterfaceAliases".

share|improve this answer
1  
this GUI? The question is about assigning profiles from the command line. –  suspectus Aug 9 at 20:02
    
The question assumes this can be done via GUI in the first place, which I doubt. This also affects the possible cmdline answer — because, if it does the same as the GUI and the GUI does not do what the authour assumes, the outcome would be less than useful. –  hypersw Aug 12 at 17:05

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.