diff -r ba71d0ad5564 -r a40f9b8661d8 mod_s2s_auth_dane/mod_s2s_auth_dane.lua --- a/mod_s2s_auth_dane/mod_s2s_auth_dane.lua Tue Sep 16 17:32:45 2014 -0400 +++ b/mod_s2s_auth_dane/mod_s2s_auth_dane.lua Tue Sep 16 19:53:41 2014 +0200 @@ -253,7 +253,7 @@ for i = srv_choice or 1, srv_choice or #srv_hosts do srv_target = session.srv_hosts[i].target:gsub("%.?$",""); log("debug", "Comparing certificate with Secure SRV target %s", srv_target); - srv_target = nameprep(idna_to_unicode()); + srv_target = nameprep(idna_to_unicode(srv_target)); if srv_target and cert_verify_identity(srv_target, "xmpp-server", cert) then log("info", "Certificate for %s matches Secure SRV target %s", host, srv_target); session.cert_identity_status = "valid";