mirror of https://github.com/cowrie/cowrie.git
test 3
This commit is contained in:
parent
3ca7cc1da5
commit
bfe0d7612b
|
@ -141,8 +141,8 @@ class HoneyPotCommand(object):
|
|||
"""
|
||||
log.msg('QUEUED INPUT: {}'.format(line))
|
||||
# FIXME: naive command parsing, see lineReceived below
|
||||
if (isinstance(line, str)):
|
||||
line = line.decode()
|
||||
line = b"".join(line)
|
||||
line = line.decode("utf-8")
|
||||
self.protocol.cmdstack[0].cmdpending.append(shlex.split(line))
|
||||
|
||||
|
||||
|
@ -186,8 +186,8 @@ class HoneyPotShell(object):
|
|||
"""
|
||||
"""
|
||||
log.msg(eventid='cowrie.command.input', input=line, format='CMD: %(input)s')
|
||||
if (isinstance(line, str)):
|
||||
line = line.decode()
|
||||
line = b"".join(line)
|
||||
line = line.decode("utf-8")
|
||||
self.lexer = shlex.shlex(instream=line, punctuation_chars=True)
|
||||
tokens = []
|
||||
while True:
|
||||
|
|
Loading…
Reference in New Issue