This commit is contained in:
DESKTOP-DPA61F8\Benedek 2021-04-29 17:11:33 +02:00
parent fd4434f504
commit 73c91d1426
2 changed files with 2 additions and 2 deletions

View File

@ -51,7 +51,7 @@ class Authetication:
b64pwd = b64encode(SHA256.new(password.encode('utf-8')).digest()) b64pwd = b64encode(SHA256.new(password.encode('utf-8')).digest())
bcrypt_check(b64pwd, user['password'].encode('utf-8')) bcrypt_check(b64pwd, user['password'].encode('utf-8'))
auth_logger.debug("User logged in: " + username) auth_logger.debug("User logged in: " + username)
return user['homeDir'] return self.HOME_DIRECTORY_LOCATION + os.path.sep + user['homeDir']
except ValueError: except ValueError:
auth_logger.debug("User NOT logged in: " + username) auth_logger.debug("User NOT logged in: " + username)
return '' return ''

View File

@ -22,7 +22,7 @@ class Server:
def login(self, homeDir: str) -> None: def login(self, homeDir: str) -> None:
self.isAuthenticated = True self.isAuthenticated = True
self.executor = Executor(homeDir + os.path.seb) self.executor = Executor(homeDir + os.path.sep)
def logout(self) -> None: def logout(self) -> None:
self.networkInstance.logout() self.networkInstance.logout()