Request: Reverse resolve #3186
Replies: 2 comments 2 replies
-
The current state of things is that our resolver treats IP addresses as already resolved, so besides the reverse resolution question we should also invent a non-standard URL to indicate an IP that wants to be reverse resolved. Or, provide a separate API. The latter makes more sense. |
Beta Was this translation helpful? Give feedback.
-
I think what you're doing is fine, an UDP event handler is able to do that, and you should parse the response yourself, is not black magic, just copy what the dns_cb does, no need for Win calls |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
In my project I have the need to reverse-resolve an IPv4-address into a name.
As in
adig -t ptr -x 88.95.131.105
->ti0040q160-6429.bb.online.no
.So I cooked up this function:
and in my DNS-callback, I call WinDNS to parse the raw response:
Assuming
mg_dns_parse(()
have to succeed in order for WinDNS to succeed. Not sure this is needed.This program works fine. But I'd rather like Mongoose and
dns.c
could have such reverse-resolver functions instead.(avoiding blocking in
gethostbyaddr()
etc.). The details of DNS, is too complex for me to make a PR for this,so how about it?
Beta Was this translation helpful? Give feedback.
All reactions