Windows Dev Center

 locked
How to do "reverse" IP lookup?

    Question

  • I've found how to resolve a hostname to IP address in the post:
    http://social.msdn.microsoft.com/Forums/en-US/winappswithcsharp/thread/568935a2-5474-43bf-b9d4-1d9c3ba78365

    But if I need to get the hostname/domain name from an IP address, how can I do it in Win8 app?

    I've tried the solutions in the mentioned article, but no hostname is found in the attributes of "HostName"....



    Tuesday, November 27, 2012 8:33 AM

Answers

All replies

  • Hi,

    Sorry I can't find any way to ahieve that.


    Aaron Xue [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Wednesday, November 28, 2012 9:11 AM
  • It depends, ping -a IP Address should show the hostname

    Also you can do PTR lookups in DNS..  

    Here's an example of all the hostnames assocaited to Apple's Ip address

    Apple's IP Address

    There's some C# code on Code Project that does the PTR lookup you can use..

    http://www.codeproject.com/Articles/23673/DNS-NET-Resolver-C



    MCTS - Gold Certification

    Wednesday, November 28, 2012 6:48 PM