07-11-2014 06:55 AM
Hi all,
I am trying to use the API to get a list of unused and another of used rules. Via the API I only get the following error
<response status="error"><msg><line>An error occured. See dagger.log for information.</line></msg></response>
I have also tried with the following
I then get a list of all policies. This does not change even if I change from used to unused, or from security to nat or pbf.
Does anyone know how to get an api command that will simply list the unused security rules as on e would get from a normal command line query?
Hope so,
thanks
Stefan
07-13-2014 08:00 AM
You need send the following over the API,
<show><running><rule-use><vsys>vsys1</vsys><type>unused</type><rule-base>security</rule-base></rule-use></running></show>
The resultant URL would look look like this,
07-11-2014 02:25 PM
Have you seen the option on the GUI?
Policy tab and on the bottom of the screen is the check box to highlight unused policies.
07-13-2014 08:00 AM
You need send the following over the API,
<show><running><rule-use><vsys>vsys1</vsys><type>unused</type><rule-base>security</rule-base></rule-use></running></show>
The resultant URL would look look like this,
07-16-2014 10:51 AM
07-16-2014 04:32 PM
Thanks everyone for the responses. All of them works
Click Accept as Solution to acknowledge that the answer to your question has been provided.
The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!
These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!
The LIVEcommunity thanks you for your participation!