Verzeichnisschutz funktioniert nicht

Irgendwelche Probleme mit XAMPP für Windows? Dann ist hier genau der richtige Ort um nachzufragen.

Verzeichnisschutz funktioniert nicht

Postby Papillon » 30. May 2014 19:19

Hallo,

ich habe xampp portable 1.8.3 auf einem Stick installiert.
Anschließend habe ich über http://localhost/security/xamppsecurity.php das XAMPP-Verzeichnis abgesichert.
In \htdocs\xampp\.htaccess steht danach folgendes:
Code: Select all
AuthName "xampp user"
AuthType Basic
AuthUserFile "N:\xampp\security\xampp.users"
require valid-user


Unter N:\xampp\security\xampp.users steht folgendes:
Code: Select all
admin:$apr1$jvFkQTCd$ADOMVwwRDl87uvqg6WZOH/


Ich habe den Browser geschlossen und Apache neu gestartet. Leider kommt bei einem Zugriff auf Xampp über http://localhost/xampp/ keine Verzeichnisschutzabfrage.
Die Apache error.log ist leer.

Wo liegt der Fehler?

Vielen Dank

Papi
Papillon
 
Posts: 4
Joined: 30. May 2014 19:11
Operating System: Windows 7

Re: Verzeichnisschutz funktioniert nicht

Postby Nobbie » 30. May 2014 20:59

Papillon wrote:In \htdocs\xampp\.htaccess steht danach folgendes:


Es gibt unter Xampp kein Verzeichnis \htdocs \xampp (auf oberster Ebene).
Nobbie
 
Posts: 13183
Joined: 09. March 2008 13:04

Re: Verzeichnisschutz funktioniert nicht

Postby Papillon » 30. May 2014 21:45

Der komplette Pfad ist in meinem Fall: N:\xampp\htdocs\xampp\.htaccess
Diesen Pfad gibt es im Zip-Paket von Xampp Portable. Da liegt ja so einiges drin.
Papillon
 
Posts: 4
Joined: 30. May 2014 19:11
Operating System: Windows 7

Re: Verzeichnisschutz funktioniert nicht

Postby Nobbie » 30. May 2014 22:05

Papillon wrote:Der komplette Pfad ist in meinem Fall: N:\xampp\htdocs\xampp\.htaccess
Diesen Pfad gibt es im Zip-Paket von Xampp Portable. Da liegt ja so einiges drin.


Das ist schon einmal extrem schlecht, dass Deine Beschreibung so schwere Fehler hat.

Wie ist in der httpd,conf der "DocumentRoot" definiert?
Nobbie
 
Posts: 13183
Joined: 09. March 2008 13:04

Re: Verzeichnisschutz funktioniert nicht

Postby Papillon » 31. May 2014 08:40

httpd.conf:
Code: Select all
#
# DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
#
DocumentRoot "/xampp/htdocs"
<Directory "/xampp/htdocs">
    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://httpd.apache.org/docs/2.4/mod/core.html#options
    # for more information.
    #
    Options Indexes FollowSymLinks Includes ExecCGI

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   AllowOverride FileInfo AuthConfig Limit
    #
    AllowOverride All

    #
    # Controls who can get stuff from this server.
    #
    Require all granted
</Directory>
Papillon
 
Posts: 4
Joined: 30. May 2014 19:11
Operating System: Windows 7

Re: Verzeichnisschutz funktioniert nicht

Postby Nobbie » 31. May 2014 13:53

Da steht also wie erwartet auch kein Laufwerksbuchstabe drin, dann lass den auch in der .htaccess weg (und die Backslashes in Slashes ändern):

Statt

AuthUserFile "N:\xampp\security\xampp.users"

einfach

AuthUserFile "/xampp/security/xampp.users"
Nobbie
 
Posts: 13183
Joined: 09. March 2008 13:04

Re: Verzeichnisschutz funktioniert nicht

Postby Papillon » 31. May 2014 15:17

Leider bewirkt dies keinerlei Änderung.
Papillon
 
Posts: 4
Joined: 30. May 2014 19:11
Operating System: Windows 7

Re: Verzeichnisschutz funktioniert nicht

Postby Nobbie » 31. May 2014 15:37

Vielleicht ist ja AllowOverride nicht richtig gesetzt, ansonsten schau in den Access Log und in den Error Log - so schwer kann das nicht sein, mir fehlen leider alle Dateien, die Du vor Dir liegen hast.
Nobbie
 
Posts: 13183
Joined: 09. March 2008 13:04


Return to XAMPP für Windows

Who is online

Users browsing this forum: No registered users and 39 guests