This article explains on how to make a Firewall Policy Profile work using script.
By default, SD will only update the Firewall Policy Profile assigned to a Policy only if rules are created from SD. The script attached will update the configuration in DB so that Firewall Policy Profile changes can be pushed from SD. This script will also optionally update the selected Policy-rules with the Rule Options - "Inherit Profile from Policy".
Rule Options - "Inherit Profile from Policy" must be selected in each rule for the Policy profile to work. If a user has 100's of rules and have logging configured in all rules from device command line itself.
Example:
set security policies from-zone trust to-zone untrust policy test then log session-close set security policies from-zone trust to-zone untrust policy test then count
While importing the firewall policy to SD, all the rules under the policy imported will have the Rule Options "CUSTOM". In this case, it’s difficult to modify individual rules with Rule Options - "Inherit Profile from Policy". This script will help in achieving this task.
This is a limitation in all SD versions. A Problem Report has been created for this. This workaround can be applicable until the issue is fixed permanently.
Work-around:
unzip updateProfile.zip
sh updateProfile.sh
Example with Screenshots:
If Firewall Policy Profile is not created yet create one.
Edit the Security Policy and assign the profile
Check preview, you may see “No configuration changes". Don’t publish now.
Run the script.