EldoS | Feel safer!

Software components for data protection, secure storage and transfer

Using HTTPS sample to upload file

Also by EldoS: RawDisk
Access locked and protected files in Windows, read and write disks and partitions and more.
Posted: 11/08/2010 14:56:54
by GERALD MORRIS (Standard support level)
Joined: 11/08/2010
Posts: 27

I am using the HTTPS UploadFile sample project

I have entered the URL in the format(https://sftp.someserver.com/test)
In the RequestParameters I entered the username and password
I get an EEISimpleSSLClientError Message: connection error(-1)
Is there any way to get more details on exactly what the error is?

If I use the same URL and parameters in IE I am able to connect with no problem

Any help appreciated


I am using the evaluation product.
Posted: 11/09/2010 01:22:34
by Vsevolod Ievgiienko (EldoS Corp.)


Please clarify which demo do you use: VCL or .NET?

If VCL, then change SSLEnabled property of TElHTTPSClient component to true, because in HTTPBlackbox\FileUpload demo project it is set to false.
Posted: 11/09/2010 09:33:12
by GERALD MORRIS (Standard support level)
Joined: 11/08/2010
Posts: 27

I am using VCL with Delphi 6.
I chnaged SSLEnabled property to true.
I am still getting the same error (Connection error (-1))

Here is my code

procedure TFrmFileUpload.BtStartClick(Sender: TObject);
FS: TFileStream;
SL: TStringList;
vurl := 'https://sftp.somedomain.com/uploads';
if not HttpClient.Active then
if FileExists(EdFileName.Text) then
FS := TFileStream.Create(EdFileName.Text, fmOpenRead + fmShareDenyWrite);
SL := TStringList.Create;
PBUploading.Min := 0;
PBUploading.Max := FS.Size;
PBUploading.Position := 0;
BtStart.Caption := 'Stop';
vfilename := ExtractFileName(EdFileName.Text);
HttpClient.Post(vurl, SL, 'testfile', vfilename, FS, 'text/plain', True);
BtStart.Caption := 'Start';
Application.MessageBox('Cant open the specified file.', 'Error', MB_OK);
pbUploading.Position := 0;
BtStart.Caption := 'Start';
Posted: 11/09/2010 10:17:29
by Eugene Mayevski (EldoS Corp.)

First of all please handle OnSSLError event and see if any error is reported.

Next, the address "sftp.somedomain.com/uploads" looks suspicious. I'd say it requires either SFTP or FTPS uploads, and not HTTPS.

Sincerely yours
Eugene Mayevski
Posted: 11/09/2010 12:12:56
by GERALD MORRIS (Standard support level)
Joined: 11/08/2010
Posts: 27

There is no OnSSLError associated with TEIHTTPSClient
There is an OnError event but when I tested again it did not get triggered.

I then tried connecting using the IndySTFP client demo
I used sftp.somedomain.com:443/uploads as host
It gets to FSFTPClient.Open in procedure TElIdSFTPClient.Connect.
After that nothing happens for about a minute and then I get the error
connection failed(error code is 6)

I then tried the SophisticatedClient/sftpdemo
I used sftp.somedomain.com:443/uploads as host
I got a 10060 time out error

The server they are using is Fastream IQ HTTP Server
Posted: 11/09/2010 12:44:37
by Eugene Mayevski (EldoS Corp.)

Port 443 is indeed HTTPS port, so my initial assumption was wrong. I think we need the actual URL to do tests and to understand anything.

Sincerely yours
Eugene Mayevski
Posted: 11/09/2010 14:31:09
by GERALD MORRIS (Standard support level)
Joined: 11/08/2010
Posts: 27

Yes. Email me with your email address and I will provide the URL and log in info
Posted: 11/09/2010 14:39:41
by Eugene Mayevski (EldoS Corp.)

I've moved the topic to HelpDesk for investigation.

Sincerely yours
Eugene Mayevski
Also by EldoS: CallbackFilter
A component to monitor and control disk activity, track file and directory operations (create, read, write, rename etc.), alter file data, encrypt files, create virtual files.



Topic viewed 1853 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!