ThalysNet or other accesspoints destroy my browsing experience I tend to travel a lot around Europe, and I don't necessarily think about removing Wifi from my MacBook Air. I also keep dozens of tabs open.

Every single time I take the Thalys, or I get into some Hotel "pay-per-use" Wifi network, my MBA stupidly loads the accesspoints' login-or-register-with-credit-card-number page. While I ignore it, I do lose the pages I had open, since the damn things rewrite the URLs.

For example:

http://stackoverflow.com/questions/somenumber/somequestion


is turned into:

https://portal.thalysnet.com/?hostname=stackoverflow.com


which means I don't know what the page was about, since I might have a dozen SO tabs open at the time... all called this :/ .

Is there any way I can block "URL rewriting" on the Mac, unless specifically authorized by me?
Disable "Ask to join new networks", when selecting Wi-fi in the Network preference pane. You might also need to explicitely forget those networks if you joined them in the past, by clicking on "Advanced..." and removing any undesired network.

Once you are connected to these networks, there is no way in changing this behavior. As every request passes through their access point, they can modify it in every way they want (and return a redirect response instead for example).