Terarea  2
The automation project
Loading...
Searching...
No Matches
src.lib.components.password_handling.PasswordHandling Class Reference
Collaboration diagram for src.lib.components.password_handling.PasswordHandling:
Collaboration graph

Public Member Functions

None __init__ (self, int error=84, int success=0, bool debug=False)
 
str hash_password (self, str password)
 
bool check_password (self, str password, bytes password_hash)
 

Data Fields

bool debug = debug
 
int success = success
 
int error = error
 
int salt_rounds = 10
 
Disp disp
 

Detailed Description

__summary__

Definition at line 8 of file password_handling.py.

Constructor & Destructor Documentation

◆ __init__()

None src.lib.components.password_handling.PasswordHandling.__init__ ( self,
int error = 84,
int success = 0,
bool debug = False )

Definition at line 12 of file password_handling.py.

Member Function Documentation

◆ check_password()

bool src.lib.components.password_handling.PasswordHandling.check_password ( self,
str password,
bytes password_hash )
    The function to check the entered password with the hashed password
Args:
    password (str): The entered password
    password_hash (bytes): The hashed password

Returns:
    bool: True if it's the same, False if not

Definition at line 45 of file password_handling.py.

◆ hash_password()

str src.lib.components.password_handling.PasswordHandling.hash_password ( self,
str password )
    The function to hash the password for the security
Args:
    password (str): The entered password

Returns:
    str: The hashed password

Definition at line 27 of file password_handling.py.

Field Documentation

◆ debug

bool src.lib.components.password_handling.PasswordHandling.debug = debug

Definition at line 13 of file password_handling.py.

◆ disp

Disp src.lib.components.password_handling.PasswordHandling.disp
Initial value:
= Disp(
TOML_CONF,
FILE_DESCRIPTOR,
SAVE_TO_FILE,
FILE_NAME,
debug=self.debug,
logger=self.__class__.__name__
)

Definition at line 18 of file password_handling.py.

◆ error

int src.lib.components.password_handling.PasswordHandling.error = error

Definition at line 15 of file password_handling.py.

◆ salt_rounds

int src.lib.components.password_handling.PasswordHandling.salt_rounds = 10

Definition at line 16 of file password_handling.py.

◆ success

int src.lib.components.password_handling.PasswordHandling.success = success

Definition at line 14 of file password_handling.py.


The documentation for this class was generated from the following file: