From 2377be3b4929f1391d1d290ce062a1cce1ae5d59 Mon Sep 17 00:00:00 2001 From: Remi Gacogne Date: Wed, 8 Feb 2017 11:57:41 +0100 Subject: [PATCH] rec: Fix `remote`/`local` inversion in `preoutquery` `dq.remoteaddr` should hold the authoritative server address, but it was stored in `dq.localaddr` instead since ba21fcfedc103f12b6a8eadc17f2797b6d7ffb7b. --- pdns/lua-recursor4.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pdns/lua-recursor4.cc b/pdns/lua-recursor4.cc index 850a97d179..dc15ea2260 100644 --- a/pdns/lua-recursor4.cc +++ b/pdns/lua-recursor4.cc @@ -615,7 +615,7 @@ bool RecursorLua4::preoutquery(const ComboAddress& ns, const ComboAddress& reque { bool variableAnswer = false; bool wantsRPZ = false; - RecursorLua4::DNSQuestion dq(requestor, ns, query, qtype.getCode(), isTcp, variableAnswer, wantsRPZ); + RecursorLua4::DNSQuestion dq(ns, requestor, query, qtype.getCode(), isTcp, variableAnswer, wantsRPZ); dq.currentRecords = &res; return genhook(d_preoutquery, dq, ret); -- 2.47.2