EldoS | Feel safer!

Software components for data protection, secure storage and transfer

SimpleSftpClient UploadFile()

Also by EldoS: RawDisk
Access locked and protected files in Windows, read and write disks and partitions and more.
#1057
Posted: 08/22/2006 16:46:11
by Matt Harter (Basic support level)
Joined: 08/22/2006
Posts: 5

I am able to successfully upload a file that is less than 50KB. I am trying to now upload files that are 4-15MB and am now receiving and error. I did not change the code in between the successful smaller file and the failed larger file. What do I need to do to use the simpleSftpClient to upload larger files? Should I not be using the simple method?

The error that I am getting is:

"Offset and length were out of bounds for the array or count is greater than the number of elements from index to the end of the source collection."
#1059
Posted: 08/22/2006 23:28:37
by Eugene Mayevski (EldoS Corp.)

1) Please specify, what version of SecureBlackbox you are using. If it's .NET, please tell us if you use .NET 1.0/2.0 package or .NET CF package (they are different in SecureBlackbox 4).
2) what method are you currently using for file download?
3) what server software you are connecting to?


Sincerely yours
Eugene Mayevski
#1061
Posted: 08/23/2006 09:03:02
by Matt Harter (Basic support level)
Joined: 08/22/2006
Posts: 5

I am using SecureBlackbox for .NET version 4.4.94. I am developing in the 1.1 framework. In my application I am only looking to upload files to a sftp server. This server that I am uploading to is a UNIX server.

#1062
Posted: 08/23/2006 09:06:15
by Matt Harter (Basic support level)
Joined: 08/22/2006
Posts: 5

Thanks for the help by the way. I am hoping to get over this hurdle. I think this product has a lot of great features.

I should add to the above post that I am currently using an evaluation copy to test out how it all works. I did request a temporary unlock key to get accurate performance measurements. Hopefully that is not causing an issue with uploads.
#1064
Posted: 08/23/2006 12:12:12
by Eugene Mayevski (EldoS Corp.)

Thank you for answering. This is the second report of this kind, and we will investigate the issue deeper tomorrow. I am moving your request to HelpDesk.


Sincerely yours
Eugene Mayevski
#1065
Posted: 08/23/2006 14:31:45
by Eugene Mayevski (EldoS Corp.)

(I am duplicating the HelpDesk answer here in order to let other users be aware of the problem).

Please insert the following before the call to UploadFile() (or UploadFiles or UploadStream) method:

Client.AutoAdjustTransferBlock = false;
Client.UploadBlockSize = 32768;

This sets the size of the upload block to the size that is guaranteed to be handled correctly by all servers. In fact the issue only happens with OpenSSH due to too large block size being set automatically for this server.

More generic fix will be available in the next beta of SecureBlackbox 5.


Sincerely yours
Eugene Mayevski
#1066
Posted: 08/23/2006 16:46:47
by Matt Harter (Basic support level)
Joined: 08/22/2006
Posts: 5

Thanks. That solved the issue. I appreciate the help.
#8854
Posted: 02/11/2009 11:44:38
by y song (Basic support level)
Joined: 02/10/2009
Posts: 12

Client.AutoAdjustTransferBlock = false;
Client.UploadBlockSize = 32768;

I suppose that these two lines are not necessary for current version of SecureBlackbox ??

thanks
#8855
Posted: 02/11/2009 11:52:04
by Eugene Mayevski (EldoS Corp.)

That was server-specific problem. Now we have added detection of most specific servers, so less adjustment of this kind is needed. But it's possible that for some rare server such or similar adjustment will he necessary.


Sincerely yours
Eugene Mayevski
Also by EldoS: Solid File System
A virtual file system that offers a feature-rich storage for application documents and data with built-in compression and encryption.

Reply

Statistics

Topic viewed 3291 times

Number of guests: 1, registered members: 0, in total hidden: 0




|

Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!