Recently I locked down a PC to allow a customer to remote into our office and run a single app.  To make it secure I made a number of firewall changes to block internet and even LAN access.  The problem I have is I couldn’t recall what those changes were and I needed assign the PC to new office worker… not good.

How Backup the Windows Firewall via Command Line

In case you are worried about the firewall reset, you might want to backup the configuration to a simple text file before you make changes:

  1. Right click on your START button and select COMMAND PROMPT (ADMIN), POWERSHELL (ADMIN) or WINDOWS TERMINAL (ADMIN)
  2. Enter this command and press the enter key on your keyboard:
    netsh advfirewall export "C:\Temp\firewall-config.wfw"

How Reset the Windows Firewall To Default via Windows Security Center:

If you want to reset the Windows Firewall to default easity, just click through the Windows Security Center:

  1. Double click on the Windows Security shield icon in your system tray (near the clock in your task bar)
  2. Click FIREWALL & NETWORK PROTECTION (in the left menu, or the large tile on the right)
  3. Click RESTORE FIREWALL TO DEFAULT
  4. Click the RESTORE button

 


How Reset the Windows Firewall To Default via Control Panel:

If you want to reset the Windows Firewall to default easily, just click through the Control Panel:

Control Panel > All Control Panel Items > Windows Defender Firewall > Restore defaults

how to reset windows firewall to defaults - reset button


How Reset the Windows Firewall To Default via PowerShell:
  1. Right click on the START button and select POWERSHELL (ADMIN)
  2. Enter this command, then press the ENTER key on your keyboard:
    (New-Object -ComObject HNetCfg.FwPolicy2).RestoreLocalFirewallDefaults()

how to reset windows firewall to defaults via PowerShell

 


How Reset the Windows Firewall To Default via Command Prompt:
  1. Start a CMD PROMPT (ADMIN)
  2. Enter this command, then press the ENTER key on your keyboard:
    netsh advfirewall reset

how to reset windows firewall to defaults via command line prompt


0 Comments

Leave a Reply

Avatar placeholder

Your email address will not be published.