modifié: m/login.py

modifié:         superTornado.py
This commit is contained in:
sidya82 2014-03-01 22:06:28 +01:00
parent ca621aba8f
commit e3c796a102
2 changed files with 5 additions and 5 deletions

View File

@ -6,7 +6,7 @@ from datetime import datetime
class Login(object):
def verifLogin(self,pLog,pMdp):
hashMdp = hashlib.sha224(pMdp).hexdigest()
with open("fichier/autorise", "r") as source :
with open("m/fichier/autorise", "r") as source :
for ligne in source :
data = ligne.rstrip('\n\r').split(',')
if data[0] in pLog :
@ -17,7 +17,7 @@ class Login(object):
return False
def enregDansLog(self,pLog,pMsg,pIP):
with open("fichier/log", "a") as dest :
with open("m/fichier/log", "a") as dest :
d = datetime.now().strftime("%c")
dest.write("%s,%s,%s,%s\n" % (d,pLog,pMsg,pIP))

View File

@ -141,9 +141,9 @@ application = tornado.web.Application([
(r"/unauthorized", UnauthorizedHandler),
(r"/disconnection", DisconnectionHandler),
(r"/socket", WSocketHandler),
(r"/style/(.*)", tornado.web.StaticFileHandler,{"path":"./style"},),
(r"/images/(.*)", tornado.web.StaticFileHandler,{"path":"./images"},),
(r"/js/(.*)", tornado.web.StaticFileHandler,{"path":"./js"},)],
(r"/style/(.*)", tornado.web.StaticFileHandler,{"path":"./v/style"},),
(r"/images/(.*)", tornado.web.StaticFileHandler,{"path":"./v/images"},),
(r"/js/(.*)", tornado.web.StaticFileHandler,{"path":"./v/js"},)],
cookie_secret="1213215656")
if __name__ == "__main__":