|
@@ -243,13 +243,13 @@ class XfrinConnection(asyncore.dispatcher):
|
|
|
msg = Message(Message.PARSE)
|
|
|
msg.from_wire(soa_response)
|
|
|
|
|
|
+ # TSIG related checks, including an unexpected signed response
|
|
|
+ self._check_response_tsig(msg, soa_response)
|
|
|
+
|
|
|
# perform some minimal level validation. It's an open issue how
|
|
|
# strict we should be (see the comment in _check_response_header())
|
|
|
self._check_response_header(msg)
|
|
|
|
|
|
- # TSIG related checks, including an unexpected signed response
|
|
|
- self._check_response_tsig(msg, soa_response)
|
|
|
-
|
|
|
# TODO, need select soa record from data source then compare the two
|
|
|
# serial, current just return OK, since this function hasn't been used
|
|
|
# now.
|
|
@@ -362,11 +362,13 @@ class XfrinConnection(asyncore.dispatcher):
|
|
|
recvdata = self._get_request_response(msg_len)
|
|
|
msg = Message(Message.PARSE)
|
|
|
msg.from_wire(recvdata)
|
|
|
- self._check_response_status(msg)
|
|
|
|
|
|
# TSIG related checks, including an unexpected signed response
|
|
|
self._check_response_tsig(msg, recvdata)
|
|
|
|
|
|
+ # Perform response status validation
|
|
|
+ self._check_response_status(msg)
|
|
|
+
|
|
|
answer_section = msg.get_section(Message.SECTION_ANSWER)
|
|
|
for rr in self._handle_answer_section(answer_section):
|
|
|
yield rr
|