- CheckMates
- :
- Products
- :
- Developers
- :
- API / CLI Discussion
- :
- Re: Extract the group members with mgmt_cli show a...
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Are you a member of CheckMates?
×- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Extract the group members with mgmt_cli show access-rulebase
Hello Experts,
With the command below I am able to extract the members of the network groups in the source and the destination of the rule.
mgmt_cli show access-rulebase -d xxx.xxx.xxx.xxx offset 0 limit 1 name "Network" details-level "full" use-object-dictionary true show-hits true --format json
My problem is I see the members with their UIDs:
"members" : [ "eac74afb-0f30-4406-8024-4e304094d9c9", "895aed67-7011-46a7-9d42-9e78797301ed", "5ad03019-82c4-4ffb-970d-d0fa3b78adde", "5f5c1f2b-d7de-44e4-aee0-679544b0f8a2", "1b60d48f-9e2c-47e2-80bf-18529eae86d5", "cc9bc8e6-cee6-41e0-a7f9-068d47974b26", "ce76b961-6a85-479e-809b-4807e91aba94" ],
Is it possible to get more details for the members like Name, Type, IP, Subnet, etc... ?
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I believe what the UIDs translate to are in the output of the API call when you say object-dictionary true.
Even so, you may need to parse the individual "members" to get the full details you want.
You can see some discussion about this fact here: https://community.checkpoint.com/t5/API-CLI-Discussion/How-to-list-and-export-the-objects-member-fro...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I believe what the UIDs translate to are in the output of the API call when you say object-dictionary true.
Even so, you may need to parse the individual "members" to get the full details you want.
You can see some discussion about this fact here: https://community.checkpoint.com/t5/API-CLI-Discussion/How-to-list-and-export-the-objects-member-fro...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you @PhoneBoy for your reply.
So there is no single command to produce all I need.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The closest thing you can do with a single command is to add show-as-ranges true to your command line argument.
This will convert the source, destination, and service to ranges (either IPs or ports).
Depending on your precise purpose, that might be exactly what you need.
