Open flatsiedatsie opened 4 years ago
The login page you were seeing at /login
was almost definitely cached. We don't even bring up those routes while in Wi-Fi setup mode.
Ah I see. But:
*cough
Related: It would be nice if the gateway could function as an actual routing / wifi gateway.
@eode That's what the OpenWrt build for the Turris Omnia was for: https://iot.mozilla.org/gateway/
We had some internal OpenWrt builds for the Raspberry Pi as well, it just didn't make much sense as a router.
Would it technically be possible to allow logins while in hotspot mode? Is this something that would require relatively small changes, or is that just my projection?
What would be required to 'unlock' the login in this mode? Are there a theoretical set of SSH commands that could get it to that state?
Would it be interesting to made these changes to the gateway?
Possible, sure. "It's just software." You'd have to modify the whole server setup process in the gateway, and the captive portal would not be as reliable.
Do you have any hints as to which files I'd need to modify to "bring up those routes" during the captive portal phase?
If you want the captive portal to stay running, you'll need to look here:
For general routing, see here:
Thanks for the links! really interesting to look deeply under the hood.
If you want the captive portal to stay running
I don't really want the captive portal to say running. I want to bring up all the routes while the gateway in captive portal mode.
Or are you saying that this would be much easier to get working?
Still, I'd prefer that routes were available while in captive portal mode, as this would avoid the necessity to connect to a wifi network. It would just be its own wifi network. This would be great for exhibits and workshops, where connecting to the local wifi is often hit-and-miss.
This functionality would also be great in a pinch. Imagine if someone's router suddenly dies or is hacked. Currently they'd have no way to access the Gateway. But if it would revert to access point mode and they could connect to that, then hey could then still have basic control over their home while they buy a new router.
Last weekend I was frantically trying to enable an add-on (voco) somehow at a location (TV studio) where the gateway couldn't succesfully connect to the WiFi. I wanted to demo the local voice control, but in the end had to let it go.
The gateway had been prepared before, and already had an account on it, and had SSH enabled.
I noticed that when my laptop was connected to the gateway while in hotspot mode, I could SSH into it, and could also access the samba share I had made on it. This was great, since it allowed me to salvage some work-in-progress files from it.
I also noticed that I could reach the gateway's login page while in hotspot mode. If memory serves, I just had to visit
192.168.2.1/login
, and the login page was actually there.I got very excited, since a gateway that would work in stand-alone mode would simplify demonstrations tremendously. However, I could not login. It seems as if the existing user accounts were somehow inaccessible when the gateway was in that mode?
The questions that it raised with me were:
To be clear, I'm not proposing that the Raspberry Pi act as a full fledged router. I'm just proposing that it would be great if it was possible to log-in while it is in hotspot mode.
I think I have proposed a similar idea before, but I can't find the issue now. What really made me want to bring this up again was the feeling that it was so close to working.