-
Notifications
You must be signed in to change notification settings - Fork 22
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
Preserve file permissions broken #142
Comments
I need to perform some tests to see how the file permission stuff works But I think the I have a file that has the following permissions
But vsftpd reports (using LIST command):
As you can see, (some) FTP servers report wrong permissions Perhaps FTP servers don't report the true file permissions but the permissions granted to the FTP client (this always seem to be the case with MLSD) MLSD: permission handling is completely broken, and servers may report permissions that don't map to UNIX permissions, so overall the feature can be considered broken and must be removed. But I'm not sure that will fix the issue you're seeing, I'll perform tests to get a better picture of the situation ... |
Thank you for your response. In my case the permissions on my site and the server site are correct if I look in my terminal / in SSH. |
Well it shouldn't override default file permissions if the It works as expected with the FTP protocol, I just verified that vsFTPd reports the real permissions, I was looking in a different directory. If using MLSD, some servers will report stuff that doesn't map to unix permissions, so it's "partially" broken when it comes to applying permissions after downloading files, depends on the server. Now I have to see how it works with SFTP, it's probably specifying file permissions when uploading a file or something, and the |
Oh, yes, I use SSH FTP (SFTP) |
Sorry for the long delay. I've been unable to set up a local SSH server, but I did upload a few files to source forge, files with unsuitable permissions and those permissions were not preserved, so SF is setting its default permissions It's easy for to you determine if gFTP is actually the culprit, upload files with permissions 600, 644, 755, 777 and so on, if all those permissions are preserved then it may be gftp, otherwise the server is applying some defaults And the log reveals info, when gftp preserves permissions, you'll see that in the log, it explicitly tells you whether it succeeded changing permissions after uploading files, copying and pasting some lines would not be a bad idea |
Ah, preserve permission sets the permissions of my local computer file on the ftp storage. And the other permissions seems to be the server default. In the first place I thought preserving the permissions means that it won't change the file permission of the file on the server, if gFTP overrides an existing file. |
Regardless if I enable or disable the setting, gftp always changes the file permissions.
If I send the file from my local computer to the webspace, the file in the webspace now has the same permissions like on my local computer.
This breaks the website, since of course on my local computer only the owner and the group can read the file but on the webspace everyone needs to read the file as a visitor.
The text was updated successfully, but these errors were encountered: