Sign in to follow this  
Followers 0
michaelslamet

Connect to Mikrotik Router

2 posts in this topic

Hi!

Is there anyway to connect to Mikrotik Router using AutoIT? What I want to do is connect to the mikrotik router and release the ip address. Usually I do this manually through WinBox, but I would like to automate it using AutoIT.

Thanks in advance.

MS.

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

hi...

i connected... start

$user = "root"
$password ="xxxxxxxx"
$host ="5.0.0.1"
$port ="22"

$puty_exe = @ScriptDir & "\putty.exe"; putty salve local folder script

; putty -ssh -l usuario 5.0.0.1 p "port" -pw senha

;input

$command = RunWait(@comspec & " /C "&$puty_exe&" -ssh -l "&$user&" "&$host&" p "&$port&" -pw "&$password,@SystemDir, @SW_HIDE, 1)

While 1
$data = StdoutRead($command)
ConsoleWrite($data&@CRLF)
If @error Then ExitLoop
Wend
Edited by bhns

:bike: 

Att...Cleber Antônio Made in Bio zonte Minas Gerais  :sweating:

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0