def get_config():
    profiles = {}
    curr = None

    cmd = ['netsh', 'advfirewall', 'show', 'allprofiles']
    for line in __salt__['cmd.run'](cmd, python_shell=False).splitlines():
        if not curr:
            tmp = re.search('(.*) Profile Settings:', line)
            if tmp:
                curr = tmp.group(1)
        elif line.startswith('State'):
            profiles[curr] = line.split()[1] == 'ON'
            curr = None

    return profiles
Get the status of all the firewall profiles
dataset/ETHPy150Open saltstack/salt/salt/modules/win_firewall.py/get_config