https://bz.apache.org/bugzilla/show_bug.cgi?id=64996

--- Comment #2 from Christoph Anton Mitterer <cales...@scientia.net> ---

<TL;DR>

As indicated in the other ticket, my ultimate suggestion would probably be to
rather re-write the documentation and merge it all in one simpler document,
with about the following abstract:

- tell the concepts of a vhost (i.e. one httpd serving (typically different)
content, reachable from different domainnames/addresses/ports.

- tell what IP based hosting is/was, namely that the vhost is selected purely
based on the addr/port (at which the connection arrives)... perhaps adding that
this is typically not necessary anymore (especially in times of tight v4 space)
and that even past reasons (non-SNI TLS) are gone - instead of just vaguely
indicating this, which just confuses users)

- tell what name based hosting is, namely the clients send a HTTP Host header
giving the domainname of the host they desire (and that this is usually
identical to the domainname in the client's URL
and the crucial point: selection is done based on that Header, rather then the
IP/port
perhaps also, that with TLS, the SNI name is take for the Host

- tell how it actually works in apache, which does basically both at the same
time, i.e. how the vhost is selected:
1) first take any vhosts whose addr:port match literally (i.e. no wildcard)
2) if none, take also those with wildcards)
3) if there is a HTTP Host Header, match that in the remaining vhosts and fall
back to the first one if no-one matches or there is none.
4) if there was matching no vhost at all, give it to the main server

- remainders are special thing, like where  ServerName get's its default from,
or who the implicitly added ServerAlias (form <VirtualHost> name works... or
that a vhost literal hostname (instead of addr) will be replaced by ***all***
addresses that name resolves to at server startup.... and other special stuff
like: what if more than one <VirtualHost> have a literal addr:port match.
</TL;DR>


---------------------


But given the above would be a huge effort, a solution for this ticket would
perhaps be to really clarify what's meant with phrases like (from your
quotations):
- "the proper server", "the best IP-based address"
- "the best (most specific) matching", "best-match address and port"
- "most specific matching IP address and port combination"

I think these phrases are all pretty vague... I mean they're clear for us,
since we know what's meant,.. but for a beginner: What's a "best address
match"? Is IPv4 better than IPv6? Or is a match 10.10.10.10:8080 better than
10.10.10.10:*

One should simply use a clear description like:
It first considers only vhosts with literally matching address:port pair (i.e.
where neither of both is a wildcard *), and only then it also considers those
with wildcards.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscr...@httpd.apache.org
For additional commands, e-mail: docs-h...@httpd.apache.org

Reply via email to