Look at the routing table? Typically, if you do not route between networks on Windows (which is possible, but unusual for a client computer these days), an interface that has a default route will have an Internet connection.
There was no detail in your question about why or what you are doing, so I cannot provide any features. The "route" command line tool may be of some help, but there are probably libraries for any programming language that you use to view the routing table.
You cannot rely on the IP address of the interface (for example, if the address RFC-1918 [192.168.0.0/16, 172.16.0.0/12, 10.0.0.0/8] is not the Internet), since most sites have some kind of NAT a firewall or proxy installation, and the Internet interface is really located on the private server, which takes you to the Internet.
UPDATE: Based on your additional information, it looks like you have a decent solution. I'm not sure about 0.0.0.0, as this is a borderline case for an IP address - it might be ok on your particular platform / language combination. Sounds (from the API description), how could you just indicate an address, so why not name some address on the Internet, for example? Is the IP address of your website or something more random, like 65.66.67.68? Just remember to choose one of the rfc-1918 addresses or the localhost range (127.0.0.0/8) or multicast, any other reserved range and any address that allows .mil or .gov (as long as it doesn't work) It sounds like getbestinterface sends any traffic, it suck to find out if the feds will break your door ... :)
source share