LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   access 403 forbidden - user_dir (https://www.linuxquestions.org/questions/linux-newbie-8/access-403-forbidden-user_dir-259431/)

sigurdne 11-26-2004 03:18 AM

access 403 forbidden - user_dir
 
I can't access the localhost/~user

the users public_html (and a index.html) is created and world readable (in fact 777 !)

in httpd.conf:

<Directory /home/*/public_html>
Options Indexes FollowSymLinks
Order allow,deny
Allow from all
</Directory>

Apache-PREFORK-AdvancedExtranetServer/2.0.52 (Mandrakelinux/8mdk) Hardened-PHP/4.3.9 Server at 127.0.0.1 Port 80

Regards

Sigurd

MasterC 11-26-2004 03:59 AM

I had to include the following to enable this on my setup:
Code:

<IfModule mod_userdir.c>
    UserDir public_html
</IfModule>

UserDir enabled masterc

And obviously, this enabled for my user, masterc.

Cool

sigurdne 11-26-2004 06:39 AM

It didn't help:
I have

Code:

LoadModule userdir_module    modules/mod_userdir.so
Code:

AddModule mod_userdir.c
Code:

<IfModule mod_userdir.c>
UserDir public_html
</IfModule>
UserDir enabled sigurd sn5607 kornelius

Sigurd

MasterC 11-27-2004 12:56 AM

I'm assuming you restarted apache after making the changes? If so, post up the permissions on your home directory as well as public_html ( ls -lh )

Cool

sigurdne 11-27-2004 03:56 AM

The home directory was 700 – but when I changed it to 701 – the access was permitted (it did'nt help to add read rights).
At this stage - public_html is 777.
Is this really necessary – giving executable right to everyone?

Sigurd

MasterC 11-27-2004 04:36 AM

No, you can go about it other ways. chgroup apache, change the group apache runs as to users, add apache to the users group, create an all new group, chgroup to that. Play with the perms to suit your needs, I personally don't have quite the strict perms you do on my home dir, it's not like I am hiding the code to unlock a nuclear war head in my home directory and don't want any other user on the system to read it ;)

Cool

sigurdne 11-27-2004 05:55 AM

Ok – thanks for the help - it really helped me a lot :)

Sigurd


All times are GMT -5. The time now is 03:44 AM.