mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
password: utils/password.py is not used by ssowat anymore
This commit is contained in:
parent
7f02fcd985
commit
f505efc8bb
1 changed files with 0 additions and 16 deletions
|
@ -206,19 +206,3 @@ class PasswordValidator:
|
||||||
p = subprocess.Popen(command.split(), stdin=subprocess.PIPE)
|
p = subprocess.Popen(command.split(), stdin=subprocess.PIPE)
|
||||||
p.communicate(input=password.encode("utf-8"))
|
p.communicate(input=password.encode("utf-8"))
|
||||||
return not bool(p.returncode)
|
return not bool(p.returncode)
|
||||||
|
|
||||||
|
|
||||||
# This file is also meant to be used as an executable by
|
|
||||||
# SSOwat to validate password from the portal when an user
|
|
||||||
# change its password.
|
|
||||||
if __name__ == "__main__":
|
|
||||||
if len(sys.argv) < 2:
|
|
||||||
import getpass
|
|
||||||
|
|
||||||
pwd = getpass.getpass("")
|
|
||||||
# print("usage: password.py PASSWORD")
|
|
||||||
else:
|
|
||||||
pwd = sys.argv[1]
|
|
||||||
status, msg = PasswordValidator("user").validation_summary(pwd)
|
|
||||||
print(msg)
|
|
||||||
sys.exit(0)
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue