Jump to content
  • Advertisement
Sign in to follow this  
Evil Steve

Winsock: Getting IP of DNS server

This topic is 3674 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm writing some test code for submitting various types of DNS requests as a learning experience, and I'd like to automatically determine the IP address of the name server. At work, I can send a DNS request to and I get a reply back from our server which is running as a name server (Some varient of Windows Server). At home, I don't get any reply from the router (A Netgear router) unless I send the DNS request to it directly (EDIT: As verified by Wireshark). So my question is: How can I get the IP address of the DNS server(s) as shown by running ipconfig /all on the command prompt? I'm only interested in Windows for this, and XP / Vista, and in C++. Cheers, Steve

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!