March 28, 2024, 08:49:56 AM

News:

Own IWBasic 2.x ? -----> Get your free upgrade to 3.x now.........


How do I call sftp?

Started by Rock Ridge Farm (Larry), December 28, 2006, 08:26:12 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Rock Ridge Farm (Larry)

The following will call ftp and get a file:
    error = FtpGetFileA(hconnect, <file to get>, <local file name>, 0, 0, 0x2, 0);
What call would I use for sftp (secure ftp/ssh)?
I am sure the open call would change as well.

Rock Ridge Farm (Larry)

Does the resounding silence indicate that I am the only one interested in this?

Bruce Peaslee

No, but I don't have the answer.   :-\
Bruce Peaslee
"Born too loose."
iTired (There's a nap for that.)
Well, I headed for Las Vegas
Only made it out to Needles

J B Wood (Zumwalt)

Don't know if this helps:
http://doc.ddart.net/msdn/header/include/wininet.h.html

This one might be more appropriate:
http://www.tek-tips.com/faqs.cfm?fid=5904

I don't have the time to translate them at the moment to Aurora or EBasic.

Rock Ridge Farm (Larry)

Both of those appear to be for regular ftp.
I have that working - it is sftp I can not find info about.
I implemented the ftp with little effort but can not find a comprable approach for sftp.
All I want to do is login and retreive one file do not need fancy screen interface just the code to login
and get one file.
I have 700 systems mixed windoz, unix, aix, sun, and linux. Many use only sftp for access.

Shannara

The secure edition of socket tools allow this I believe. There are also classes for Aurora for use with Socket Tools. It costs a pretty penny though.
Love is staying up all night with a sick child, or a healthy adult.

Mike Stefanik

The current version of SocketTools supports FTPS (FTP+SSL) but doesn't yet support SFTP (FTP+SSH); that's coming out in a few months with the next major release. As far as the Aurora classes are concerned, I haven't made any decisions about them since the compiler is still in beta. It's a side project of mine that I started last year, and really isn't part of the commercial SocketTools products per se. You're right that the SocketTools Library Edition would be out of the price range for most hobbiests, it's really designed for commercial software development. As Aurora moves along, we'll see what happens.
Mike Stefanik
www.catalyst.com
Catalyst Development Corporation

Rock Ridge Farm (Larry)

I am sinking here - have a major project that I could deploy using Aurora but I need to be able to build in
sftp. Got the ftp part to work but needs sftp.
Help!
I could possibly use the C++ lib if I knew how.

Ionic Wind Support Team

Unfortunately I have no idea myself.  Have you tried the normal channels like searching Google for SFTP + source, etc ?
Ionic Wind Support Team

Zen

Larry. I am looking into it now but there is no way I can have it done anytime soon.

Lewis

Vikki

January 07, 2007, 11:10:40 AM #10 Last Edit: January 07, 2007, 12:04:45 PM by Vikki
I don't know if any of this info will help you are not but it seems you may want to use InternetConnectA to pass the secure information (user/pass). Below are two links that may or may not be useful.

This first one is the declaration:

http://source.winehq.org/WineAPI/InternetConnectA.html

This next one is an example in PB (titled unattended ftp but talks about a secure ftp connection in the second post:

http://www.powerbasic.com/support/forums/Forum7/HTML/000593.html

From MS:

http://msdn2.microsoft.com/en-us/library/aa384363.aspx

Supposedly the ftp we're talking about is used over an ssh connection but I read that so many pages ago I'm not sure anymore.

Anywho, I'll keep looking...



Zen

Larry.

I would recomend reading through the source code for Putty. It has FTP over SSH in there somewhere, unfortunatley I don't have time to look, but maybe it can help.

Lewis

Rock Ridge Farm (Larry)

Putty is a bit large - I did find a sftp lib written in ms6 C++ - I think I will invest the time to convert it to Aurora.
Anyone else interested in this?

Zen

Yes larry I am interested in it. It would be good research for me as I do want to add SFTP and FTPS functionality to the CCL ftp class. HTTPS was easy as it is supported through the windows API, but for some reason FTPS and SFTP is not.

Lewis

Rock Ridge Farm (Larry)

Sure - leave the work to the old guy :)
Will keep you posted on my progress - it is a big lib.

Zen

lol. Well if you send me it or tell me where you got it from, I can take a look too.

Lewis

Rock Ridge Farm (Larry)

This is the lib I am looking at.

Zen

Ok thanks Larry.

I will take a look and see what I can do as soon as possible

Lewis

Rock Ridge Farm (Larry)

Well - I got sidetracked and never finished. Lewis - did you ever get to look at it.
Once more I find I am in need to be able to sftp to a site to retrieve files.
Help???