Re: [users@httpd] Bug? Or not? Accessing server with numeric IP produces error page... with VirtualHost setup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Well i actually found a different bug with the same topic... but this one answers question 1+2 for me, thanks!

Now to question 3:

Lets pretend I want this to work on my server... is there anything I can do to forward any request to a standard vhost, even if its an malformed one?

Thanks!



Chris wrote:
A quick google search got me this:

http://issues.apache.org/bugzilla/show_bug.cgi?id=34595

Chris

SkyFlash wrote:

Good morning....

I have a problem with my Apache2 (2.0.52).

While checking how to calculate numeric IPs from my own I found out that my webserver does not like it when I access it via the numeric IP.

I have my webserver set up with virtual hosts, so I do understand that he has problems to figure out WHICH webpage to serve, but I had the impression that in all cases when he does not know what domain is being asked for he would just server the first webpage in the config.

Example:

If I access it via an IP (e.g. http://192.168.1.2/index.php) it all works.

When I do something like "http://123456789/index.php it will produce the following page:

-----snip-----
Bad Request

Your browser sent a request that this server could not understand.
-----snip-----

Also it will log an error in the logfile.:

-----snip-----
[Tue May 10 06:34:08 2005] [error] [client 192.155.149.29] Client sent malformed Host header
-----snip-----

Now my questions are...

1. Is that intended behaviour?
2. If not, is there something I can do to fix it?
3. Is there a workaround that would enable me to redirect those requests to a specific virtual host by other means?

I did find a bug report from some years ago about the exact same problem, but it was apparently fixed... so should it work?

Thanks for help!


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
  "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux