我想建立一個(gè)telnet連接,但是我不想在終端中看到我寫和讀的內(nèi)容。例如tn = telnetlib.Telnet(host)tn.write(command.encode('ascii') + b"\n")time.sleep(0.1)ret = True if b'iconstorage' in self.tn.read_until(b'iconstorage') else False...我什么也不想看到,但仍然收到 Telnet(host): send b'command\n' Telnet(host): recv b'\xff\xfd\x01\xff\xfd\x1f\xff\xfb\x01\xff\xfb\x03\r\r\nls\r\n~ # ls\r\n\x1b[1;34mbin\x1b[0m ' Telnet(host): IAC DO 1 Telnet(host): IAC DO 31 Telnet(host): IAC WILL 1 Telnet(host): IAC WILL 3...有可能避免這種情況嗎?提前致謝。
添加回答
舉報(bào)
0/150
提交
取消