HTTPS hit not showing in apache log

user48297 asked:

A website which has a link to my website recently changed from http to
https. Before that, a hit from its link appeared in my apache access_log, as expected – but that is no longer true. I now see hits generated by the webpage load, but not the initial webpage hit itself. Testing that website’s link myself confirms this behavior – the initial hit is not logged.

What can explain this? How can I again get the initial hit logged (I use its referer field to keep track of accesses from that website)? In the log I do see referers from other https sites – but not from this particular website. FYI my apache configuration is pretty standard. Nothing has changed on my end and hits from other sites appear as expected. Trying to get more info using “LogLevel debug” did give anything I found useful.

Jack

PS: I’m assuming the change to https is the cause, since that is the obvious change – but perhaps the website has made additional changes I’m not aware of. Also, I do have modsecurity installed, but cannot see anything in its logs relevant to this.

My answer:


Referrer information is never sent in this case. Browsers will refuse to send the Referer header to an HTTP URL when the referring site is HTTPS.

If you want to get the referrer information again, you will need to move your site to HTTPS, and also get the referring site to update their link so that it points to HTTPS rather than HTTP.


View the full question and any other answers on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.