Repository navigation
feat(wifi): Protect the captive portal AP with WPA2/WPA3 by default #562
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
edf2e5f
feat(wifi): apply the stored access point name and add an access poin…
hhvrc 2665cc4
feat(wifi): protect the access point with WPA2/WPA3 and a default pas…
hhvrc d783d6d
Merge remote-tracking branch 'origin/develop' into feat/ap-name-password
hhvrc 85809ba
fix(wifi): tighten access point name and password checks and keep net…
hhvrc f31c5a0
test(config): read back the access point settings and check the redac…
hhvrc 6e37f40
refactor(common): add StringIsPrintableAscii and use it for the acces…
hhvrc 15e2b76
refactor(common): use ranges algorithms in StringHelpers
hhvrc 7f7143d
Merge branch 'develop' into feat/ap-name-password
hhvrc 62c6ac0
fix(wifi): validate the AP defaults at compile time and reject contro…
hhvrc 4910bc2
fix(wifi): reject an invalid access point password in a JSON import
hhvrc 12bc7e2
fix(portal): bind the servers to the AP's interface after a config ch…
hhvrc da4c2bb
feat(portal): change the access point's name and password from the ca…
hhvrc 0e3f0d4
fix(portal): refuse control characters in the access point name befor…
hhvrc dc81b30
refactor(wifi): move access point naming and WiFi limits out of the c…
hhvrc 5522a6a
refactor(wifi): add access point reset accessors and move its validat…
hhvrc 3b67424
fix(portal): answer PUT /api/ap with the saved settings and match eac…
hhvrc c7e3496
chore(schemas): pin the access point Ready message schema as committe…
hhvrc File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| --- | ||
| kind: added | ||
| --- | ||
| Set the captive portal's network name and password, protected by default | ||
|
|
||
| ## Release Note | ||
| The captive portal's WiFi network can now have its own name and a WPA2/WPA3 password, set in the captive portal's new Access Point section or over serial with `ap ssid` and `ap password` | ||
|
|
||
| The portal's network is now protected by default with the password `openshock`, including on hubs that update from an older version. It is public, so it only keeps out passers-by. Phones and computers that support WPA3 get a connection that someone listening nearby can't decrypt even with the password, but anyone who knows it can set up a fake network with the same name. Set your own password or open the network with `ap open`. A factory reset restores the default password, so a forgotten one can always be recovered over USB. | ||
|
|
||
| - Use the stored `wifi.accessPointSSID` for the access point; it was saved but never applied. The default name still gets the hub's MAC appended | ||
| - Add `wifi.accessPointPassword` (NVS key `ap_pass` in `wifi.cfg`, exported in jsonconfig only with sensitive data): defaulting to the new Kconfig option `OPENSHOCK_FW_AP_PASSWORD` (`openshock`, checked at compile time), empty for an open network, else 8-63 printable ASCII characters, with WPA2/WPA3-PSK transition mode (WPA3 clients use SAE, WPA2 clients still connect) | ||
| - Add the `ap` serial command: `ap` shows the name and whether it is protected, `ap ssid <name|default>`, `ap password <password|default>` and `ap open` | ||
| - Add `PUT /api/ap` to the captive portal API (form body: `ssid`, empty for the default; `protection` `default`, `open` or `custom` with `password`; answers with the saved `ssid` and `protection`), and the access point's name and protection, never its password, to the portal's Ready message | ||
| - Changes apply the next time the captive portal starts |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.