httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From (David Robinson)
Subject HostAlias (was Re: cvs commit: apache/src CHANGES http_config.c http_config.h http_core.c http_main.c http_protocol.c httpd.h util.c)
Date Tue, 02 Apr 1996 18:51:00 GMT
> akosut      96/03/27 23:59:37
>  Modified:    src       CHANGES http_config.c http_config.h http_core.c
>                        http_main.c  http_protocol.c httpd.h util.c
>  Log:
>  Add new directive, <HostAlias>, very similar to <VirtualHost> in
>  function, but instead of binding the server to a new IP address, it
>  uses hostnames derived from the Host: header and/or full-URI
>  requests. (Requests that have neither will be served the documents as
>  given normally) The directive is of the form <HostAlias *
>> (multiple entires seperated by spaces, with
>  wildcards).

Sorry I didn't spot this before, but the subject really wasn't very

I think that the invention of a completely new <HostAlias> section is
unnecessary and over-complicated. It is duplicating the entire functionality
of the VirtualHost directive. Apart from questions like can hostalias
and virtual host nest?, and can directives in virtual host sections be
allowed in host alias sections? -- there is the point that this could be
achivied simply by modifying the VirtualHost directive.

i.e. simply take the names in the virtual host directive as host aliases
as well interfaces.

Advantages: minimal changes to existing configuration files.

Implementation: each virtual host has an address property list and a hostname
property list.

<VirutalHost host1 host2 ... >
adds the IP adress for each host to the address list, and adds the hostname
itself to the hostname list.

The virtual host is matched by the request if the incoming address is
on the address list, and the Host: or URL host is on the hostname list.


<VirtualHost host1.dom>

<VirtualHost host2.dom>

will 'work' for 1.1 queries even if host1.dom and host2.dom have the
same IP address.


View raw message