Page 1 of 1

Ubuntu 9.04 guest, captive portals on wifi hotspots

Posted: 12. Apr 2010, 22:47
by cpsully69
This is a weird one...I'm not sure I'll get much reaction or help, but here it goes.


I'm running Ubuntu 64-bit, 9.10 host with a 32-bit 9.04 guest. When I am using WiFi hotspots, the ones redirect you to their captive portal to 'accept terms' before they'll let you surf anywhere, I get caught in a vicious loop that won't let me off the captive page. If I type an address or otherwise navigate, I get directed back to the captive page to click "accept."

When I surf through a browser on the Host OS, I "accept" and can go surfing just fine. Then if I start up VB and launch the Guest, that's where I get stuck in the loop.

When I NAT the interface, I can't connect to anything, including the captive portal, on the guest, so I end up Bridging, which gets me to the portal, but then I'm looped.

I have no idea how these portals work, or what they do (cookie?) once you've "accepted" that allows you to surf.

Any direction or help on this would be great!

Re: Ubuntu 9.04 guest, captive portals on wifi hotspots

Posted: 12. Apr 2010, 23:45
by Perryg
They track you via MAC usually, and session cookies. But I have not seen a condition that it would not allow you to continue before.
I do know that you will need to leave the browser up as long as you want to be connected. Closing usually logs you out.

I guess you could setup ICS and use the host as a proxy to work around this.

[SOLVED]: Ubuntu 9.04 guest, captive portals on wifi hotspot

Posted: 12. Apr 2010, 23:59
by cpsully69
Thanks, Perry.

I think I figured something out. I can't say that I can explain why it fixed the problem, but it seems to work...

I got the NAT adapter to work by modifying the internal NAT network (from section 9.8 of the VBox user guide):

VBoxManage modifyvm "My VM" --natnet1 "192.168/16"

It seems that the hotspot I was having most trouble with was issuing 10.0.2.x addresses, which is what VBox wants to NAT by default. So changing the internal NAT to something else made the NAT'd interface work just fine!

I can't explain why my bridged adapter wouldn't work, but since my problem is fixed, I'll leave that to smarter people to figure out.