The following examples were posted with the original JSch java library,
and were translated to C#
====================================================================
- Shell.cs
This program enables you to connect to sshd server and get the shell prompt.
You will be asked username, hostname and passwd.
If everything works fine, you will get the shell prompt. Output will
be ugly because of lacks of terminal-emulation, but you can issue commands.
- Exec.cs
This program will demonstrate remote exec.
You will be asked username, hostname, displayname, passwd and command.
If everything works fine, given command will be invoked
on the remote side and outputs will be printed out. In this sample,
X forwarding is enabled, so you can give an X client as a command.
- PortForwardingR.cs
This program will demonstrate the port forwarding like option -R of
ssh command; the given port on the remote host will be forwarded to
the given host and port on the local side.
You will be asked username, hostname, port:host:hostport and passwd.
If everything works fine, you will get the shell prompt.
Try the port on remote host.
- PortForwardingL.cs
This program will demonstrate the port forwarding like option -L of
ssh command; the given port on the local host will be forwarded to
the given remote host and port on the remote side.
You will be asked username, hostname, port:host:hostport and passwd.
If everything works fine, you will get the shell prompt.
Try the port on localhost.
- StreamForwarding.cs
This program will demonstrate the stream forwarding. The given Java
I/O streams will be forwared to the given remote host and port on
the remote side. It is simmilar to the -L option of ssh command,
but you don't have to assign and open a local tcp port.
You will be asked username, hostname, host:hostport and passwd.
If everything works fine, System.in and System.out streams will be
forwared to remote port and you can send messages from command line.
- UserAuthPubKey.cs
This program will demonstrate the user authentification by public key.
You will be asked username, hostname, privatekey(id_dsa) and passphrase.
If everything works fine, you will get the shell prompt
- ScpTo.cs
This program will demonstrate the file transfer from local to remote.
You will be asked passwd.
If everything works fine, a local file 'file1' will copied to
'file2' on 'remotehost'.
- ScpFrom.cs
This program will demonstrate the file transfer from remote to local
You will be asked passwd.
If everything works fine, a file 'file1' on 'remotehost' will copied to
local 'file1'.
- Sftp.cs
This program will demonstrate the sftp protocol support.
You will be asked username, host and passwd.
If everything works fine, you will get a prompt 'sftp>'.
'help' command will show available command.
In current implementation, the destination path for 'get' and 'put'
commands must be a file, not a directory.
- KnownHosts.cs
This program will demonstrate the 'known_hosts' file handling.
You will be asked username, hostname, a path for 'known_hosts' and passwd.
If everything works fine, you will get the shell prompt.
In current implementation, jsch only reads 'known_hosts' for checking
and does not modify it.
- KeyGen.cs
This progam will demonstrate the RSA/DSA keypair generation.
You will be asked a passphrase for output_keyfile.
If everything works fine, you will get the DSA or RSA keypair,
output_keyfile and output_keyfile+".pub".
The private key and public key are in the OpenSSH format.
- ChangePassphrase.cs
This program will demonstrate to change the passphrase for a
private key file instead of creating a new private key.
A passphrase will be prompted if the given private-key has been
encrypted. After successfully loading the content of the
private-key, the new passphrase will be prompted and the given
private-key will be re-encrypted with that new passphrase.
- AES.cs
This program will demonstrate how to use "aes128-cbc".
- Daemon.cs
This program will demonstrate how to provide a network service like
inetd by using remote port-forwarding functionality.
- ViaHTTP.cs
This program will demonstrate the ssh session via HTTP proxy.
You will be asked username, hostname, proxy-server and passwd.
If everything works fine, you will get the shell prompt.
没有合适的资源?快使用搜索试试~ 我知道了~
用c#写的ssh
共244个文件
cs:171个
entries:17个
root:17个
5星 · 超过95%的资源 需积分: 40 457 下载量 41 浏览量
2008-04-07
13:35:57
上传
评论
收藏 398KB ZIP 举报
温馨提示
用c#写的ssh <br>
资源推荐
资源详情
资源评论
收起资源包目录
用c#写的ssh (244个子文件)
ChannelSftp.cs 65KB
Session.cs 46KB
IdentityFile.cs 24KB
KeyPair.cs 17KB
Scp.cs 17KB
Util.cs 14KB
Channel.cs 13KB
Sftp.cs 13KB
Sftp.cs 13KB
PipedInputStream.cs 13KB
KnownHosts.cs 13KB
Channel.old.cs 12KB
KeyPairRSA.cs 10KB
SshStream.cs 10KB
DHG1.cs 10KB
Scp.old.cs 10KB
SftpATTRS.cs 9KB
DHGEX.cs 9KB
Main.cs 9KB
UserAuthPublicKey.cs 8KB
ChannelForwardedTCPIP.cs 8KB
SshBase.cs 8KB
JSch.cs 8KB
SshShell.cs 8KB
CombinedStream.cs 7KB
KeyPairDSA.cs 7KB
PipedOutputStream.cs 7KB
ChannelX11.cs 7KB
UserAuthKeyboardInteractive.cs 6KB
sharpSshTest.cs 6KB
PortWatcher.cs 6KB
Buffer.cs 6KB
SignatureRSA.cs 6KB
KeyExchange.cs 6KB
Sftp.cs 5KB
ChannelDirectTCPIP.cs 5KB
SshHelper.cs 5KB
ScpFrom.cs 5KB
ScpFrom.cs 5KB
InputForm.cs 5KB
InputForm.cs 5KB
UserAuthPassword.cs 5KB
KnownHosts.cs 5KB
KnownHosts.cs 5KB
ProtectedConsoleStream.cs 5KB
ScpTo.cs 4KB
ScpTo.cs 4KB
IO.cs 4KB
SshTransferProtocolBase.cs 4KB
SignatureDSA.cs 4KB
ProxyHTTP.cs 4KB
UserAuthNone.cs 4KB
ViaHTTP.cs 4KB
ConsoleProgressBar.cs 4KB
ConsoleProgressBar.cs 4KB
ConsoleProgressBar.cs 4KB
ConsoleProgressBar.cs 4KB
Shell.cs 4KB
SshExe.cs 4KB
TripleDESCBC.cs 4KB
Packet.cs 4KB
Subsystem.cs 4KB
PortForwardingR.cs 4KB
StreamForwarding.cs 4KB
StreamForwarding.cs 4KB
InputForm.cs 4KB
AES.cs 4KB
KeyPairGenRSA.cs 4KB
UserAuthPubKey.cs 3KB
AES.cs 3KB
UserAuthPubKey.cs 3KB
SshFileTransferTest.cs 3KB
PortForwardingL.cs 3KB
Shell.cs 3KB
PortForwardingL.cs 3KB
PortForwardingR.cs 3KB
ChannelSftpStreamGet.cs 3KB
String.cs 3KB
AES128CBC.cs 3KB
ProgressForm.cs 3KB
ProgressForm.cs 3KB
HMACSHA1.cs 3KB
HMACSHA196.cs 3KB
HMACMD5.cs 3KB
HMACMD596.cs 3KB
ChannelSubsystem.cs 3KB
ChannelExec.cs 3KB
ChannelSession.cs 3KB
HostKey.cs 3KB
ChannelShell.cs 3KB
KeyPairGenDSA.cs 3KB
Random.cs 3KB
RequestWindowChange.cs 3KB
RequestSubsystem.cs 3KB
JStream.cs 3KB
RequestX11.cs 3KB
DH.cs 3KB
MD5.cs 2KB
SHA1.cs 2KB
AssemblyInfo.cs 2KB
共 244 条
- 1
- 2
- 3
ilovechao1314
- 粉丝: 17
- 资源: 4
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功
- 1
- 2
- 3
- 4
- 5
- 6
前往页