passusr.py

This commit is contained in:
Raphanaud 2021-10-06 09:31:00 +02:00
parent a28bbb33b1
commit 9c37b351ec

View File

@ -21,10 +21,7 @@ else:
res = os.system ("getent passwd "+login)
if res != 0:
passw = ["pwgen", "4","1"]
#passw = "pwgen 4 1"
os.system (cmd)
#mdp = str(os.system (passw))
#print (mdp)
mdp = subprocess.run(passw,capture_output=True)
mdp2 = mdp.stdout.decode("utf-8")
mdp3 = mdp2.rstrip()