Chinaunix首页 | 论坛 | 博客

qsh

  • 博客访问: 3955348
  • 博文数量: 1015
  • 博客积分: 15904
  • 博客等级: 上将
  • 技术积分: 8572
  • 用 户 组: 普通用户
  • 注册时间: 2008-07-04 19:16
文章分类

全部博文(1015)

文章存档

2019年(1)

2017年(1)

2016年(19)

2015年(27)

2014年(30)

2013年(95)

2012年(199)

2011年(72)

2010年(109)

2009年(166)

2008年(296)

分类: 系统运维

2012-04-02 16:01:49

 
# $language = "VBScript"
# $interface = "1.0"
' Connect to an SSH server using the SSH2 protocol. Specify the
' username and password and hostname on the command line as well as
' some SSH2 protocol specific options.
Sub Main
  Dim host
  host = "ssh.somecompany.com"
  Dim user
  user = "myusername"
  ' Prompt for a password instead of embedding it in a script...
  '
  Dim passwd
  passwd = crt.Dialog.Prompt("Enter password for " & host, "Login", "", True)
  ' Build a command-line string to pass to the Connect method.
  '
  cmd = "/SSH2 /L " & user & " /PASSWORD " & passwd & " /C 3DES /M MD5 " & host
  crt.Session.Connect cmd
End Sub
阅读(7231) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~