add some duplicate file prevention

git-svn-id: https://kippo.googlecode.com/svn/trunk@12 951d7100-d841-11de-b865-b3884708a8e2
This commit is contained in:
desaster
2009-11-16 17:43:25 +00:00
parent 1e3246c6cd
commit 285fbb21ab
2 changed files with 6 additions and 0 deletions

View File

@@ -71,6 +71,10 @@ class command_mkdir(HoneyPotCommand):
'mkdir: cannot create directory `%s\': ' % f + \
'No such file or directory')
return
if f in [x[A_NAME] for x in dir]:
self.honeypot.writeln(
'mkdir: cannot create directory `test\': File exists')
return
dir.append([f, T_DIR, 0, 0, 4096, 16877, time.time(), [], None])
class command_uptime(HoneyPotCommand):