Hi
this code for get identity of mikrotik device. after run this code. only work for last IP
lines in ip.txt
192.168.3.6 --> NET_6
192.168.3.8 --> NET_8
192.168.3.10 --> NET_10
import os
filename = 'ip.txt'
with open(filename, 'r') as f:
for line in f:
pq = os.popen('plink -batch admin@' + line + ' -pw 123456@ "/system identity print"')
line = pq.readline()
print(line)
Using username "admin".
Using username "admin".
name: NET_10