I've developped a fakeinternet service so that the standalone (non internet connected) routers would not cause Android/iOS/Kindle Fire tablets to display the warning message about lack of internet connectivity and/or blacklist the WiFi.
The use case would be anywhere where the WiFi and local connectivity is needed while internet access is not available -- for example remote cabin/plane/boat with the local service like emby.
I'd welcome some real-world feedback from iOS users.
Check out the README for more information. The pre-built package is available from my repo.
Added handling of requests sent by Kindle Fire tablets.
Converted iptables rules to PROCD firewall rules for more OpenWrt-like code.
It's ready for prime time! If you have an offline network and don't want your devices to annoy you with "This network has no internet connection" -- just install this package.
@stangri Thank you for package. Kudos! Am doing extensive testing with multiple devices and OS's in next few weeks. Will do bit of contribution by filing any bugs I find.
Here is a question? Is it possible to use this Fakeinternet settings itself to redirect all HTTP/HTTPS connections to the Internet redirected to local website hosted on the http://localserver.lan/ when Internet is connected (WAN cable is disconnected.) Thanks!
You'd have to edit the code a bit. In the file /etc/init.d/fakeinternet replace the line 27 with the assignment like ip=192.168.1.xx, where 192.168.1.xx is an IP for localserver.lan.
It would break the functionality unless you configure your localserver to give exactly same responses to specific requests as my package does.
The FakeInternet intercepts the connections and redirects the browser to localserver.lan.
Basically we are redirecting all traffic to the localserver if it doesn't match any address defined in fakeinternet configuration or local lan addresses.
@stangri Reading through the dnsmasq docs, I found out that all traffic could be redirected by adding following line to dnsmasq custom configuration.
address=/#/10.0.0.1
Wonder if I could just add it as last policy at the end of fakeinternet.conf. Not sure what sort of actions there are other than 'fake' and 'block'? Is there a redirect or allow?
@stangri Is there any docs about /www_fakeinternet/error.cgi configuration. At the moment whenever there is no code to handle fake or block a URI, you are show a directory listing of the root page with "/ error.cgi"
@stangri How do I build/cross compile the fakeinternet package locally on Ubuntu 64bit machine? I want to make some changes and test the package on OpenWRT Virtual machine or the real device. Thanks!
Just like you would any other package. Or you can modify files on the live router. Not sure if you'd even need to restart the service if you're only changing the .cgi.