Skip to content

Handling of symlinks #27

@dh-benrod5

Description

@dh-benrod5

mod_xsendfile provides a means to white-list directories that it should be able to deliver file content from.

XSendFilePath

However, it doesn't filter based on the canonical path. Creating a symlink from any white-listed path allows read access to files that the web server has access to.

e.g. example.com/passwd -> /etc/passwd
e.g. example.com/config.php -> /home/some-other-user/example.org/config.php

This does still respect Apache's uid/gid file permissions, but does not appear to be the intended behavior, and allows for a broader and likely unintended access to files on servers using suexec, suphp, or similar Apache modules to separate user privileges.

I have confirmed this behavior in mod_xsendfile 0.12 (as packaged by Debian) and the 1.0b1 beta release.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions