httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jens-U. Mozdzen" <jmozd...@nde.ag>
Subject Re: [users@httpd] Apache virtualhost order deny, allow works only on localhost; ignores public IP for allow
Date Tue, 25 Jun 2013 15:10:08 GMT
Hi Kirk,

Zitat von Kirk Woellert <kdwoell@gmail.com>:
> It's a good point but I need to able to access this site from one public IP
> in particular. I thought an entry in /etc/hosts currently as:
>
> 127.0.0.1 [redacted alias for 3rd vhost]
>
> would be sufficient but maybe not? If not, how can I get Apache to 'route'
> to that 3rd vhost? What would people typically do in this case? BTW, I'm

as already said by Eric: put the /etc/hosts entry on the *client*,  
where you run your browser.

The browser will take the name from the URL, convert it to your  
server's (internal) IP and send the request there - stating it's for  
"<FQDN>". httpd then will take that name and match it to the vhost  
setting.

> not the DNS manager and won't get a FQDN for this stage of development.

no need for that.

> On Tue, Jun 25, 2013 at 10:55 AM, Eric Covener <covener@gmail.com> wrote:
>
>> > As a reminder- I don't have a FQDN for the third vhost site- so I just
>> made
>> > a /etc/host temporary entry as mentioned earlier in my post. Therefore

How should that help? The browser doesn't even send the FQDN of the  
vhost, but asks for the IP you give in the URL:

>> when
>> > I try to check for public access, I'm always using a physical path in the
>> > browser as:
>> >
>> > http://[redacted public IP]/~[redacted user for 3rd vhost]/[redacted
>> site
>> > directory for 3rd vhost]/index.php
>> > [...]
>> How would Apache know to route  that to the third name-based vhost
>> when you use the IP address only and no matching servername?  You
>> should mock the hostname in your hosts file from the client you test
>> on.

Regards,
Jens


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message