Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When using public wifi spots that requires acceptance of terms of use, the network notification icon in the Windows taskbar shows a balloon that says "Additional logon information may be required". Clicking this opens my browser to the appropriate page, so that I can accept the terms of use.

How does Windows know which URL to send your browser to?

share|improve this question
It probably just picks your "Gateway" address, which is usually the thing requesting authentication. – Ƭᴇcʜιᴇ007 Jul 14 '14 at 15:19
up vote 5 down vote accepted

It's not just a Windows thing, but a networking thing.

Your system will try to access a generic website it knows to always be up, and checks the result. If it gets a success code (ie HTTP 200), it knows it has permission to access the internet, and lets you go on your way.

This sort of system is known as a Captive Portal. Before authentication/authorization has completed, when the client requests a web page, an HTTP 302 error code (redirect) is returned, and the Location response header includes the URL to direct the user to.

RFC 2138 also describes the process, and what is required, to setup such a system.

Wikipedia has a good quick write-up about how the system works. In my school that I work at, we have all the user accounts on the server for regular file sharing. We have our HP Wireless Controllers connect to the server when authenticating users, so everyone can log in with their own credentials, without bugging the IT department, or having one generic login.

share|improve this answer
I can't seem to find anything in that wikipedia article specifically related to my question. Also, the RFC is a rather large document. Could you be more specific about what you mean by "it includes the url to direct users to"? Where is the URL? In the HTTP headers? In the returned HTML? – GreenGiant Jul 14 '14 at 23:15
In the HTTP headers. When you connect (if you run a packet sniffer), you'll see Windows request a website, and get an HTTP code. I don't know the exact one, but one will be a redirect requiring authorization, and include the URL to send the user to. I'll try to get more information for you. – Canadian Luke Jul 15 '14 at 2:53
@GreenGiant I updated the answer with more information on Captive Portals (sorry, couldn't remember the name earlier) – Canadian Luke Jul 15 '14 at 2:58
Thanks. My question was mainly focused on how the client knows the URL, not how the whole system works. I've edited your answer to make that part clear. – GreenGiant Jul 16 '14 at 13:27

The network tells Windows that it needs some sort of Authentication, so the info it receives is that it needs to go to a website to authenticate.

share|improve this answer
Right. How does it know what website (URL) that is? – GreenGiant Jul 14 '14 at 16:46

You must log in to answer this question.

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