From dd847cfba7a24bc338ff07feb1e7685bbf4b512e Mon Sep 17 00:00:00 2001 From: desaster Date: Tue, 8 Jun 2010 19:13:09 +0000 Subject: [PATCH] Log full command line for known/unknown commands git-svn-id: https://kippo.googlecode.com/svn/trunk@117 951d7100-d841-11de-b865-b3884708a8e2 --- kippo/core/honeypot.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/kippo/core/honeypot.py b/kippo/core/honeypot.py index 3795d3f..2f1b4ea 100644 --- a/kippo/core/honeypot.py +++ b/kippo/core/honeypot.py @@ -72,9 +72,9 @@ class HoneyPotShell(object): if not len(self.cmdpending): self.showPrompt() return - i = self.cmdpending.pop(0) + line = self.cmdpending.pop(0) try: - cmdAndArgs = shlex.split(i) + cmdAndArgs = shlex.split(line) except: self.honeypot.writeln( '-bash: syntax error: unexpected end of file') @@ -103,11 +103,11 @@ class HoneyPotShell(object): rargs.append(arg) cmdclass = self.honeypot.getCommand(cmd, envvars['PATH'].split(':')) if cmdclass: - print 'Command found: %s' % (cmd,) + print 'Command found: %s' % (line,) self.honeypot.call_command(cmdclass, *rargs) else: - print 'Command not found: %s' % (cmd,) - if len(i): + print 'Command not found: %s' % (line,) + if len(line): self.honeypot.writeln('bash: %s: command not found' % cmd) if len(self.cmdpending): self.runCommand()