6 lines
164 B
Python
6 lines
164 B
Python
|
|
import bcrypt
|
||
|
|
|
||
|
|
def hashPassword(plain_text_password):
|
||
|
|
salt = bcrypt.gensalt(rounds=10)
|
||
|
|
return bcrypt.hashpw(plain_text_password.encode('utf-8'), salt)
|