summaryrefslogtreecommitdiff
path: root/mod_auth_custom/mod_auth_custom.lua
diff options
context:
space:
mode:
Diffstat (limited to 'mod_auth_custom/mod_auth_custom.lua')
-rw-r--r--mod_auth_custom/mod_auth_custom.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/mod_auth_custom/mod_auth_custom.lua b/mod_auth_custom/mod_auth_custom.lua
index 315b630..2c05f74 100644
--- a/mod_auth_custom/mod_auth_custom.lua
+++ b/mod_auth_custom/mod_auth_custom.lua
@@ -21,10 +21,13 @@ function test_password(username, password)
21 local responses = {} 21 local responses = {}
22 for i,m in ipairs(t) do 22 for i,m in ipairs(t) do
23 if m[1] == pam.PAM_PROMPT_ECHO_OFF then 23 if m[1] == pam.PAM_PROMPT_ECHO_OFF then
24 print("sending password");
24 responses[i] = {password, 0}; 25 responses[i] = {password, 0};
25 elseif m[1] == pam.PAM_PROMPT_ECHO_ON then 26 elseif m[1] == pam.PAM_PROMPT_ECHO_ON then
27 print("sending username");
26 responses[i] = {username, 0}; 28 responses[i] = {username, 0};
27 else 29 else
30 print("sending empty response");
28 responses[i] = {"", 0}; 31 responses[i] = {"", 0};
29 end 32 end
30 end 33 end