Software /
code /
prosody-modules
Comparison
mod_s2s_auth_dane/mod_s2s_auth_dane.lua @ 1414:48141957f719
mod_s2s_auth_dane: Unreference DNS lookup when reply arrives (thanks LordVan)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 19 May 2014 16:28:43 +0200 |
parent | 1412:d85695be0441 |
child | 1415:8791fa8a18c8 |
comparison
equal
deleted
inserted
replaced
1413:cfe360d9d82c | 1414:48141957f719 |
---|---|
61 if host_session.dane ~= nil then return end | 61 if host_session.dane ~= nil then return end |
62 if host_session.direction == "incoming" then | 62 if host_session.direction == "incoming" then |
63 local name = host_session.from_host and idna_to_ascii(host_session.from_host); | 63 local name = host_session.from_host and idna_to_ascii(host_session.from_host); |
64 if not name then return end | 64 if not name then return end |
65 host_session.dane = dns_lookup(function (answer) | 65 host_session.dane = dns_lookup(function (answer) |
66 host_session.dane = false; | |
66 if not answer.secure then | 67 if not answer.secure then |
67 if cb then return cb(a,b,c,e); end | 68 if cb then return cb(a,b,c,e); end |
68 return; | 69 return; |
69 end | 70 end |
70 local n = #answer | 71 local n = #answer |