A Little .htaccess Problem

This is a discussion on A Little .htaccess Problem within the Apache Web Server forums, part of the Web Server and Related Forums category; I want to block, e.g, any IP address of the type 208.111.154. from my site. The following ...


Go Back   Usenet Forums > Web Server and Related Forums > Apache Web Server

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 01-23-2008
maria
 
Posts: n/a
Default A Little .htaccess Problem

I want to block, e.g, any IP address
of the type

208.111.154.

from my site. The following snipet in my .htaccess file
does not do it.

<Limit GET>
order allow, deny
deny from 208.111.154.
allow from all
</Limit>

What is wrong with it?
My site is on Powweb.
Thanks!

maria
  #2 (permalink)  
Old 01-23-2008
John Clancy
 
Posts: n/a
Default Re: A Little .htaccess Problem

On Tue, 22 Jan 2008 21:46:12 -0500, maria <maria@maria_de_napoli.com>
wrote:

>I want to block, e.g, any IP address
>of the type
>
>208.111.154.
>
>from my site. The following snipet in my .htaccess file
>does not do it.
>
><Limit GET>
>order allow, deny
>deny from 208.111.154.
>allow from all
></Limit>
>
>What is wrong with it?
>My site is on Powweb.
>Thanks!
>
>maria


Try order deny,allow

with "order allow,deny" the allow condition will be evaluated first,
since the allow condition allows all the deny condition would not be
evalutated

JC
  #3 (permalink)  
Old 01-25-2008
HansH
 
Posts: n/a
Default Re: A Little .htaccess Problem

"John Clancy" <JC@nospam.com> schreef in bericht
news:cg6ep3pkehqqmp0tli18vho4ed06s7plce@4ax.com...
> On Tue, 22 Jan 2008 21:46:12 -0500, maria <maria@maria_de_napoli.com>
>>of the type
>>208.111.154.
>>
>>from my site. The following snipet in my .htaccess file
>>does not do it.
>>
>><Limit GET>
>>order allow, deny
>>deny from 208.111.154.
>>allow from all
>></Limit>
>>

> Try order deny,allow
>
> with "order allow,deny" the allow condition will be evaluated first,
> since the allow condition allows all the deny condition would not be
> evalutated
>

http://httpd.apache.org/docs/2.2/mod...ost.html#order
Allow,Deny
First, all Allow directives are evaluated; at least one must match, or the
request is rejected. Next, all Deny directives are evaluated. If any
matches, the request is rejected. Last, any requests which do not match an
Allow or a Deny directive are denied by default.


To the OP:
There should not be a space in 'allow, deny' ...


HansH


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 09:23 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0