Closed tristanlatr closed 4 years ago
I've tried to implement an invalid session error handler.
It re-logins the user, then it sleeps 0.2s and retry the request. If it still run into an error, It returns a NitroError
The method NitroSession.esm_request
currently handles the following errors :
list
NitroError
The current behaviour for NitroSession.esm_request() is to automatically retry once the request if it failed. If it's a login issue it will re-login first.
The current behaviour for EventManager.qry_load_data() is the same: retry once the request
NitroSession
should handle correctly SIEM errors :Currently, calls to
NitroSession.esm_request
that raisesrequests.HTTPError
errors can raiseNitroError
if the error is unhandled.See docs : https://mfesiem.github.io/docs/msiempy/index.html#msiempy.NitroSession.esm_request
Unhandled 400 errors :
com.mcafee.siem.api.data.query.EsmTimeRange
java.lang.String
out of START_OBJECT tokencom.mcafee.siem.api.data.alert.EsmAlertId
Unhandled 500 errors :
Connexion errors -> Raises !