sjhilt/GasPot

Error in telnet session

tXambe opened this issue · 7 comments

Hello,

When I run ^AI20100 in the session of telnet , close the connection with error "Connection closed by foreign host"

What can is wrong ?

Thanks a greeting

what is the telnet command you are using?

telnet localhost 10001

are you using "^" + "A" or using Control + A, as its Control + A, which is a 0x01 which is what the program is looking for.

adm:~$ telnet localhost 10001
Trying ::1...
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
^A I20100
Connection closed by foreign host.

adm:~$ telnet localhost 10001
Trying ::1...
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
^AI20100
Connection closed by foreign host.

Any logs from GasPot from this connection? It writes connection information to a log file.

AESPS commented

Got the same error,

from GasPot
Unknown Error: a bytes-like object is required, not 'str'
Traceback (most recent call last):
File "GasPot.py", line 302, in
while not ('\n' in response or '00' in response):
TypeError: a bytes-like object is required, not 'str'

So looking more into this it takes a lot more of my socket stuff to change and might need a rewrite of this code to make it work, so at this point in time, use ConPot until I can fix it, or use python2.7 on this https://github.com/sjhilt/GasPot/tree/f90987f5fdb05eb6bd140721088346d3400ed8eb