PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Forums Hébergement > Forum Hébergement serveur > comp.info.servers.unix > Restricting access with .htaccess; first IP then auth
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
comp.info.servers.unix Web servers for UNIX platforms.

Restricting access with .htaccess; first IP then auth

Réponse
 
LinkBack Outils de la discussion
Vieux 17/05/2005, 13h51   #1
Sjaakie
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Restricting access with .htaccess; first IP then auth

Hi all,

I wish to restrict access to a part of my website using htaccess. So far
I managed to restrict either by IP or by user. Is it possible to use
them in this order

1. restrict by IP, if allowed then display page, if denied then ..
2. validate username and password (.htpasswd)

not sure if this is possible at all, and how to put this in the
..htaccess file.

TIA
  Réponse avec citation
Vieux 17/05/2005, 17h51   #2
adam
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Restricting access with .htaccess; first IP then auth

you need to use the 'Satisfy any' directive

in your .htaccess you need the following lines..

Allow from <domain.com>
Require valid-user
Satisfy any

Satisy any will say if it's allowed from <domain.com> it's ok OR if
they are a valid-user (from anywhere) it's ok too.

  Réponse avec citation
Vieux 18/05/2005, 09h31   #3
Sjaakie
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Restricting access with .htaccess; first IP then auth

adam wrote:
> you need to use the 'Satisfy any' directive
>
> in your .htaccess you need the following lines..
>
> Allow from <domain.com>
> Require valid-user
> Satisfy any
>
> Satisy any will say if it's allowed from <domain.com> it's ok OR if
> they are a valid-user (from anywhere) it's ok too.
>


Thank you so much! I've been searching for this little line for days now

Cheers!
  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 22h31.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,06899 seconds with 11 queries