mushorg / tanner

He who flays the hide
GNU General Public License v3.0
222 stars 103 forks source link

Tanner API Parameter for setting number of returned session #404

Open BlackPreacher opened 3 years ago

BlackPreacher commented 3 years ago

After a few days for the snare honeypot collecting data there had been about 1000 sessions with data. If I tried to export and query them at one time to analyse the collected data for some ressearches I saw that there were returned only 50 requests. I would suggest to add an filter-parameter (e.g. called "size"), where the user can choose the number of returned sessions.

mohamedmostafadawood commented 2 years ago

https://github.com/mushorg/tanner/blob/2fdce2e2ad7e125012c7e6dcbfa02b50f73c128e/tanner/api/server.py#L38

I think this line is the key solution for your problem.

mohamedmostafadawood commented 2 years ago

@afeena @mzfr is there a reason for choosing to return 50 requests only? I can work on it if it is possible : )

mzfr commented 2 years ago

@mohamedmostafadawood AFAIK it is just for the single query. So in the single query, it returns 50. And then I think filters were supposed to be used for getting the other sessions. But yes there has to be a better way via which any number of sessions can be extracted.

mohamedmostafadawood commented 2 years ago

@mzfr I got it!