Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove O_NOFOLLOW on opening of quota file #172

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Harfusha
Copy link

There is no need to use O_NOFOLLOW. Since .ftpquota is a reserved name for pure-ftpd. We would like to use symlinks for shared quotas across multiple users. Therefore, I am sending a request for a small update :-).

@jedisct1
Copy link
Owner

The reason for O_NOFOLLOW is that it's possible to create a .ftpquota link if the folder is accessible by other means (using PHP, SSH, etc). That would effectively allow for escaping the chroot jail.

@Harfusha
Copy link
Author

Oh i see. But if i would manually follow symlink before opening it and verified that the target file has same name as the inputed one, but diffrent path? Worst thing that could happen is that somebody would rewrite someone else quota or make some files in FileSystem.

Or add field to users in database that will contain path to .ftpquota. That would be better solution i think.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants