aboutsummaryrefslogtreecommitdiffstats
path: root/net/dns.lua
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2009-11-18 01:05:38 +0000
committerMatthew Wild <mwild1@gmail.com>2009-11-18 01:05:38 +0000
commit911cb9d48898a35652e0e8ae53a7b5459522431d (patch)
treedc755e78e11bda71aee541b20ce7ba13cb607beb /net/dns.lua
parent8fc8a263c6ab7c2595693764f46e366084d72a55 (diff)
downloadprosody-911cb9d48898a35652e0e8ae53a7b5459522431d.tar.gz
prosody-911cb9d48898a35652e0e8ae53a7b5459522431d.zip
net.dns: Be more strict about checking the DNS replies we receive
Diffstat (limited to 'net/dns.lua')
-rw-r--r--net/dns.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/dns.lua b/net/dns.lua
index 04b2cf22..5d5f512f 100644
--- a/net/dns.lua
+++ b/net/dns.lua
@@ -726,7 +726,8 @@ function resolver:receive(rset) -- - - - - - - - - - - - - - - - - receive
local packet = sock:receive();
if packet then
response = self:decode(packet);
- if response then
+ if response and self.active[response.header.id]
+ and self.active[response.header.id][response.question.raw] then
--print('received response');
--self.print(response);