1

I was attempting to create an SFTP server and successfully managed to get it to the point where I can view folders from an external location. However, whenever I try to copy folders across from the remote machine to the local machine, FileZilla gives the error "Open for read: permission denied".

In general the solution given online is to give the folder permissions however I made sure that the file I tried to get have the specific permission for the user as well as the "Everyone" setting but neither of these fixed the issue.

Interestingly, I could move files within the remote server, it was just a case of moving them from the remote server to the client. If I attempt to move files from Client to Server, this creates the file but then will not write any data to it (ie. It creates a blank file).

Further details about the problem:

The SFTP server was set up via the instructions found here. In addition, I have also set up a file tree where users are locked within their own folders. This can be seen in my sftp_config file (located in C:/ssh/...) where my settings are as follows:

LogLevel VERBOSE
ForceCommand internal-sftp
AllowTCPForwarding no
X11Forwarding no

Match User User1
    ChrootDirectory "C:/SFTP Server/User1"

Match User User2
    ChrootDirectory "C:/SFTP Server/User2"
...

The folders located in SFTP Server have their security set such that "Everyone" has full control in order to prevent issues with permissions however I still log in with the Administrator account on the Windows 10 machine running the server but this doesn't change anything in that while I can create and delete files/folders on the server, I can not read or write their data.

In addition, the folders I wish to access have been shared over LAN (Windows' built-in network share) and work correctly which means it's specific to the setup of the SFTP server itself.

Accessing it from the internal IP address, didn't help anything. I also tried using WinSCP however this did not change anything.

As for debug logging, I was unable to get this to work effectively. Logs seen in Event Viewer only showed logging in via SFTP (including when I set LogLevel to DEBUG2) which doesn't help.

Edit: A resolution has been found and the server is working as expected with no issues, however I am not sure what changed and therefore have not answered the question. To help others, between it not working and it working, I set up a printer that connects via SMB to a different folder, and some part of that process fixed the server issues I was having

Ciaran
  • 31
  • 6
  • 1
    Welcome to Stackexchange! Please provide a little more information. A few suggestions: How is the sftp server set up. What are the permissions and the account you use. Does this happen with one folder or any folders. What if you use the sftp client on that same server (i.e. is it a problem related to Filezilla or the server). What do you get when you enable debug logging on the client and/or the server. – berndbausch Mar 23 '21 at 23:45

0 Answers0