Invalid "host" information in access and error logs

Valentin V. Bartenev vbart at nginx.com
Wed Oct 28 14:51:36 UTC 2015


On Wednesday 28 October 2015 15:34:50 tamere22 wrote:
> Hi,
> 
> I'm sorry but I can't believe this is true. The random "hosts" I see in logs are defined in other "server" blocks that have their own separate log files.

You have a couple of server blocks that listens on different ports.
So for each such addr:port pair you have different default server
that handles all requests with unknown host header.


> Also why would the "server" information in the logs be good whereas the "host" information is completly random ?

Because the "host" is what the client sent.  Clients are able to send
whatever they want.

  wbr, Valentin V. Bartenev



More information about the nginx mailing list