import getpass
import telnetlib
HOST = input("Enter the IP Address of Device: ")
user = input("Enter your account: ")
password = getpass.getpass()
tn = telnetlib.Telnet(HOST)
tn.read_until(b"Username: ")
tn.write(user.encode('ascii') + b"\n")
if password:
tn.read_until(b"Password: ")
tn.write(password.encode('ascii') + b"\n")
tn.write(b"enable\n")
tn.write(b"terminal len 0\n")
tn.write(b"configure terminal\n")
tn.write(b"hostname amar\n")
tn.write(b"router eigrp 100\n")
tn.write(b"no auto-summary\n")
tn.write(b"network 0.0.0.0\n")
tn.write(b"exit\n")
tn.write(b"exit\n")
tn.write(b"show ip protocol\n")
tn.write(b"show version\n")
tn.write(b"write memory\n")
tn.write(b"exit\n")
print(tn.read_all().decode('ascii'))
Thanks for Reading
amartechstuff 😊😊
Sir if you will elaborate each line then it will be great for sure
ReplyDeleteSir if you will elaborate each line then it will be great for sure
ReplyDeleteSir if you will elaborate each line then it will be great for sure
ReplyDeletethat script does not work
ReplyDeleteo122b8ktbwb575 real dolls,dual stimulator,sex chair,penis sleeves,dildos,cheap sex toys,G-Spot Vibrators,horse dildo,sex toys b815h3gxrae082
ReplyDelete