Closed sarabesh closed 8 months ago
Looks like it should be just if not self.types
Yes, that's clearly a bug
I believe it should be if self.types
.
All the other parameters are tested with is None
so I don't see why types is handled differently.
Depends on what you check for. If ""
, False
and None
should be treated equally, use if self.types
, otherwise check for the value explicitly.
""
usually appears when a bot is edited with the manager and should always be handled.
https://github.com/certtools/intelmq/blob/42a9bfa2a49801659ec8f0f462ee76d4734a7e33/intelmq/bots/collectors/shadowserver/collector_reports_api.py#L112
By default from the intelmq, types is added as "", when we leave it empty though all the JSON conversions. So, I had some time to figure out why my reports were being filtered. Eventually, as a temporary work around I removed the types parameter completely.