C# Windows App - SSH

J

Jesse Charbneau

Hi Everyone,
If I'm posting to the wrong group, please let me know. I have an
application that I am writing to communicate from a Windows host to a
UNIX server via SSH.

What I would like to do, is send one command at a time, but without
having to re-authenticate for each command. I am currently using a COM
component (trial version) from djHD, but this only allows me to use the
ExecCommand method and putting a command like "cmd1;cmd2;cmd3" doesn't
seem to work. I have emailed the author, but so far, have not heard
back.

I have also looked at using a opensource ssh lib from granados, but
found the documentation and samples where almost non-existent.

I really need the functionality typically found in the scripting
language Expect. Is there any way to accomplish this using C#? I am
building a Windows Forms app, and would really like to stick with C# if
possible.

Thanks for the assistance,
Jess

If anyone has samples of using the granados libs that would certainly
help. The sample that came with the lib, did more of a send a byte at
a time instead of a full command, which seemed a little confusing.
 
S

Scott Roberts

Jesse Charbneau said:
Hi Everyone,
If I'm posting to the wrong group, please let me know. I have an
application that I am writing to communicate from a Windows host to a
UNIX server via SSH.

What I would like to do, is send one command at a time, but without
having to re-authenticate for each command. I am currently using a COM
component (trial version) from djHD, but this only allows me to use the
ExecCommand method and putting a command like "cmd1;cmd2;cmd3" doesn't
seem to work. I have emailed the author, but so far, have not heard
back.

I have also looked at using a opensource ssh lib from granados, but
found the documentation and samples where almost non-existent.

I really need the functionality typically found in the scripting
language Expect. Is there any way to accomplish this using C#? I am
building a Windows Forms app, and would really like to stick with C# if
possible.

Thanks for the assistance,
Jess

If anyone has samples of using the granados libs that would certainly
help. The sample that came with the lib, did more of a send a byte at
a time instead of a full command, which seemed a little confusing.

Check out http://www.catalyst.com

I've not tried the SSH stuff, but their other components are nice.
 
C

Cletus Van Damme

Jesse Charbneau said:
Hi Everyone,
If I'm posting to the wrong group, please let me know. I have an
application that I am writing to communicate from a Windows host to a
UNIX server via SSH.

What I would like to do, is send one command at a time, but without
having to re-authenticate for each command. I am currently using a COM
component (trial version) from djHD, but this only allows me to use the
ExecCommand method and putting a command like "cmd1;cmd2;cmd3" doesn't
seem to work. I have emailed the author, but so far, have not heard
back.

I have also looked at using a opensource ssh lib from granados, but
found the documentation and samples where almost non-existent.

I really need the functionality typically found in the scripting
language Expect. Is there any way to accomplish this using C#? I am
building a Windows Forms app, and would really like to stick with C# if
possible.

Thanks for the assistance,
Jess

If anyone has samples of using the granados libs that would certainly
help. The sample that came with the lib, did more of a send a byte at
a time instead of a full command, which seemed a little confusing.

http://www.weonlydo.com/index.asp?showform=SSH.NET

Have a look at this component, looks like it may do what you need. I have
no experience with it personally, though we did look into using it, however
we ended up not needing SSH functionality.

CVD
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top