- Products
- Learn
- Local User Groups
- Partners
-
More
It's Here!
CPX 360 2021 Content
Check Point Harmony
Highest Level of Security for Remote Users
Important certificate update to CloudGuard Controller, CME,
and Azure HA Security Gateways
Advanced Protection for
Small and Medium Business
Secure Endpoints from
the Sunburst Attack
Important! R80 and R80.10
End Of Support around the corner (May 2021)
Hello guys,
I am quite new when it comes to the usage of the management API and have a small question.
I've written a batch script which imports a list of "add access-rule commands" (e.g. line one: "mgmt_cli add access-rule layer [...]", line two: "mgmt_cli add access-rule layer [...]", etc.). The script verifies each imported rule and gives the feedback of "ok" for a working one and an error message for non working ones. The error message contains the default return information of the api which looks like this (for a non existing object):
"code: "generic_err_object_not_found"
message: "Requested object [here is the object name] not found"
Unfortunately this message only contains the first error that the API can find within the command.
Now my question is; is it possible to receive all incorrect statements of a management api command and not just the first one that is found? Because by default if you try to execute a command, as mentioned before, only the first found error is being returned. It would be great, for troubleshooting purposes, to instantly see all incorrect or non existing statements of a command string. As currently, if errors are found, I need to change the command and run it again just to maybe see that later in the same command another error occured.
Thanks in advance and best regards,
Maik
Hi Maik,
Management API errors are raised on a first match, they are not accumulated.
Robert.
Hi Robert,
Thanks for the fast reply!
Are there any plans for future API updates to also allow accumlated errors per command?
Regards,
Maik
No, there are no such plans due to major performance downgrade.
The command that executes must return as fast as possible.
Robert.
About CheckMates
Learn Check Point
Advanced Learning
WELCOME TO THE FUTURE OF CYBER SECURITY