Hello,
dnsjava works perfectly for me when I do a single PTR record lookup.
However, if I try to do more than 1, it always fails for me (regardless of
the DNS server I point to)
Here's the code snippet and the response. Can anyone tell me how I can get
this to work?
Any insight would be appreciated! -Kumar
--
public static void lookupPTRMultiple() throws IOException {
Resolver res = new SimpleResolver("209.244.0.3"); // level 3 dns
server
res.setTCP(true);
res.setTimeout(Integer.MAX_VALUE);
Message request = new Message();
Record rec1 =
Record.newRecord(ReverseMap.fromAddress("206.190.36.105"), Type.PTR,
DClass.IN);
request.addRecord(rec1, Section.QUESTION);
Record rec2 =
Record.newRecord(ReverseMap.fromAddress("199.27.145.64"), Type.PTR,
DClass.IN);
request.addRecord(rec2, Section.QUESTION);
System.err.println("Request: " + request);
Message response = res.send(request);
System.err.println("Response: " + response);
}
--
Response: ;; ->>HEADER<<- opcode: QUERY, status: FORMERR, id: 32188
;; flags: qr ; qd: 2 an: 0 au: 0 ad: 0
;; QUESTIONS:
;; 105.36.190.206.in-addr.arpa., type = PTR, class = IN
;; 64.145.27.199.in-addr.arpa., type = PTR, class = IN
;; ANSWERS:
;; AUTHORITY RECORDS:
;; ADDITIONAL RECORDS:
;; Message size: 65 bytes
|