I'm connecting to a server using sftp through console. I'm trying to download a folder which has some files without write permission for anyone. When I use get, those files throw an error that says I need write permissions, but the rest download fine.
It seems to be a problem with the console program, I tried WinSCP and it works fine, but I'd like to know if it's possible to do it from a terminal without changing permissions.
The local system runs Windows 7 with Cygwin, the remote one Ubuntu 12.04.
Couldn't open local file "website/sites/default/default.settings.php" for writing: Permission denied Download of file /var/www/website/sites/default/default.settings.php to website/sites/default/default.settings.php failed
Permissions on remote server:
website/ 755 sites/ 775 default/ 555 default.setting.php 664
The local directory in which I start sftp has 755 permissions. After the get, files and directories seem to retain the same permissions they had on the remote server, so since default has no write permissions, nothing can be downloaded into it.
How can I get files without retaining the original permissions?