Skip to content

How make multi domain query #1077

Answered by rthalley
Petrov-Daniil asked this question in Q&A
Discussion options

You must be logged in to vote

Yes, though dnspython's stub resolver has no support for such queries as the protocol has lots of issues with multiple questions, and so basically no one implements support. But to make such a request is easy

import dns.message

m = dns.message.make_query("www.example1.", "A")
m.find_rrset(m.question, "www.example2.", "IN", "AAAA", create=True)
print(m.to_text())

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Petrov-Daniil
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants