PyMISP icon indicating copy to clipboard operation
PyMISP copied to clipboard

fix: [search_index] Update date_from and date_to parameters to date str

Open tomking2 opened this issue 4 months ago • 3 comments

I don't think it was always this way, but it now appears that MISP is unable to handle the datefrom and dateto parameters for the event index as timestamps. The value is directly passed to the DB, which has unexpected results depending on the DB choice:

  • MariaDB: Seems to return everything, ignoring the filter
  • Azure MySQL: Returns nothing

The solution is to instead format the field as a date string YYYY-MM-DD which correctly enables you to use these filters on the search_index endpoint. This should be a non-breaking change, as the fields accept the same input types as before.

tomking2 avatar Oct 10 '24 11:10 tomking2