Quantcast
Channel: sshnet Discussions Rss Feed
Viewing all articles
Browse latest Browse all 1729

New Post: SCP Error !

$
0
0
Finally i have the info you need from me !

Yes you are correct reporting that the problem occurs when the file i am uploading exists already ! In my case the owner of the file is the user that uploads the file and it has read or write permissions to the file ! The group of the file also is the group that the user belongs ! And the group and other has read permissions also !
Since the owner has read/write should be enough to set the date/time info. I wonder also if it is a security issue and not bug since the issue occurs after the file upload
is completed successfully !

I report that if the file is not existing the error message is not appearing !

In my application if i have access to ssh shell i perform an deletion of the file first and then i upload it !So every time is like an first time ! If there was a delete sub in the scp class i would call it first and then i would use the upload so the issue would not appear. Some implementation i have does not have shell access so the only way is the upload and cannot do rm....

So i propose three solutions for you;
  1. It would help if you implement an delete sub in the scp class since shell access is not always accessible in order to use the command line deletion !
  2. You can add an deletefirst parameter in the upload function so that if the user sets it to true it would delete the file first and then upload...
  3. All above !

Viewing all articles
Browse latest Browse all 1729

Trending Articles