Script to import firewall settings into gpedit

Home Forums Scripting General Scripting Script to import firewall settings into gpedit

This topic contains 2 replies, has 3 voices, and was last updated by Avatar siringo 4 years, 3 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • Avatar
    dogdude
    Member
    #164661

    hello all,

    i am trying to find a solution to automate importing firewall rules (.wfw) so that it is viewable and manageable from gpedit.msc. I already know how to automate and import the firewall rule set into the advanced firewall setting in the control panel but doing that does not make them viewable and manageable from gpedit.msc

    “netsh advfirewall import firewallrules.wfw” only imports them to be viewable and manageable from the advanced firewall option in the control panel. If i manually import the config file into gpedit from Local Computer Policy – Computer configuration – Windows settings – Security settings – Windows Firewall with advanced security, it naturally overwrite the settings manageable from the control panel.

    I need help with automating the above. This is automated deployments. I know I can do it by hand but thats not what I am looking for. Constraints, this is a Server 2012 R2 member server standalone on a workgroup, so its all local, so no AD logon scripts, domain gpos, etc. Its not really important why I need to do this, I just do.

    Any help is kindly appreciated. I have looked but cannot find a solution so far that works given the above.

    thanks in advance

    JeremyW
    JeremyW
    Moderator
    #271057

    Re: Script to import firewall settings into gpedit

    If you open the local policy and expand to the Windows Firewall node, you can right-click and import a policy.

    Avatar
    siringo
    Member
    #390658

    Re: Script to import firewall settings into gpedit

    thanks but that’s by hand. that’s not automated.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.