Piratebox on raspberry pi works but mobile devices nagged with popup

Posted by cito 
This forum is currently read only. You can not log in or make any changes. This is a temporary situation.
Now, this forum is in read-only mode. You find details Details hereContinue on /r/PirateBox
Piratebox on raspberry pi works but mobile devices nagged with popup
September 26, 2018 09:30PM
Howdy,

Installed piratebox 1.1.4 image on a raspberry pi and it works, except in my case the average users have issues and i can see why, just don't know how to fix.

on any mobile device from my tablet, neighbors phone, and a friend's tablet that visited when they connect to the access point they get 'connected, no internet' and a popup message which ill link screenshot below.

now on my tablet i click the popup and click so that my tablet doesn't disconnect. I open a web browser and of course there's no immediate redirects. So I type in random letters in the url bar as if doing a search then it redirects just fine to the piratebox web interface.

Now I may be trying to be a little too ambitious as my wifi antenna is on my roof and testing it i can connect from all around the apartment complex im at. But neighbors don't know to jump through the hoops as i cant tell them all to connect, when you get popup that warns no internet to touch 'stay connected anyway' then open a browser and type any random letters on the url bar and then you'll be good to go.

Here's a screenshot i cropped showing the "connected, no internet" and the popup android gives.

[cloud.dude-suit.net]

temporarily for testing i changed the ssid to "testing" reason it's listed as such in the screenshot.


any tips or tricks I may be missing?
the redirect does work if i attempt to enter any url or type any random gibberish on the url bar then it redirects and works just fine. So that part is working, checking process list dnsmasq loads the piratebox configs. So you can imagine neighbors who aren't the most technically savvy i tell them i got this project running that all can connect, share files, chat, leave messages, etc but they get that connected, no internet and android popup would run off some, but then those that didnt click to disconnect would be a little lost hehe.

i would think since if i open a web browser and type an address like google.com in the url bar since it does redirect to the piratebox web interface that it shouldnt give error 'connected, no internet'.
but im most likely missing something.

anyhow thanks for info smiling smiley


edit to add:

I did search forums and tried the disable dnsmasq/etc stuff but no change.

the redirect works if typing a url in bar and still get popup connected, no internet



Edited 1 time(s). Last edit at 09/26/2018 09:33PM by cito.
Re: Piratebox on raspberry pi works but mobile devices nagged with popup
September 29, 2018 02:52PM
Are android devices compatible with piratebox?

Since I've done more testing, since mobiles popup connected, no internet they swap back to data connection and disconnect from piratebox, and tablets keep getting popup in screenshot above. Which nobody can use unless they were a bit technically inclined since they don't know to click stay connected despite no internet on the popup plus not knowing they have to manually type in an ip address in browser to load the piratebox interface.

I've tried dozens of tricks found on piratebox reddit and old forum posts here from 2014 but none are working.

New version of Android the fake internet isn't working so pop-ups occur and mobiles judt flip back to data.

Is the raspberry pi supported? Or is there a special config for Android to get it to work. I fear I'm out of luck since similar problems mentioned on reddit months ago was never resolved.

Anyhow thanks for the project, it used to work but new versions of Android seem to have patched their "connected no internet" protection stuff
Re: Piratebox on raspberry pi works but mobile devices nagged with popup
September 29, 2018 06:37PM
Hi,
you found everything what I can tell you about it.

The issue is, that our "fake internet detection" does not work reliable with Android.
A while ago, I had a 2 week ongoing infrequent debug session with doing alot of adjustments on the lighttpd configuration to get it working, with no success. The Android internet detect want a special reply with the Message "conent-size: 0" and no content.
But lighttpd drops that HTTP request information resulting in a not working internet detection.

The problem is getting more odd with the further spread of https, because
- in the past: on http only page, you open up your browser while being connected to piratebox and you are properly redirected to the piratebox' landing page
- now the most pages are running https, which prevents the piratebox to send over a redirect.

(no, having some kind of certificate active on PirateBox does not solve the problem (you'll receive more or less hard error message which prevent you connecting (depending on your browser))).

thumbs down

edit: in the development branch, I added a captive portal style feature, which may help- but nobody is testing. anyway. cheers.

Matthias



Edited 1 time(s). Last edit at 09/29/2018 06:37PM by Matthias.
I've run into another issue on android.

It detects no internet but doesn't switch to cell data.
It forces redirects so I get the piratebox.lan/content page

BUT all attempts to hit piratebox.lan:8080 get redirected as well... Not sure why.
I found it.

Chrome's download accelerator thing.

It's attempting some kind of connection to google to do the accelerator stuff.

Disabled and its going normally now.
Re: Piratebox on raspberry pi works but mobile devices nagged with popup
March 28, 2019 04:31AM
I'm having an issue where when a user opens a browser which most likely connects to an https site like google which many people have set as their homepage doesn't redirect to piratebox.lan. Not just google but any https website. Most modern browsers always make the first attempt to connect using https which is not redirected. Is there a way to redirect all browser traffic to piratebox.lan regardless of http or https?

The only way to get around this currently is to go to a website that the user has never visited before or tell the user to type the ip address into the browser. Either way the user needs to be instructed how to access piratebox.lan

My goal is to have it so when someone connects to the piratebox and opens a browser, the browser will automatically go to the piratebox page without having to instruct the user how to access the page. similar to a captive portal.

Thank you in advanced for your help.