Information Technology Grimoire

Version .0.0.1

IT Notes from various projects because I forget, and hopefully they help you too.

rule export

Old Way

If you’re using R77.30 or earlier management, then you do something like the following from the management:

[Expert@mgmt:0]# dbedit -local
Please enter a command, -h for help or -q to quit:
dbedit> print fw_policies ##YourPolicy
db_tool -p $FWDIR/state/local/FW1 get_rules

New Way (API)

mgmt_cli show access-rulebase name "my_policy Network" package "my_policy" -f json

If you’re using R80 management, then you can use the mgmt_cli commands referred to above.

Note that in no case will you be able to easily obtain this information from the gateway itself, only on the management.