mirror of
https://github.com/midoks/mdserver-web.git
synced 2026-10-18 23:45:52 +08:00
Update mw.py
This commit is contained in:
+2
-1
@@ -432,7 +432,8 @@ def hasPwd(password):
|
|||||||
# return crypt.crypt(password, password)
|
# return crypt.crypt(password, password)
|
||||||
import bcrypt
|
import bcrypt
|
||||||
salt = bcrypt.gensalt()
|
salt = bcrypt.gensalt()
|
||||||
return str(bcrypt.hashpw(password.encode('utf-8'), salt))
|
hpw = bcrypt.hashpw(password.encode('utf-8'), salt)
|
||||||
|
return hpw.encode('utf-8')
|
||||||
|
|
||||||
|
|
||||||
def getFileMd5(filename):
|
def getFileMd5(filename):
|
||||||
|
|||||||
Reference in New Issue
Block a user