Jump to content
  • Advertisement
Sign in to follow this  
Khatharr

winapi NIC enumeration

This topic is 1945 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

Is there a way in WINAPI to enumerate the addresses of all active local NICs?

 

I've got two separate internet sources right now and I'm wanting to experiment with multihomed download acceleration, and possibly a multihomed torrent program if I can find a lib that's not a pain to pull parts from.

Share this post


Link to post
Share on other sites
Advertisement
GetAdaptersAddresses ought to get you started.

One thing to be aware of is that for a given IP version (i.e. IPv4 or IPv6) you will typically have only one default route which controls which NIC the majority of your internet traffic flows over. It is possible but extremely unusual on a consumer machine to have multiple routes which direct different portions of internet traffic across different NICs.

Put simply, it's not really just a matter of hooking up two internet "sources" to a single machine and suddenly getting twice the bandwidth.

Share this post


Link to post
Share on other sites

Thanks for that function. I'm aware that the routing isn't going to do it for me. I'm going to try explicitly bind the sockets and see if I can bend the thing to my evil will.

 

Edit - Sat down and whipped out some PoC code and it's working as expected. smile.png

 

Thanks again.

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.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!