Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set User-Agent for import_logs.py #4072

Closed
anonymous-matomo-user opened this issue Aug 8, 2013 · 2 comments
Closed

Set User-Agent for import_logs.py #4072

anonymous-matomo-user opened this issue Aug 8, 2013 · 2 comments
Assignees
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc.

Comments

@anonymous-matomo-user
Copy link

I encountered problems running import_logs.py as the script's requests were rejected with a 403 Forbidden error. Of course this was a configuration issue on my part: specifically, Cloudflare was blocking requests with missing User-Agent headers. It might also have been Apache, Nginx, or some other software. I would suggest that since there are so many pieces of software that may block requests, and since well-behaved software should provide a User-Agent, that import_logs.py should provide the headers. I'm attaching a trivial patch.
Keywords: import_logs, 403, forbidden

@anonymous-matomo-user
Copy link
Author

Attachment: Patch to send User-Agent with import_log.py requests
add_user_agent.patch

@mattab
Copy link
Member

mattab commented Aug 9, 2013

In c64939a: Fixes #4072 thanks for the patch

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc.
Projects
None yet
Development

No branches or pull requests

2 participants