zoukankan      html  css  js  c++  java
  • 利用Ganymed SSH2模拟SSH操作

    利用Ganymed SSH-2模拟SSH操作

     
          今天在看SFTP资料时,无意中看到了Ganymed SSH-2,写了个简单demo,通过,感觉挺好用,特记录如之。
    简介
     
    Ganymed SSH-2 for Java is a library which implements the SSH-2 protocol in pure Java (tested on J2SE 1.4.2 and 5.0). It allows one to connect to SSH servers from within Java programs. It supports SSH sessions (remote command execution and shell access), local and remote port forwarding, local stream forwarding, X11 forwarding, SCP and SFTP. There are no dependencies on any JCE provider, as all crypto functionality is included.
     
    程序:
     
    运行结果:
     
    connect ok
    Authentication ok
    Here is some information about the remote host:
    Linux localhost.localdomain 2.6.22 #1 SMP Wed Aug 13 11:24:59 CST 2008 i686 i686 i386 GNU/Linux
    ExitCode: 0
  • 相关阅读:
    基于Java的地铁线路查询系统设计思路
    个人总结05
    构建之法读书笔记03
    Java 8 (二) 新的时间API
    MySql基础笔记(三)其他重要的事情
    MySql基础笔记(二)Mysql语句优化---索引
    JavaScript基础笔记(十四)最佳实践
    JavaScript基础笔记(十三)测试和调试
    MySql基础笔记(一)Mysql快速入门
    JavaScript基础笔记(十二)Ajax
  • 原文地址:https://www.cnblogs.com/hehe520/p/6330189.html
Copyright © 2011-2022 走看看