Auto-Archive script makes requests with empty User Agent string

While testing the Auto-Archiving script just now I noticed that 3 out of the 6 requests made by the script has no user-agent string set; the 3 others are set as “Piwik/1.8.4”. This is not really a problem usually except that I have my web server set up in such a way that all requests with no user-agent set is immediately rejected with a 403.

I hope this can be fixed for a version in the future.

The 3 requests are the ones with period=week, period=month and period=year.

thanks for the report, I created a bug in: archive.php curl requests do not set user agent · Issue #3383 · matomo-org/matomo · GitHub

replace the 2 files in your piwik:

please confirm it’s OK!

Thank you, Matt.

I made the changes you suggested and everything seems to be all right.