- CheckMates
- :
- Products
- :
- Developers
- :
- API / CLI Discussion
- :
- class names available for use with the "show-gener...
- 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
class names available for use with the "show-generic-objects" API command
Hello,
How can I browse/search the class-names available for use with the show-generic-objects API call?
For example:
I have been able to find the "Track" object guessing:
> show generic-objects class-name com.checkpoint.objects.Track
objects:
- uid: "29e53e3d-23bf-48fe-b6b1-d59bd88036f9"
name: "None"
type: "Track"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
- uid: "598ead32-aa42-4615-90ed-f51a5928d41d"
name: "Log"
type: "Track"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
- uid: "d395a3bb-c96c-4781-8017-b9cd0418e982"
name: "Detailed Log"
type: "Track"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
- uid: "78566494-7e96-4513-ada9-ded83f4ee9ea"
name: "Extended Log"
type: "Track"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
from: 1
to: 4
total: 4
but I am unable to find the RulebaseAction object type, or
> show generic-objects class-name com.checkpoint.objects.RulebaseAction
objects: []
total: 0
Could you please help?
I am unable to find this information here or in the docs.
Thank you very much.
- Labels:
-
General
-
Object Management
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have found a possible way to find an unknown class name for use with "show-generic-objects"
First, look at the type of the object, using the show-object uid uid command:
> show-object uid 6c488338-8eec-4103-ad21-cd461ac2c472
object:
uid: "6c488338-8eec-4103-ad21-cd461ac2c472"
name: "Accept"
type: "RulebaseAction"
domain:
uid: "a0bbbc99-adef-4ef8-bb6d-defdefdefdef"
name: "Check Point Data"
domain-type: "data domain"
Once you have the type, in this case "RulebaseAction", query the database directly for a possible match, grep lowercase and uniq to remove duplicates:
[Expert@cp8020-mgm:0]# psql_client cpm postgres -c "select objclass from dleobjectderef_data where objclass like 'com.checkpoint.objects.%'" | grep -i rulebaseaction | uniq
com.checkpoint.objects.rulebase_classes.dummy.CpmiSslInspectionRulebaseAction
com.checkpoint.objects.rulebase.RulebaseAction <<<<<<< I was looking for this
Very useful info to search and query almost any object in the database using the rest API show-generic-objects
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for the post as it really helped me to find what I was looking for. One improvement if I may is to get rid of the ugly grep and keep the full statement as clear SQL:
psql_client cpm postgres -c "select distinct objclass from dleobjectderef_data where objclass ilike '%rulebaseaction%'"
