Squid - log Google and other search engines related queries

categories:

By default, the queries sent to google and other search engines are not logged into Squid proxy logs. This is meant to protect the user’s privacy.

See below how to enable queries logging..

Add this to /etc/squid/squid.conf

strip_query_terms off

As a result, you’d get this in the logs : 1166463218.353 1285 192.168.1.10 TCP_MISS/200 6429 GET http://www.google.com/search?hl=en&q=s%C3%A9bastien+wains&btnG=Google+Search - DIRECT/64.233.161.104 text/html

Instead of this :

1166463218.353 1285 192.168.1.10 TCP_MISS/200 6429 GET http://www.google.com - DIRECT/64.233.161.104 text/html




Thanks for reading this post!


Did you find an issue in this article?

- click on the following Github link
- log into Github with your account
- click on the line number containing the error
- click on the "..." button
- choose "Reference in new issue"
- add a title and your comment
- click "Submit new issue"

Your feedback is much appreciated! πŸ€œπŸΌπŸ€›πŸΌ

You can also drop me a line below!