80后的细娃儿

两段路由自动登录代码,TELNET自动登录

@echo off

echo set sh=WScript.CreateObject("WScript.Shell") >>Telnet_tmp.vbs 
echo WScript.Sleep 300 >>Telnet_tmp.vbs 
echo sh.SendKeys "open 192.168.3.1" >>Telnet_tmp.vbs 
echo WScript.Sleep 300 >>Telnet_tmp.vbs 
echo sh.SendKeys "{ENTER}" >>Telnet_tmp.vbs
echo WScript.Sleep 300 >>Telnet_tmp.vbs
echo sh.SendKeys "root{ENTER}">>Telnet_tmp.vbs
echo WScript.Sleep 300 >>Telnet_tmp.vbs
echo sh.SendKeys "admin{ENTER}">>Telnet_tmp.vbs 
start Telnet
cscript //nologo Telnet_tmp.vbs 

ping -n 3 127.1>nul

del Telnet_tmp.vbs
exit

 

 

[code type=php]

@echo off
rem 192.168.1.1 IP地址
rem useradmin   用记名
rem adminuser 用记密码
echo Set WshShell = CreateObject("WScript.Shell")>%tmp%TelDelphi1.vbs
echo WshShell.Run "telnet 192.168.3.1">>%tmp%TelDelphi1.vbs
echo WScript.Sleep(2000)>>%tmp%TelDelphi1.vbs
echo WshShell.SendKeys "root{enter}">>%tmp%TelDelphi1.vbs
echo WScript.Sleep(2000) >>%tmp%TelDelphi1.vbs
echo WshShell.SendKeys "admin{enter}">>%tmp%TelDelphi1.vbs
echo WScript.Sleep(2000) >>%tmp%TelDelphi1.vbs
echo WshShell.SendKeys "sys{enter}">>%tmp%TelDelphi1.vbs
echo WScript.Sleep(2000) >>%tmp%TelDelphi1.vbs
echo WshShell.SendKeys "arp ?">>%tmp%TelDelphi1.vbs
start cscript /nologo %tmp%TelDelphi1.vbs
ping -n 10 127.1>nul
del /q %tmp%TelDelphi1.vbs
 [/code]

点赞

发表评论

电子邮件地址不会被公开。 必填项已用*标注