Create a Post
cancel
Showing results for 
Search instead for 
Did you mean: 
Ekta_Siwani1
Contributor
Jump to solution

Getting list of sections of a given rule-base using R80.10 API

Hi,

I need to get the list of all the sections of a rule base using R80.10 REST API.

I can see "show access-section"  API to get one section information but there is nothing like "show access-sections".

Is there any way to get a list of all the section of a given rule-base?

0 Kudos
1 Solution

Accepted Solutions
Tal_Paz-Fridman
Employee
Employee

You can use the following command:

mgmt_cli -r true show access-rulebase name "layer name" | grep -B 1 access-section

https://sc1.checkpoint.com/documents/latest/APIs/#cli/show-access-rulebase~v1.9%20

 

It will show all the Section Titles in the Layer with the name of each section (one line before the grep). You can also view additional lines after the output using -A <value>

 

An example of the output from my lab:

[Expert@gw-a30d15:0]# mgmt_cli -r true show access-rulebase name "NEW1 Network" | grep -B 1 access-section
name: "Test Section 1"
type: "access-section"
--
name: "Test Section 2"
type: "access-section"

View solution in original post

5 Replies
Tomer_Sole
Mentor
Mentor

This should be done using show access-rulebase 

0 Kudos
Gongya_Yu
Collaborator

need to pull all the access-rulebase to extract the sections?

0 Kudos
Chris_Atkinson
Employee Employee
Employee

Do you use any naming convention for your "sections" that would allow you to easily filter?

CCSM R77/R80/ELITE
0 Kudos
Tal_Paz-Fridman
Employee
Employee

You can use the following command:

mgmt_cli -r true show access-rulebase name "layer name" | grep -B 1 access-section

https://sc1.checkpoint.com/documents/latest/APIs/#cli/show-access-rulebase~v1.9%20

 

It will show all the Section Titles in the Layer with the name of each section (one line before the grep). You can also view additional lines after the output using -A <value>

 

An example of the output from my lab:

[Expert@gw-a30d15:0]# mgmt_cli -r true show access-rulebase name "NEW1 Network" | grep -B 1 access-section
name: "Test Section 1"
type: "access-section"
--
name: "Test Section 2"
type: "access-section"

Gongya_Yu
Collaborator

thanks so much !! This is what I look for.

0 Kudos

Leaderboard

Epsum factorial non deposit quid pro quo hic escorol.

Upcoming Events

    CheckMates Events