gokrazy / wifi

WiFi daemon for connecting to WiFi networks (encrypted or unencrypted) with gokrazy
https://gokrazy.org/
Other
36 stars 4 forks source link

[Feature Request] WiFi Kiosk Mode #1

Open the-technat opened 2 years ago

the-technat commented 2 years ago

Hey there!

I started using gokrazy some time ago and definitely love it. One thing I came across and I think it could be very useful, is a WiFi Kiosk Mode. I've seen this with comercial products and think it's an easy option to configure WiFi for your "applicance" when you don't have technical know-how (e.g in a "finished" product you hand out to someone).

The idea is that gokrazy creates an access point (if no wifi is configured) and spawns an open WiFi you can connect to using your phone in order to configure WiFi for the device on a web page. The instance could then restart and use the WiFi you configured.

I guess it's rather hard to implement, especially when there are no libaries available to create an accesa point, but I thought I share my idea anyway.

Let me know what you think or close the issue when it's too stupid ;) I'd also have limited time and some Go know-how available to contribute if desired.

stapelberg commented 2 years ago

Hey @the-technat

I’m glad gokrazy is useful for you!

Yes, configuring a device via WiFi is very convenient indeed, and it would be a cool feature if gokrazy could do that 👍

It looks like the Raspberry Pi 3 and 4 (maybe also others) support running a WiFi network in master mode, which is typically accomplished using hostapd.

I don’t know how much code would be required to run an (unencrypted) WiFi in master mode from Go, but perhaps it’s as simple as extending the github.com/mdlayher/wifi package with a method or two.

You’re certainly welcome to look into it and share your findings. Myself, I have little time right now, so it probably will be a while before I get around to it, if at all :)

FYI: Apple has an even more convenient setup flow, but that’s probably way more out of reach for us to implement :) https://twitter.com/zekjur/status/1319386140156329986

quite commented 1 year ago

That msg on twitter can no longer be viewed. But I concur that in general running gokrazy as, among other things, an Accesspoint (AP), would be useful!

stapelberg commented 1 year ago

That msg on twitter can no longer be viewed.

Here are the message contents:

Just set up my first device using Apple’s wireless accessory configuration (WAC) and that was pretty magical!

After selecting the device, your phone makes it join the WiFi automatically. No forms or apps needed!

more details in @grandcentrix’s post https://medium.com/grandcentrix/iot-onboarding-2e009535c050

1319386140156329986-Ek9mTVyXgAIR86b

Thu Oct 22 21:12:23 +0000 2020