DonationCoder.com forum
 
Read-only archive. This is a static copy of the DonationCoder.com forum. Reading and searching work as before; logging in, posting and private messages do not.
Archive of 2026-10-21 · About this archive · Main site

Author Topic: Switching Windows firewall on/off?  (Read 8,057 times)

lanux128

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 6,277
    • Coding Snacks
    • Volunteers/Staff
    • Gathering Badge
    • Participated in NANY Challenge Once
    • Linux User
Switching Windows firewall on/off?
« on: May 17, 2007, 03:58 AM »
i want to quickly enable the "Don't allow exceptions" option in Windows Firewall (see pic) before going online. so i'm wondering which registry keys are involved so that maybe i might be able to whip up a mini AHK script to do that and also toggle on/off the windows firewall.. Any ideas? :)

[attach=#]

cthorpe

  • Discount Coordinator
  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 738
Re: Switching Windows firewall on/off?
« Reply #1 on: May 17, 2007, 02:35 PM »
the following command disables exceptions:

netsh firewall set opmode mode = ENABLE exceptions = DISABLE


To allows exceptions:

netsh firewall set opmode mode = ENABLE exceptions = ENABLE


turn off firewall:

netsh firewall set opmode DISABLE


turn on firewall

netsh firewall set opmode ENABLE
« Last Edit: May 17, 2007, 02:41 PM by cthorpe »

lanux128

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 6,277
    • Coding Snacks
    • Volunteers/Staff
    • Gathering Badge
    • Participated in NANY Challenge Once
    • Linux User
Re: Switching Windows firewall on/off?
« Reply #2 on: May 18, 2007, 02:29 AM »
thanks a lot, cthorpe.. that is very helpful.. :Thmbsup:

Original address: https://www.donationcoder.com/forum/index.php?topic=8571.0