Package src.util
Class password
java.lang.Object
src.util.password
Password Class to Hash Password and check also check them
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
password
public password()
-
-
Method Details
-
getHash
Hash a Password with the SHA-256 Hash function- Parameters:
password
-- Returns:
- password as sha256-hash
-
check
Check if the passworts are the same- Parameters:
password
- that the user providedhash
- from the database- Returns:
- true if the password is correct, otherwise false
-