Project

General

Profile

Symlink to a /home subdirectory incurs 403

Added by Wyverald almost 13 years ago

Sorry for yet another 403 problem thread, but I searched all over the Internet for 2 hours and none of the solutions provided worked for me.

The distro is Fedora 16, lighttpd is straight from the repos (1.4.31 ssl), and the config files are almost 100% untouched (well, except for debug.request-handling). Document root is /var/www, and `ls -l /var/www` gives

drwxr-xr-x. 2 root root 4096 Jul  9 09:44 lighttpd
lrwxrwxrwx. 1 root root   31 Jul 10 15:08 poisson -> /home/wyverald/projects/poisson

And I promise you, I quadruple-checked that /home, /h/wyverald, /h/w/projects and /h/w/p/poisson all have 755. I even did `su lighttpd` and `cat /home/wyverald/projects/poisson/script.js` or `cat /var/www/poisson/script.js` without a problem.

Now when I go http://localhost/poisson/script.js, I get a 403, and the log has this to say:

2012-07-10 16:22:43: (response.c.300) -- splitting Request-URI
2012-07-10 16:22:43: (response.c.301) Request-URI  :  /poisson/script.js
2012-07-10 16:22:43: (response.c.302) URI-scheme   :  http
2012-07-10 16:22:43: (response.c.303) URI-authority:  59.66.130.237
2012-07-10 16:22:43: (response.c.304) URI-path     :  /poisson/script.js
2012-07-10 16:22:43: (response.c.305) URI-query    :
2012-07-10 16:22:43: (response.c.349) -- sanatising URI
2012-07-10 16:22:43: (response.c.350) URI-path     :  /poisson/script.js
2012-07-10 16:22:43: (mod_access.c.135) -- mod_access_uri_handler called
2012-07-10 16:22:43: (response.c.470) -- before doc_root
2012-07-10 16:22:43: (response.c.471) Doc-Root     : /var/www
2012-07-10 16:22:43: (response.c.472) Rel-Path     : /poisson/script.js
2012-07-10 16:22:43: (response.c.473) Path         :
2012-07-10 16:22:43: (response.c.521) -- after doc_root
2012-07-10 16:22:43: (response.c.522) Doc-Root     : /var/www
2012-07-10 16:22:43: (response.c.523) Rel-Path     : /poisson/script.js
2012-07-10 16:22:43: (response.c.524) Path         : /var/www/poisson/script.js
2012-07-10 16:22:43: (response.c.541) -- logical -> physical
2012-07-10 16:22:43: (response.c.542) Doc-Root     : /var/www
2012-07-10 16:22:43: (response.c.543) Rel-Path     : /poisson/script.js
2012-07-10 16:22:43: (response.c.544) Path         : /var/www/poisson/script.js
2012-07-10 16:22:43: (response.c.561) -- handling physical path
2012-07-10 16:22:43: (response.c.562) Path         : /var/www/poisson/script.js
2012-07-10 16:22:43: (response.c.608) -- access denied
2012-07-10 16:22:43: (response.c.609) Path         : /var/www/poisson/script.js

http://localhost/lighttpd works fine (the "lighttpd - fly light" page). This means that directories directly under /var/www work fine, but symlinks do not. server.follow-symlink is "enable"d by the way.

Any help? Thanks in advance.


Replies (1)

RE: Symlink to a /home subdirectory incurs 403 - Added by nitrox almost 13 years ago

Attach strace to it: strace -fF -s 2048 -o foo.log -p <pidoflighty>

Search foo.log for the resulting 403 request and check again.

    (1-1/1)