ProcessQueryResult processQuery(DNSQuestion& dnsQuestion, std::shared_ptr<DownstreamState>& selectedBackend);
ProcessQueryResult processQueryAfterRules(DNSQuestion& dnsQuestion, std::shared_ptr<DownstreamState>& outgoingBackend);
+/* Process a response received from a backend. The return value indicates whether
+ the response processing should continue (true) or if it should be dropped right away (false).
+*/
bool processResponse(PacketBuffer& response, DNSResponse& dnsResponse, bool muted);
+/* Apply the decision (result) of a single rule to this query. If the decision implies to drop the query
+ `query` will be set to `true`. The return value indicates whether subsequent rules should be evaluated (true)
+ or not (false).
+*/
bool processRulesResult(const DNSAction::Action& action, DNSQuestion& dnsQuestion, std::string& ruleresult, bool& drop);
+/* Handle the processing of a response once the rules have been applied. The return value indicates whether
+ the response processing should continue (true) or if it should be dropped right away (false).
+*/
bool processResponseAfterRules(PacketBuffer& response, DNSResponse& dnsResponse, bool muted);
bool processResponderPacket(std::shared_ptr<DownstreamState>& dss, PacketBuffer& response, InternalQueryState&& ids);
bool applyRulesToResponse(const std::vector<dnsdist::rules::ResponseRuleAction>& respRuleActions, DNSResponse& dnsResponse);