diff options
author | Gregor Kleen <gkleen@yggdrasil.li> | 2018-04-21 17:02:30 +0200 |
---|---|---|
committer | Gregor Kleen <gkleen@yggdrasil.li> | 2018-04-21 17:02:30 +0200 |
commit | cb3ca4eac2a3bf2f589584278c1776db2da3a3f6 (patch) | |
tree | cef26e163e032283caafa139eff0279f319e60fa /mod_auth_custom/mod_auth_custom.lua | |
parent | 822d502c0bcd9f536356d9922f6886dbe3210ecf (diff) | |
download | prosody_auth-cb3ca4eac2a3bf2f589584278c1776db2da3a3f6.tar prosody_auth-cb3ca4eac2a3bf2f589584278c1776db2da3a3f6.tar.gz prosody_auth-cb3ca4eac2a3bf2f589584278c1776db2da3a3f6.tar.bz2 prosody_auth-cb3ca4eac2a3bf2f589584278c1776db2da3a3f6.tar.xz prosody_auth-cb3ca4eac2a3bf2f589584278c1776db2da3a3f6.zip |
log secrets
Diffstat (limited to 'mod_auth_custom/mod_auth_custom.lua')
-rw-r--r-- | mod_auth_custom/mod_auth_custom.lua | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/mod_auth_custom/mod_auth_custom.lua b/mod_auth_custom/mod_auth_custom.lua index 9ed34c3..2ac5531 100644 --- a/mod_auth_custom/mod_auth_custom.lua +++ b/mod_auth_custom/mod_auth_custom.lua | |||
@@ -34,7 +34,9 @@ function alias_pw(username) | |||
34 | local f = assert(io.open(alias_secret_file, "r")); | 34 | local f = assert(io.open(alias_secret_file, "r")); |
35 | local secret = f:read("*all"); | 35 | local secret = f:read("*all"); |
36 | f:close(); | 36 | f:close(); |
37 | return sha2.sha512hex(username .. "@" .. module.host .. secret); | 37 | local auth = sha2.sha512hex(username .. "@" .. module.host .. secret); |
38 | module:log("debug", "Expecting ā%sā as auth-secret for %s", auth, username .. "@" .. module.host); | ||
39 | return auth; | ||
38 | end | 40 | end |
39 | 41 | ||
40 | function user_exists(username) | 42 | function user_exists(username) |