pi-builder icon indicating copy to clipboard operation
pi-builder copied to clipboard

WiFi captive portal cross-platform access issues

Open jywarren opened this issue 6 years ago • 7 comments

Different platforms treat the "captive portal" differently:

  1. iOS pops up a notification with the welcome page in a webView mini browser, and you can see through the camera, but if you dismiss the window, it disconnects from the network
  2. Android works fine with the welcome page in the prompt window (similarly a kind of mini browser instance) but Chrome and Firefox can't access http://pi.local until you turn of cellular internet data
  3. Mac OS pops up a mini browser window with the welcome page, and you can escape out or close the popup and use Chrome or another browser to open http://pi.local manually, but it's not redirected-to

I think as we collect information about these scenarios, we can refine the exact captive portal settings and add other solutions!

jywarren avatar Oct 29 '18 16:10 jywarren

Some documentation here: https://en.wikipedia.org/wiki/Captive_portal#Implementation

Raspberry Pi specific info: https://andrewwippler.com/2017/04/07/captive-portal-overview/ with a LOT of info here: https://andrewwippler.com/2016/03/11/wifi-captive-portal/

jywarren avatar Oct 29 '18 16:10 jywarren

Is our approach using the 204 http response code as in the Wikipedia article?

jywarren avatar Nov 01 '18 19:11 jywarren

Figured out that I have to turn off mobile/cellular internet on my Android (Pie) device to be able to load http://pi.local, then it works perfectly!

jywarren avatar Nov 01 '18 21:11 jywarren

iOS seems to really reject WiFi access points that have no real internet connection: https://serverfault.com/questions/709909/wifi-access-point-without-internet-access-ios-devices-disconnect

These folks have found you can enter a static IP and a few other configs on the iOS device, and get it to work: https://discussions.apple.com/thread/7705927 although that seems like a not very ideal solution...

In the same thread on p2 there is speculation that iOS is not accepting the IP address assigned by the ad-hoc network:

http://www.digitalyachtamerica.com/index.php/en/support/support-manuals/support- technotes?download=458:tech-00065-2016-c… interesting document which says that the default IP address for an ad-hoc network may no longer be acceptable to iOS 10. Do you know which address range your network is using?

jywarren avatar Nov 02 '18 21:11 jywarren

And it says:

Roland (maker of some very high-end, expensive mixers) gets around this because their wifi network is identified as a "device" rather than an actual network. Connecting to their mixer is only a matter of answering "ok" to the question about connecting to that device, even without an internet, and then I'm good.

jywarren avatar Nov 02 '18 21:11 jywarren

Kind of cool, here's the message Chrome shows for Amtrak's captive portal: image

jywarren avatar Nov 15 '18 21:11 jywarren

@jywarren hi mate were you able to solve it ?!

minanagehsalalma avatar Nov 03 '20 01:11 minanagehsalalma