Problem with /api/client/(server)/stats/(client)
Hello Ziirish,
Testing with demo, GET https://admin:admin@demo.ziirish.me/api/client/Burp1/stats/demo2 returns []
https://burp-ui.readthedocs.io/en/latest/api.html#get--api-client-(server)-stats-(name)
Report works fine https://burp-ui.readthedocs.io/en/latest/api.html#get--api-client-(server)-report-(name)
Is there something that I'm missing?
Why I'm testing it?:
I'm planning to use this list of backups for a given client, to get the latest number of backup for the client.
Creating a list of numbers https://github.com/pablodav/burp_server_reports/blob/refactor_burp_reports2/burp_reports/backends/burpui_api.py#L225
And then getting the max of it.
And using it to get the report of this latest backup
# Get client_report_stats ;
# Needs to add test if it's [] retry n times due to issue:
# https://git.ziirish.me/ziirish/burp-ui/issues/148
cr_stats = self._get_client_report_stats(client, server=server)
# and create a list of backups numbers only
for n in range(len(cr_stats)): backups.append(cr_stats[n].get('number'))
# Get the maximum number of backup to use
number = max(backups)
# Add the backup_report to the dict of the client
client_report_dict['backup_report'] = self._get_backup_report_stats(client, number, server=server)
Kind regards, Pablo.