64 end |
64 end |
65 |
65 |
66 function provider.get_sasl_handler() |
66 function provider.get_sasl_handler() |
67 local realm = module:get_option("sasl_realm") or module.host; |
67 local realm = module:get_option("sasl_realm") or module.host; |
68 local getpass_authentication_profile = { |
68 local getpass_authentication_profile = { |
69 plain = function(username, realm) |
69 plain = function(sasl, username, realm) |
70 local prepped_username = nodeprep(username); |
70 local prepped_username = nodeprep(username); |
71 if not prepped_username then |
71 if not prepped_username then |
72 log("debug", "NODEprep failed on username: %s", username); |
72 log("debug", "NODEprep failed on username: %s", username); |
73 return "", nil; |
73 return "", nil; |
74 end |
74 end |