plugins/mod_auth_internal_hashed.lua
changeset 8195 4354f556c5db
parent 8059 cacf14c218ab
child 10222 e458578ddfd3
child 10526 b1ca849b8e3a
--- a/plugins/mod_auth_internal_hashed.lua	Sun Aug 06 13:27:47 2017 +0200
+++ b/plugins/mod_auth_internal_hashed.lua	Fri Jul 28 13:15:29 2017 +0200
@@ -120,7 +120,9 @@
 			local credentials = accounts:get(username);
 			if not credentials then return; end
 			if credentials.password then
-				usermanager.set_password(username, credentials.password, host);
+				if provider.set_password(username, credentials.password) == nil then
+					return nil, "Auth failed. Could not set hashed password from plaintext.";
+				end
 				credentials = accounts:get(username);
 				if not credentials then return; end
 			end