0

How does a device know if it has "Internet Access" or "No Internet"?

My laptop can connect to a local network, but it also somehow knows whether or not I can get 'past" that LAN to the wider Internet. If I can't, it usually means I haven't registered for access with the hotel or campus or whatever.

How does it know?

Is the device trying to connect to something "on the Internet," getting denied, and using that as a metric?

1

1 Answer 1

0

Is the device trying to connect to something "on the Internet," getting denied, and using that as a metric?

Yes, that is exactly what will happen. In case of Android, it make an request to some url like http://clients3.google.com/generate_204, and see if the request get redirected (by the wifi router, for example).

2
  • Who decides what URL it tries to access? Is this manufacturer-specific? Is it configurable somewhere?
    – Deane
    Feb 13, 2019 at 14:33
  • It is set by manufacturer or OS vendor. I wouldn't try customizing it. Figuring out what to use is tricky and has to follow the exact convention of your OS's internet check algorithm. If you feel like breaking things though, the settings for windows are in the registry: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Nla\Svc\Parameters\Internet. You can read more here: blog.superuser.com/2011/05/16/windows-7-network-awareness
    – Andy
    Feb 13, 2019 at 20:46

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .